aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Arts <[email protected]>2014-09-11 20:28:23 +0200
committerHans Nilsson <[email protected]>2014-09-18 10:09:40 +0200
commit14418409c971cf20f5db35f8ff33713b1924c20a (patch)
tree92aad82a098775a3232349030d08409e4db0e3b2
parentfccdd825e41006b36137cebf4b2059682f82c2eb (diff)
downloadotp-14418409c971cf20f5db35f8ff33713b1924c20a.tar.gz
otp-14418409c971cf20f5db35f8ff33713b1924c20a.tar.bz2
otp-14418409c971cf20f5db35f8ff33713b1924c20a.zip
Reduce the total testing time for the properties to 20 seconds
We need to make a global budget for testing on CI server and then define for each property how much it may use of that time. Probably in auxiliary file, such that it can be computed from what has changed in the repo.
-rw-r--r--lib/ssh/test/property_test/ssh_eqc_client_server.erl14
1 files changed, 9 insertions, 5 deletions
diff --git a/lib/ssh/test/property_test/ssh_eqc_client_server.erl b/lib/ssh/test/property_test/ssh_eqc_client_server.erl
index 3fc7a15dd0..669aa5b5e0 100644
--- a/lib/ssh/test/property_test/ssh_eqc_client_server.erl
+++ b/lib/ssh/test/property_test/ssh_eqc_client_server.erl
@@ -32,6 +32,10 @@
-else.
+%% Limit the testing time on CI server... this needs to be improved in % from total budget.
+-define(TESTINGTIME(Prop), eqc:testing_time(30,Prop)).
+
+
-include_lib("eqc/include/eqc.hrl").
-include_lib("eqc/include/eqc_statem.hrl").
-eqc_group_commands(true).
@@ -97,7 +101,7 @@
%% To be called as eqc:quickcheck( ssh_eqc_client_server:prop_seq() ).
prop_seq() ->
- do_prop_seq(?SSH_DIR).
+ ?TESTINGTIME(do_prop_seq(?SSH_DIR)).
%% To be called from a common_test test suite
prop_seq(CT_Config) ->
@@ -116,7 +120,7 @@ full_path(SSHdir, CT_Config) ->
SSHdir).
%%%----
prop_parallel() ->
- do_prop_parallel(?SSH_DIR).
+ ?TESTINGTIME(do_prop_parallel(?SSH_DIR)).
%% To be called from a common_test test suite
prop_parallel(CT_Config) ->
@@ -131,7 +135,7 @@ do_prop_parallel(DataDir) ->
%%%----
prop_parallel_multi() ->
- do_prop_parallel_multi(?SSH_DIR).
+ ?TESTINGTIME(do_prop_parallel_multi(?SSH_DIR)).
%% To be called from a common_test test suite
prop_parallel_multi(CT_Config) ->
@@ -171,7 +175,7 @@ weight(_S, _) -> 1.
initial_state_pre(S) -> not S#state.initialized.
-initial_state_args(S) -> [{var,data_dir}].
+initial_state_args(_) -> [{var,data_dir}].
initial_state_next(S, _, _) -> S#state{initialized=true}.
@@ -182,7 +186,7 @@ initial_state_next(S, _, _) -> S#state{initialized=true}.
ssh_server_pre(S) -> S#state.initialized andalso
length(S#state.servers) < ?MAX_NUM_SERVERS.
-ssh_server_args(S) -> [?SERVER_ADDRESS, {var,data_dir}, ?SERVER_EXTRA_OPTIONS].
+ssh_server_args(_) -> [?SERVER_ADDRESS, {var,data_dir}, ?SERVER_EXTRA_OPTIONS].
ssh_server({IP,Port}, DataDir, ExtraOptions) ->
ok(ssh:daemon(IP, Port,