aboutsummaryrefslogtreecommitdiffstats
path: root/test
AgeCommit message (Collapse)Author
2019-08-29core/erlc.mk: Support non-US-ASCII characters in pathsJean-Sébastien Pédron
Internally, strings were stored using Unicode code points. However, when being written to disk with the `file:write_file()` function, there were converted to ISO-8859-1. According to the documentation, that is because the file module is bytewise-oriented: the conversion to another encoding than ISO-8859-1 is the responsibility of the caller. Using unicode:character_to_binary() permits the script to convert the Unicode string to an UTF-8-encoded binary. Without this patch, the added testcase would fail with the following error: gmake[3]: *** No rule to make target '(...)/erlang.mk/test/h��test_core_makedep_non_usascii_paths/deps/test_core_makedep_non_usascii_paths_dep/include/hello.hrl', needed by 'src/hello.erl'. Stop. In this case, the path (passed from the Makefile to the `makedep.erl` script) contains UTF-8-encoded `é` characters but it was converted when doing the final file I/O.
2019-06-30Don't use "git -C" in tests: older git doesn't have itLoïc Hoguin
2019-06-30Tweak a check in ct tests to make it work on Make 3.82Loïc Hoguin
Getting: Nothing to be done for `ct' Instead of, in later versions: Nothing to be done for 'ct' Only check for the start of the sentence instead.
2019-06-28Accept a list of deps to forcibly rebuild in `$(FORCE_REBUILD)`Jean-Sébastien Pédron
... in addition to the `$(force_rebuild_dep)` function. It's easier for the common use case than specify a function.
2019-06-28Try to make relx-start-stop more reliableLoïc Hoguin
Using new wait_for_success/wait_for_failure functions that will loop the ping commands up to 10 times then give up. This allows us to remove the "sleep 1" and lets us handle intermittent slowness at the same time.
2019-06-26Don't try to start/stop releases in bootstrap-rel testLoïc Hoguin
We already have relx-start-stop for that.
2019-06-26Fix "make eunit/ct" not fetching apps dependenciesLoïc Hoguin
2019-06-25Fix or disable some of the Relx tests on WindowsLoïc Hoguin
2019-06-24Rename force_rebuilding_dep to force_rebuild_depLoïc Hoguin
2019-06-24Fix the core-deps-dep-makefile-change test on WindowsLoïc Hoguin
2019-06-24Fix the force_rebuilding_dep testLoïc Hoguin
2019-06-24Accept `$(force_rebuilding_dep)` to tune the behavior of `$(FULL)`Jean-Sébastien Pédron
By default, Erlang.mk only builds dependencies once, the first time the top-level project is compiled. A forced rebuild of all dependencies can be forced by setting the `$(FULL)` variable to a non-empty value. For developers working on the top-level project and one or more dependencies at the same time, Erlang.mk now accepts a variable/function called `$(force_rebuilding_dep)` which is called to determine if the dependency passed as the first argument should be forcibly rebuilt. It allows a developer to filter the dependencies he works on (so they are always rebuilt) from other third-party dependencies he never touches (i.e. they are only built once at the beginning). The content of `$(force_rebuilding_dep)` is expected to be a shell one-liner where the `$(1)` Make variable is set to the path to the dependency. Here is an example from the testsuite: force_rebuilding_dep = test '$(1)' = '$(CURDIR)/deps/cowlib'
2019-06-24Skip the "rebuild" part of the "ln" test on WindowsLoïc Hoguin
By default MSYS2 will copy and not link, altering Erlang.mk's behavior. To properly link an option must be enabled and administrative privileges granted.
2019-06-24Use cowlib master in testsLoïc Hoguin
The old Cowlib's Erlang.mk does not work on Windows.
2019-06-22Fix the eunit-test-dir test on WindowsLoïc Hoguin
It was using os:cmd("echo ...") which on Windows preserves spaces. One possible fix would have been to remove the space, but I instead removed the use of os:cmd("echo ...") to avoid similar issues in the future.
2019-06-21Test `list-deps` behavior with various values of `FULL`Jean-Sébastien Pédron
Here, we want to make sure that `list-deps` always lists all dependencies, no matter if they are up-to-date or not. I.e. we want to always visit them and list them recursively.
2019-06-21Include applications `$(APPS_DIR)` in the `list-deps` targetsJean-Sébastien Pédron
In the case of a multi-applications repository, if one application depends on another one (using `$(LOCAL_DEPS)`), it will now be listed in the `list-deps` targets. Add `ssl` to the `$(LOCAL_DEPS)` in the testcase to ensure that applications not in `$(APPS_DIR)` are not affected by this change. Add a changelog entry.
2019-06-20Try a fix for the relx-start-stop intermittent test failureLoïc Hoguin
2019-06-20Use echo(1) instead of printf(1) in `core-autopatch-extended-erlc-opts`Jean-Sébastien Pédron
... to create the `autopatch-couchbeam` recipe in the testcase. Newlines characters were interpreted by echo(1) in the `core-autopatch-extended-erlc-opts` recipe which was too early: the generated recipe was malformed. Using echo(1) and its implicit appended newline character fixes the issue.
2019-06-20Replace zipinfo(1) by `unzip -l`Jean-Sébastien Pédron
The output is the same between those two commands. The benefit is that it avoids the need to install the `unzip` package on FreeBSD and all systems where the default unzip(1) is provided by libarchive.
2019-01-02Fix rebuild on Makefile change when new deps are addedLoïc Hoguin
The issue was that when a new dep is added the last-makefile-change update was done in the dependency and not in the top-level Makefile, preventing the rebuild of the top-level project. A test was also added to do the same when editing dependencies and things seem to work properly in that case. Thanks to robinchew on IRC for the great help debugging this.
2018-12-11Remove some silencing of release commandsLoïc Hoguin
Wondering if that's not what creates issues in CI sometimes. Also doesn't silence much anyway so it's not very useful.
2018-12-07Autopatch: allow configuring REBAR_GIT and REBAR_COMMITLoïc Hoguin
And use this in the tests to fetch Rebar only once and then clone from the local repository. This should speed up tests a little.
2018-12-07Make sure we go through all deps when building escriptsLoïc Hoguin
2018-12-07Add COVER_APPS and COVER_DEPS to cover compile other apps/depsLoïc Hoguin
By default COVER_APPS will cover compile all apps. COVER_DEPS will not cover compile any dependency by default, however.
2018-12-06Add cover support for PropEr and TriqLoïc Hoguin
2018-12-06Default COVER_DATA_DIR now the same as COVER_REPORT_DIRLoïc Hoguin
We have a dedicated folder for cover stuff, let's use it.
2018-12-05Fix verbosity of proper and triq testsLoïc Hoguin
2018-12-05Allow hooking before/after autopatchLoïc Hoguin
2018-12-04Fix and document Dialyzer against beam filesLoïc Hoguin
2018-12-04Delete $(ERLANG_MK_TMP) directory after 'make erlang-mk'Loïc Hoguin
This allows refreshing tools at the same time Erlang.mk gets updated.
2018-12-03Print a changelog when updating Erlang.mkLoïc Hoguin
2018-12-03Don't rebuild dependencies by defaultLoïc Hoguin
Unless it's a symbolic link, it's built directly, FULL=1 is set or the file ebin/dep_built in the dependency is removed. See the documentation changes for more details. This provides immense build speed gains, for example on a RabbitMQ project it went from 10s to 1s for the 2nd+ builds.
2018-12-03Move autopatch tests into their own test suiteLoïc Hoguin
2018-11-30Validate the .app file after generating itLoïc Hoguin
2018-11-30Fix Dialyzer when a project has and uses parse transformsLoïc Hoguin
2018-11-30Correct expanding of shell variables in autopatchLoïc Hoguin
The $(...) form was improperly converted. In addition it must be changed into a $(shell ...) form.
2018-11-30Add test for plugins that include the word rebarLoïc Hoguin
Seems that was fixed a while ago.
2018-11-30Add autopatch for LFE projectsLoïc Hoguin
Currently experimental. It'll enable lfe.mk when it encounters the rebar3 plugin lfe-compile. Tested against some small library. Note that it adds lfe as a build dependency with no version given so the latest master will be fetched right now. This can be overriden in the parent project.
2018-11-29Add the target help-plugins to document external pluginsLoïc Hoguin
It's better than extending help:: because this gets printed at the end instead of before Erlang.mk's own help.
2018-11-29Rebuild C projects when Makefiles changeLoïc Hoguin
2018-11-28Rename the rel/ directory to config/ by defaultLoïc Hoguin
2018-11-28Add option DTL_PREFIX for erlydtl-produced module namesLoïc Hoguin
2018-11-28Fix asn1 compilation with the +maps optionLoïc Hoguin
When this option is used no include file is generated. Therefore don't error out if no include file can be found.
2018-11-28Add built-in support for gpb for building proto filesLoïc Hoguin
When gpb is found in DEPS or BUILD_DEPS then it is used instead of erlang_protobuffs.
2018-11-28Modernize the protobuffs pluginLoïc Hoguin
2018-11-27Fix jobserver unavailable warningsLoïc Hoguin
When the $(MAKE) is inside an $(eval $(call ...)) then it needs to be escaped as $$(MAKE). When the $(MAKE) is inside a $(call ...) then I did not figure out a way other than passing it as an argument. When the $(MAKE) is inside many levels of $(call $(call ...)) it's easier to avoid it if at all possible, so I replaced the rebar $(MAKE) call with ./bootstrap. I confirmed it works fine on Windows as well.
2018-11-26Allow running test cases without groups in CTLoïc Hoguin
2018-11-26Remove a non-portable "echo -n" from a testLoïc Hoguin
2018-11-26Remove some non-portable "echo -e" from a couple testsLoïc Hoguin