summaryrefslogtreecommitdiff
path: root/inttest
diff options
context:
space:
mode:
authorFred Hebert <mononcqc@ferd.ca>2014-07-15 08:20:38 -0400
committerFred Hebert <mononcqc@ferd.ca>2014-07-15 08:20:38 -0400
commit7f7e36740f17a7e8a5193c1cdebbedf7cda05a8b (patch)
treeb1e3c26adaf9b095499ba21c781ad7b911620f4d /inttest
parent0d1ae7a4683b1e4a305eb848e70ec641984a1067 (diff)
parentdcfa6daf30cbd7bd1e570636d1ec76fda799eb26 (diff)
Merge branch 'NineFX-erl-args-to-end'
Diffstat (limited to 'inttest')
-rw-r--r--inttest/ct1/app.config2
-rw-r--r--inttest/ct1/ct1_rt.erl2
-rw-r--r--inttest/ct1/rebar.config1
-rw-r--r--inttest/ct1/test_SUITE.erl8
4 files changed, 12 insertions, 1 deletions
diff --git a/inttest/ct1/app.config b/inttest/ct1/app.config
new file mode 100644
index 0000000..bb718b2
--- /dev/null
+++ b/inttest/ct1/app.config
@@ -0,0 +1,2 @@
+%% This file is an application config file, not a CT test config file
+[{a1, [{foo, bar}]}].
diff --git a/inttest/ct1/ct1_rt.erl b/inttest/ct1/ct1_rt.erl
index f173d3f..f9de372 100644
--- a/inttest/ct1/ct1_rt.erl
+++ b/inttest/ct1/ct1_rt.erl
@@ -7,10 +7,12 @@ files() ->
[{create, "ebin/a1.app", app(a1)},
{copy, "../../rebar", "rebar"},
{copy, "rebar.config", "rebar.config"},
+ {copy, "app.config", "app.config"},
{copy, "test_SUITE.erl", "itest/test_SUITE.erl"}].
run(_Dir) ->
{ok, _} = retest:sh("./rebar compile ct"),
+ {ok, _} = retest:sh("./rebar compile ct -v"),
ok.
diff --git a/inttest/ct1/rebar.config b/inttest/ct1/rebar.config
index a4b5284..58047ba 100644
--- a/inttest/ct1/rebar.config
+++ b/inttest/ct1/rebar.config
@@ -1 +1,2 @@
{ct_dir, "itest"}.
+{ct_extra_params, "-repeat 2 -erl_args -config app"}.
diff --git a/inttest/ct1/test_SUITE.erl b/inttest/ct1/test_SUITE.erl
index 92f2b2e..e8a2bb8 100644
--- a/inttest/ct1/test_SUITE.erl
+++ b/inttest/ct1/test_SUITE.erl
@@ -5,7 +5,13 @@
-include_lib("ct.hrl").
all() ->
- [simple_test].
+ [simple_test,
+ app_config_file_test].
simple_test(Config) ->
io:format("Test: ~p\n", [Config]).
+
+app_config_file_test(_Config) ->
+ application:start(a1),
+ {ok, bar} = application:get_env(a1, foo),
+ application:stop(a1).