diff options
-rw-r--r-- | README.md | 5 | ||||
-rw-r--r-- | erlang.mk | 2 | ||||
-rw-r--r-- | plugins/ct.mk | 2 |
3 files changed, 5 insertions, 4 deletions
@@ -186,8 +186,9 @@ also the tests themselves. Unlike `ERLC_OPTS` it doesn't consider warnings to be errors and does not warn when `export_all` is used. `CT_SUITES` is the list of common_test suites to run when you use -the `make tests` command. If your suite module is named `ponies_SUITE` -then you only need to put `ponies` in the list. +the `make tests` command. The default behaviour is to autodetect your +common_test suites. If you only want to run the tests in `ponies_SUITE` +you should set this variable to `ponies`. `CT_OPTS` allows you to specify extra common_test options. @@ -232,7 +232,7 @@ CT_RUN = ct_run \ -dir test \ -logdir logs -CT_SUITES ?= +CT_SUITES ?= $(sort $(subst _SUITE.erl,,$(shell find test -type f -name \*_SUITE.erl -exec basename {} \;))) define test_target test_$(1): ERLC_OPTS = $(TEST_ERLC_OPTS) diff --git a/plugins/ct.mk b/plugins/ct.mk index a6d8f52..a27cc46 100644 --- a/plugins/ct.mk +++ b/plugins/ct.mk @@ -6,7 +6,7 @@ # Configuration. CT_OPTS ?= -CT_SUITES ?= +CT_SUITES ?= $(sort $(subst _SUITE.erl,,$(shell find test -type f -name \*_SUITE.erl -exec basename {} \;))) TEST_ERLC_OPTS ?= +debug_info +warn_export_vars +warn_shadow_vars +warn_obsolete_guard TEST_ERLC_OPTS += -DTEST=1 -DEXTRA=1 +'{parse_transform, eunit_autoexport}' |