From e73d368158ba3107f2f0cac271b9713dd1f7be1d Mon Sep 17 00:00:00 2001 From: ptrcnull Date: Mon, 5 Jun 2023 23:56:46 +0200 Subject: [PATCH] Fix thread context tests failing on 32-bit Python's hash() function returns 32-bit values on 32-bit architectures; the values were acquired by running 'hash((200, 100))' on i386/alpine:edge (Python 3.11.3) and i386/alpine:3.8 (Python 3.6.9) --- tests/test_dom_tag.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/test_dom_tag.py b/tests/test_dom_tag.py index 43ffecb..173fcb9 100644 --- a/tests/test_dom_tag.py +++ b/tests/test_dom_tag.py @@ -20,6 +20,8 @@ def test___get_thread_context(monkeypatch): assert sut._get_thread_context() in [ -6805948436281256182, # Python >= 3.9 3713141171098444831, # Python < 3.9 + 1692341442, # Python >= 3.9, 32-bit + -667720673, # Python < 3.9, 32-bit ] def test_add_raw_string():