From 3bb387582f443a9456bc39388d8c2015b3cc56c7 Mon Sep 17 00:00:00 2001 From: FlorianSchepersAA <163116895+FlorianSchepersAA@users.noreply.github.com> Date: Tue, 23 Apr 2024 10:40:52 +0200 Subject: [PATCH] fix: Make flaky tests stable by rounding score values (#771) --- tests/core/test_text_highlight.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/core/test_text_highlight.py b/tests/core/test_text_highlight.py index 7d78bc71d..e3277eb71 100644 --- a/tests/core/test_text_highlight.py +++ b/tests/core/test_text_highlight.py @@ -309,4 +309,4 @@ def test_highlight_clamps_end_correctly( # then assert result.highlights[0].start == start assert result.highlights[0].end == end - assert result.highlights[0].score == score + assert abs(result.highlights[0].score - score) <= 0.005