From d699c9ace8028bf74e1c6c3ea085fdf9beeb2586 Mon Sep 17 00:00:00 2001 From: Theron Luhn Date: Sat, 14 Dec 2019 19:12:01 -0600 Subject: Raise error on kwargs in `LegacySecurityPolicy.forget`. --- tests/test_security.py | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'tests/test_security.py') diff --git a/tests/test_security.py b/tests/test_security.py index 715d99804..1c969e305 100644 --- a/tests/test_security.py +++ b/tests/test_security.py @@ -466,6 +466,12 @@ class TestLegacySecurityPolicy(unittest.TestCase): policy.forget(request), [('X-Pyramid-Test', 'logout')] ) + def test_forget_with_kwargs(self): + from pyramid.security import LegacySecurityPolicy + + policy = LegacySecurityPolicy() + self.assertRaises(ValueError, lambda: policy.forget(None, foo='bar')) + def test_permits(self): from pyramid.security import LegacySecurityPolicy -- cgit v1.2.3