diff options
author | Nick Vatamaniuc <vatamane@gmail.com> | 2023-01-26 00:09:25 -0500 |
---|---|---|
committer | Nick Vatamaniuc <vatamane@gmail.com> | 2023-01-26 11:18:52 -0500 |
commit | 86d7ee64689c9a37d37269885c612883b0377c8d (patch) | |
tree | a41e686c152ed0154938a93b4cdf94e6adb0bcfb | |
parent | 075d596dffd899c46c36479b7530b29ec48da8a7 (diff) | |
download | couchdb-fix-flaky-windows-test.tar.gz |
Fix flaky chttpd_changes_testfix-flaky-windows-test
We made too strong of an assumption there that even in the case of Q=8 we'd
always have 2 pending changes, which is incorrect. The tests on Windows
apprently revealed an error where it returned 0. So let's relax the assumption
to assert that pending would be >= 0 and something less than 7.
-rw-r--r-- | src/chttpd/test/eunit/chttpd_changes_test.erl | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/chttpd/test/eunit/chttpd_changes_test.erl b/src/chttpd/test/eunit/chttpd_changes_test.erl index f780118c6..f1eb32924 100644 --- a/src/chttpd/test/eunit/chttpd_changes_test.erl +++ b/src/chttpd/test/eunit/chttpd_changes_test.erl @@ -370,7 +370,7 @@ t_design_filter({_, DbUrl}) -> Params = "?filter=_design", {Seq, Pending, Rows} = changes(DbUrl, Params), ?assertEqual(7, Seq), - ?assertEqual(2, Pending), + ?assert(is_integer(Pending), Pending >= 0 andalso Pending < 7), ?assertMatch([{_, {?DDOC2, <<"2-c">>}, ?LEAFREV}], Rows). t_docs_id_filter({_, DbUrl}) -> |