diff --git a/tests/test_pysnooper.py b/tests/test_pysnooper.py index ade570c..22e5e4c 100644 --- a/tests/test_pysnooper.py +++ b/tests/test_pysnooper.py @@ -1233,8 +1233,12 @@ def test_disable(): return x + y with mini_toolbox.TempValueSetter((pysnooper.tracer, 'DISABLED'), True): - with pysnooper.snoop(string_io): + tracer = pysnooper.snoop(string_io) + with tracer: result = my_function('baba') + my_decorated_function = tracer(my_function) + my_decorated_function('booboo') + output = string_io.getvalue() assert not output