From 2994cded4968fa3fbf9f6178c224f3b1f62f3ea5 Mon Sep 17 00:00:00 2001 From: Eric Avdey Date: Thu, 5 Jan 2017 17:30:00 -0400 Subject: [PATCH] Fix couchdb_views tests Previous commit made couch_file to monitor db_pid instead of linking ot it, so number of monitored_by for couch_db process, checked in couchdb_views_tests, changed. COUCHDB-3259 --- test/couchdb_views_tests.erl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/couchdb_views_tests.erl b/test/couchdb_views_tests.erl index 289ecb83..7b04e852 100644 --- a/test/couchdb_views_tests.erl +++ b/test/couchdb_views_tests.erl @@ -529,8 +529,9 @@ view_cleanup(DbName) -> count_users(DbName) -> {ok, Db} = couch_db:open_int(DbName, [?ADMIN_CTX]), {monitored_by, Monitors} = erlang:process_info(Db#db.main_pid, monitored_by), + CouchFiles = [P || P <- Monitors, couch_file:process_info(P) =/= undefined], ok = couch_db:close(Db), - length(lists:usort(Monitors) -- [self()]). + length(lists:usort(Monitors) -- [self() | CouchFiles]). count_index_files(DbName) -> % call server to fetch the index files