2018-07-31 07:51:12 +00:00
|
|
|
-module(woody_joint_workers_SUITE).
|
2021-01-15 12:35:41 +00:00
|
|
|
|
2018-07-31 07:51:12 +00:00
|
|
|
-include_lib("common_test/include/ct.hrl").
|
MSPF-428: Erlang OTP 21 to master (#86)
* MSPF-394/Migrate woody_erlang to cowboy 2.5.0 (#82)
* Renewed some old cowboy syntax
* Reworked types to fit new cowboy/ranch versions
* Replaced cowboy tuples with separate values
* Fixed types, deleted testing logs, deleted redundant errors
* Moved to new StackTrace retrieval syntax for Erlang/OTP 21
* Restored default config, fixed typing
* Cleaned unnessesary changes, removed export_all
* Restored genlib cached version
* Downgraded to old stacktrace retrieval syntax, fixed codestyle
* Restored new StackTrace retrieval syntax, updated build image
* Changed rebar3 version for CI
* Corrected typing and spelling, removed unnessesary supervisor
* Created stream handler to replace hooks
* Added options for reading body
* Simplified stream handler
* Fixed wrong module name, added read body options support in stream handler
* Puted read body opts to env, renamed stream handler
* Codestyle, types and config fixes
* Moved response tracing to a separate function, now tracing failed requests too
* Changed options to map (#83)
* Fixed wrong timeout override logic (#84)
* Patch merge conflict
* Bump dependencies (#87)
* bumped hackney
* bumped erlang thrift commit
2019-03-28 14:52:17 +00:00
|
|
|
|
|
|
|
-export([
|
|
|
|
all/0,
|
|
|
|
init_per_suite/1,
|
|
|
|
end_per_suite/1
|
|
|
|
]).
|
|
|
|
|
|
|
|
-export([prop_test/1]).
|
2018-07-31 07:51:12 +00:00
|
|
|
|
2019-04-19 11:18:32 +00:00
|
|
|
-type config() :: [{atom(), any()}].
|
|
|
|
-type case_name() :: atom().
|
|
|
|
|
|
|
|
-spec all() -> [case_name()].
|
|
|
|
-spec init_per_suite(config()) -> config().
|
|
|
|
-spec end_per_suite(config()) -> any().
|
|
|
|
-spec prop_test(config()) -> ok.
|
|
|
|
|
2018-07-31 07:51:12 +00:00
|
|
|
%%
|
|
|
|
%% tests descriptions
|
|
|
|
%%
|
|
|
|
all() ->
|
|
|
|
[
|
|
|
|
prop_test
|
|
|
|
].
|
|
|
|
|
|
|
|
%%
|
|
|
|
%% starting/stopping
|
|
|
|
%%
|
|
|
|
init_per_suite(C) ->
|
|
|
|
% dbg:tracer(), dbg:p(all, c),
|
|
|
|
% dbg:tpl({woody_joint_workers, do, 4}, x),
|
|
|
|
|
|
|
|
{ok, Apps} = application:ensure_all_started(woody),
|
2021-01-15 12:35:41 +00:00
|
|
|
[{apps, Apps} | C].
|
2018-07-31 07:51:12 +00:00
|
|
|
|
|
|
|
end_per_suite(C) ->
|
|
|
|
[application:stop(App) || App <- ?config(apps, C)].
|
|
|
|
|
|
|
|
%%
|
|
|
|
%% tests
|
|
|
|
%%
|
2021-08-11 19:24:08 +00:00
|
|
|
|
|
|
|
%% Suppress proper's internal type mismatch for setup generator
|
|
|
|
-dialyzer([no_return, no_opaque]).
|
2018-07-31 07:51:12 +00:00
|
|
|
prop_test(_C) ->
|
|
|
|
R = proper:quickcheck(
|
2021-01-15 12:35:41 +00:00
|
|
|
woody_joint_workers_pt:prop_test(),
|
|
|
|
% default options
|
|
|
|
[noshrink]
|
|
|
|
),
|
2018-07-31 07:51:12 +00:00
|
|
|
case R of
|
2021-01-15 12:35:41 +00:00
|
|
|
true -> ok;
|
2018-07-31 07:51:12 +00:00
|
|
|
Error -> exit(Error)
|
|
|
|
end.
|