You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by va...@apache.org on 2021/03/12 21:51:25 UTC
[couchdb] branch main updated: Fix more couch_jobs flakiness
This is an automated email from the ASF dual-hosted git repository.
vatamane pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/couchdb.git
The following commit(s) were added to refs/heads/main by this push:
new c508efe Fix more couch_jobs flakiness
c508efe is described below
commit c508efedcabd560449e4dcbd7774a04b3907257e
Author: Nick Vatamaniuc <va...@apache.org>
AuthorDate: Fri Mar 12 16:12:05 2021 -0500
Fix more couch_jobs flakiness
The errors see in #3417 seem to indicate the expiration jobs are interfering
with the couch_jobs tests, to prevent that prevent expiration_db job gen_server
from starting at all.
Fixes #3417
---
src/couch_jobs/test/couch_jobs_tests.erl | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/src/couch_jobs/test/couch_jobs_tests.erl b/src/couch_jobs/test/couch_jobs_tests.erl
index b40e52e..3582c64 100644
--- a/src/couch_jobs/test/couch_jobs_tests.erl
+++ b/src/couch_jobs/test/couch_jobs_tests.erl
@@ -78,10 +78,21 @@ couch_jobs_basic_test_() ->
setup_couch() ->
+ % Because of a circular dependency between `couch_jobs` and `fabric` in
+ % `fabric2_db_expiration` module, disable db expiration so when
+ % `couch_jobs` is stopped the test, `fabric` app doesn't get torn down as
+ % well and we don't see spurious <<"db_expiration">> jobs show up in test
+ % results.
+ meck:new(fabric2_db_expiration, [passthrough]),
+ meck:expect(fabric2_db_expiration, handle_info, fun
+ (timeout, St) -> {noreply, St};
+ (Msg, St) -> meck:passthrough([Msg, St])
+ end),
test_util:start_couch([fabric]).
teardown_couch(Ctx) ->
+ meck:unload(),
test_util:stop_couch(Ctx).