diff options
author | Anders Svensson <anders@erlang.org> | 2022-02-25 11:15:51 +0100 |
---|---|---|
committer | Anders Svensson <anders@erlang.org> | 2022-03-17 11:04:54 +0100 |
commit | d42d0fe0a89d115caa596c229c1c758c4859ee44 (patch) | |
tree | 4e98eb373dcdab44bd3c59b2c6714ad5d4bec300 /lib/diameter/test/diameter_gen_sctp_SUITE.erl | |
parent | 0dad730b654044a308777be4c7a67077dbe9ed47 (diff) | |
download | erlang-d42d0fe0a89d115caa596c229c1c758c4859ee44.tar.gz |
Rework remaining diameter testsuites
As in the previous two commit: remove common_test as a requirement and
make all testcases independent. Add a make target for running any suite
without common test; for example, to run all testcases in
diameter_dpr_SUITE:
make _dpr
Similar to the target that runs suites with common_test, just add an
underscore prefix.
Diffstat (limited to 'lib/diameter/test/diameter_gen_sctp_SUITE.erl')
-rw-r--r-- | lib/diameter/test/diameter_gen_sctp_SUITE.erl | 37 |
1 files changed, 23 insertions, 14 deletions
diff --git a/lib/diameter/test/diameter_gen_sctp_SUITE.erl b/lib/diameter/test/diameter_gen_sctp_SUITE.erl index ccee6baec1..7a3dae723d 100644 --- a/lib/diameter/test/diameter_gen_sctp_SUITE.erl +++ b/lib/diameter/test/diameter_gen_sctp_SUITE.erl @@ -1,7 +1,7 @@ %% %% %CopyrightBegin% %% -%% Copyright Ericsson AB 2010-2017. All Rights Reserved. +%% Copyright Ericsson AB 2010-2022. All Rights Reserved. %% %% Licensed under the Apache License, Version 2.0 (the "License"); %% you may not use this file except in compliance with the License. @@ -27,14 +27,19 @@ -module(diameter_gen_sctp_SUITE). +%% testcases, no common_test dependency +-export([run/0, + run/1]). + +%% common_test wrapping -export([suite/0, all/0, init_per_suite/1, end_per_suite/1]). %% testcases --export([send_one_from_many/1, send_one_from_many/0, - send_many_from_one/1, send_many_from_one/0, +-export([send_one_from_many/1, + send_many_from_one/1, receive_what_was_sent/1]). -include_lib("kernel/include/inet_sctp.hrl"). @@ -67,7 +72,7 @@ %% =========================================================================== suite() -> - [{timetrap, {seconds, 10}}]. + [{timetrap, {seconds, 15}}]. all() -> [send_one_from_many, @@ -89,13 +94,20 @@ end_per_suite(_Config) -> %% =========================================================================== -%% send_one_from_many/0 +%% run/0 + +run() -> + run(all()). + +%% run/1 + +run(List) -> + diameter_util:run([{{?MODULE, F, [[]]}, 10000} || F <- List]). + +%% send_one_from_many/1 %% %% Demonstrates sluggish delivery of messages. -send_one_from_many() -> - [{timetrap, {seconds, 30}}]. - send_one_from_many(_) -> ?OK = send_multiple(128, 1, 1024). @@ -402,23 +414,20 @@ unmark(Bin) -> %% =========================================================================== -%% send_many_from_one/0 +%% send_many_from_one/1 %% %% Demonstrates sluggish delivery of messages. -send_many_from_one() -> - [{timetrap, {seconds, 30}}]. - send_many_from_one(_) -> ?OK = send_multiple(1, 128, 1024). %% =========================================================================== -%% receive_what_was_sent/1 +%% receive_what_was_sent/0 %% %% Demonstrates reception of a message that differs from that sent. -receive_what_was_sent(_Config) -> +receive_what_was_sent(_) -> ?OK = send_multiple(1, 1, 1024*32). %% =========================================================================== |