]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
test: bump DecayCounter.steady acceptable error 48031/head
authorPatrick Donnelly <pdonnell@redhat.com>
Thu, 15 Apr 2021 13:57:57 +0000 (06:57 -0700)
committerIlya Dryomov <idryomov@gmail.com>
Fri, 9 Sep 2022 06:46:23 +0000 (08:46 +0200)
The test is often run on heavily loaded machines which will effect the
precision of the test.

Fixes: https://tracker.ceph.com/issues/50378
Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
(cherry picked from commit 9a369ef119dbc10c0dbf6da286a8eb6faa14606c)

src/test/common/test_counter.cc

index 942d2a7e530c0cf8eea569a4260f7b47642d20ad..f9a7d6e6c6203b6e91519d43f614624fbddef2b4 100644 (file)
@@ -36,5 +36,5 @@ TEST(DecayCounter, steady)
    */
   double expected = -1*std::log(0.5)/rate*max*duration;
   std::cerr << "t " << total << " e " << expected << std::endl;
-  ASSERT_LT(std::abs(total-expected)/expected, 0.01);
+  ASSERT_LT(std::abs(total-expected)/expected, 0.05);
 }