MCPcopy Create free account
hub / github.com/ParzivalHack/PySpector / test_constant_safe

Method test_constant_safe

tests/unit/test_a_sink_rules.py:41–42  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

39 # generates FPs on stdlib code that uses hasattr for duck-typing checks.
40 assert not_fires("attr=request.GET.get('f'); hasattr(obj,attr)", "HASATTR837")
41 def test_constant_safe(self):
42 assert not_fires("hasattr(obj,'is_active')", "HASATTR837")
43
44# --- VARS840 ---
45class TestVars840:

Callers

nothing calls this directly

Calls 1

not_firesFunction · 0.70

Tested by

no test coverage detected