Просмотр исходного кода

Use ct_run instead of rebar ct for running ct tests

Small tweak to the autobahn test file, we look for the python2
executable now. It'll make my life easier.
Loïc Hoguin 12 лет назад
Родитель
Сommit
7d2a481401
3 измененных файлов с 14 добавлено и 7 удалено
  1. 13 6
      Makefile
  2. 1 1
      test/autobahn_SUITE_data/test.py
  3. 0 0
      test/cover.spec

+ 13 - 6
Makefile

@@ -2,7 +2,6 @@
 
 PROJECT = cowboy
 
-DIALYZER = dialyzer
 REBAR = rebar
 
 all: app
@@ -37,19 +36,27 @@ deps/proper:
 
 tests: clean deps/proper app eunit ct
 
-inttests: clean deps/proper app eunit intct
-
 eunit:
 	@$(REBAR) -C rebar.tests.config eunit skip_deps=true
 
+CT_RUN = ct_run \
+	-pa ebin deps/*/ebin \
+	-dir test \
+	-logdir logs \
+	-cover test/cover.spec
+
 ct:
-	@$(REBAR) -C rebar.tests.config ct skip_deps=true suites=http,ws
+	@mkdir -p logs/
+	@$(CT_RUN) -suite http_SUITE ws_SUITE
 
-intct:
-	@$(REBAR) -C rebar.tests.config ct skip_deps=true suites=http,ws,autobahn
+autobahn:
+	@mkdir -p logs/
+	@$(CT_RUN) -suite autobahn_SUITE
 
 # Dialyzer.
 
+DIALYZER = dialyzer
+
 build-plt:
 	@$(DIALYZER) --build_plt --output_plt .$(PROJECT).plt \
 		--apps kernel stdlib sasl inets crypto public_key ssl deps/*

+ 1 - 1
test/autobahn_SUITE_data/test.py

@@ -1,4 +1,4 @@
-#!/usr/bin/env python
+#!/usr/bin/env python2
 import os
 import os.path
 import sys

+ 0 - 0
cover.spec → test/cover.spec