test_lazy_tool: pick a non-MATERIALIZE_OK attr for strict-raise test

``tool_action`` graduated to ``_MATERIALIZE_OK`` in the previous commit
(it's read on the execute path). The strict-raise assertion needs an
attribute the stub neither forwards nor materialises;
``totally_not_a_tool_attr`` is guaranteed unaccounted-for.
This commit is contained in:
mvdbeek
2026-07-28 17:27:20 +02:00
parent 39c5552f2b
commit b71b2847af
+6 -2
View File
@@ -167,9 +167,13 @@ def test_allow_user_access_allows_admin_for_data_manager():
def test_strict_getattr_raises_with_clear_message():
t = _stub()
# Pick an attribute that is *not* on the forwarded surface and not in
# ``_MATERIALIZE_OK`` so the strict path fires. (``tool_action`` used to
# live here but is now a materialise-OK attr; ``totally_not_a_tool_attr``
# is guaranteed unaccounted-for.)
with pytest.raises(NotImplementedError) as ei:
_ = t.tool_action
assert "tool_action" in str(ei.value)
_ = t.totally_not_a_tool_attr
assert "totally_not_a_tool_attr" in str(ei.value)
assert "bowtie2" in str(ei.value)