如何更改 rebar3 配置中 eunit 的超时时间?
当我运行基于属性的 Triq 测试时,我的 eunit 运行器超时:
===> Verifying dependencies...
===> Compiling ierminer
===> Performing EUnit tests...
Pending:
test_ec:ec_prop_test/0
%% Unknown error: timeout
undefined
%% Unknown error: {blame,[3,1]}
Finished in ? seconds
3 tests, 0 failures, 3 cancelled
===> Error running tests
这是我的属性规范:
-module(ec_property).
-include_lib("triq/include/triq.hrl").
prop_append() ->
?FORALL({Xs,Ys},{list(int()),list(int())},
lists:reverse(Xs++Ys)
==
lists:reverse(Ys) ++ lists:reverse(Xs)).
prop_valid_started() ->
?FORALL({Type, Items, Size},
{oneof([left,right]), non_empty(list(any())), pos_integer()},
element(1, ec:start(Type, Items, Size)) == ok).
这是我从我的 eunit 测试函数中调用它的方式:
ec_prop_test() -> ?assert(ec_property:check()).