diff --git a/tests/test_utils_richcfg.py b/tests/test_utils_richcfg.py index 10ea78138..0ba50dc21 100644 --- a/tests/test_utils_richcfg.py +++ b/tests/test_utils_richcfg.py @@ -93,7 +93,10 @@ def test_rich_inspector_outputs_more_than_builtin(monkeypatch): assert "name = 'Alice'" in rich_text # Built-in inspector does NOT show instance values - assert "30" not in builtin_text + assert "30" not in "\n".join( + line for line in builtin_text.splitlines() + if not line.strip().startswith("String form:") # id in this line that can contain the number 30 + ) assert "Alice" not in builtin_text # Built-in inspector only shows the raw __init__ function