From f07636e66759ecdaff4ee4e9097ecbf88eb6b217 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Hoguin?= Date: Mon, 26 Nov 2018 23:46:31 +0100 Subject: Allow running test cases without groups in CT --- test/plugin_ct.mk | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) (limited to 'test/plugin_ct.mk') diff --git a/test/plugin_ct.mk b/test/plugin_ct.mk index e58f01b..0aaf1ea 100644 --- a/test/plugin_ct.mk +++ b/test/plugin_ct.mk @@ -151,6 +151,25 @@ ct-case: build clean $i "Check that we can run Common Test on a specific test case" $t $(MAKE) -C $(APP) ct-$(APP) t=mygroup:ok $v +ct-case-without-group: build clean + + $i "Bootstrap a new OTP application named $(APP)" + $t mkdir $(APP)/ + $t cp ../erlang.mk $(APP)/ + $t $(MAKE) -C $(APP) -f erlang.mk bootstrap $v + + $i "Generate a Common Test suite with two cases that are not part of any group" + $t mkdir $(APP)/test + $t printf "%s\n" \ + "-module($(APP)_SUITE)." \ + "-export([all/0, ok/1, bad/1])." \ + "all() -> [ok, bad]." \ + "ok(_) -> ok." \ + "bad(_) -> throw(fail)." > $(APP)/test/$(APP)_SUITE.erl + + $i "Check that we can run Common Test on a specific test case" + $t $(MAKE) -C $(APP) ct-$(APP) c=ok $v + ct-check: build clean $i "Bootstrap a new OTP application named $(APP)" -- cgit v1.2.3