Current section
Files
Jump to
Current section
Files
src/qcheck_gleeunit_utils@test_spec.erl
-module(qcheck_gleeunit_utils@test_spec).
-compile([no_auto_import, nowarn_unused_vars, nowarn_unused_function, nowarn_nomatch]).
-export([make/1, make_with_timeout/2, run_in_parallel/1, run_in_order/1]).
-export_type([test_spec/1, test_group/1]).
-opaque test_spec(FMS) :: {timeout, integer(), fun(() -> FMS)}.
-opaque test_group(FMT) :: {inparallel, list(test_spec(FMT))} |
{inorder, list(test_spec(FMT))}.
-spec make(fun(() -> FMU)) -> test_spec(FMU).
make(F) ->
{timeout, 2147483647, F}.
-spec make_with_timeout(integer(), fun(() -> FMW)) -> test_spec(FMW).
make_with_timeout(Timeout, F) ->
{timeout, Timeout, F}.
-spec run_in_parallel(list(test_spec(FMY))) -> test_group(FMY).
run_in_parallel(Test_specs) ->
{inparallel, Test_specs}.
-spec run_in_order(list(test_spec(FNC))) -> test_group(FNC).
run_in_order(Test_specs) ->
{inorder, Test_specs}.