summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Avdey <eiri@eiri.ca>2018-01-22 16:34:26 -0400
committerEric Avdey <eiri@eiri.ca>2018-01-22 16:34:26 -0400
commit91f5985e224db1936c41d6bf31eddba27f90bf98 (patch)
tree9777761329c5c3143b58f7ee337514e9edb40593
parent0fd950905a76f3eaab685fc361bd3f38471761d5 (diff)
downloadcouchdb-91f5985e224db1936c41d6bf31eddba27f90bf98.tar.gz
Set eunit timeout on a whole test objectfix-create_delete_database_continuously-test
-rw-r--r--src/couch/test/couch_db_tests.erl10
1 files changed, 4 insertions, 6 deletions
diff --git a/src/couch/test/couch_db_tests.erl b/src/couch/test/couch_db_tests.erl
index 62e059070..d64f7c640 100644
--- a/src/couch/test/couch_db_tests.erl
+++ b/src/couch/test/couch_db_tests.erl
@@ -128,15 +128,13 @@ should_delete_multiple_dbs(DbNames) ->
should_create_delete_database_continuously(Times, DbName) ->
{lists:flatten(io_lib:format("~b times", [Times])),
- ?_test(begin
+ {timeout, ?TIMEOUT, ?_test(begin
?assert(create_db(DbName)),
lists:foreach(fun(_) ->
- {timeout, ?TIMEOUT, [
- ?assert(delete_db(DbName)),
- ?assert(create_db(DbName))
- ]}
+ ?assert(delete_db(DbName)),
+ ?assert(create_db(DbName))
end, lists:seq(1, Times))
- end)}.
+ end)}}.
should_create_db_if_missing(DbName) ->
?_test(begin