From cae84e39554c6cf0e644054124099d59fcd52938 Mon Sep 17 00:00:00 2001 From: Florian Schepers Date: Tue, 23 Apr 2024 09:52:24 +0200 Subject: [PATCH] fix: Make flaky tests stable by rounding score values --- 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