From dd3cc81f75dcb5ff96e0751653071722a15f46c2 Mon Sep 17 00:00:00 2001 From: Michael Merickel <michael@merickel.org> Date: Mon, 15 Oct 2018 06:46:11 +0200 Subject: [PATCH] fix the tests to import from the tests package instead of pyramid.tests --- tests/test_authentication.py | 30 +++++++++++++++--------------- 1 files changed, 15 insertions(+), 15 deletions(-) diff --git a/tests/test_authentication.py b/tests/test_authentication.py index 4efd76f..4fbc3fe 100644 --- a/tests/test_authentication.py +++ b/tests/test_authentication.py @@ -36,7 +36,7 @@ self.assertEqual(len(self.messages), 1) self.assertEqual( self.messages[0], - 'pyramid.tests.test_authentication.MyAuthenticationPolicy.' + 'tests.test_authentication.MyAuthenticationPolicy.' 'authenticated_userid: call to unauthenticated_userid returned ' 'None; returning None') @@ -47,7 +47,7 @@ self.assertEqual(len(self.messages), 1) self.assertEqual( self.messages[0], - "pyramid.tests.test_authentication.MyAuthenticationPolicy." + "tests.test_authentication.MyAuthenticationPolicy." "authenticated_userid: there was no groupfinder callback; " "returning 'fred'") @@ -60,7 +60,7 @@ self.assertEqual(len(self.messages), 1) self.assertEqual( self.messages[0], - 'pyramid.tests.test_authentication.MyAuthenticationPolicy.' + 'tests.test_authentication.MyAuthenticationPolicy.' 'authenticated_userid: groupfinder callback returned None; ' 'returning None') @@ -73,7 +73,7 @@ self.assertEqual(len(self.messages), 1) self.assertEqual( self.messages[0], - "pyramid.tests.test_authentication.MyAuthenticationPolicy." + "tests.test_authentication.MyAuthenticationPolicy." "authenticated_userid: groupfinder callback returned []; " "returning 'fred'") @@ -84,7 +84,7 @@ self.assertEqual(len(self.messages), 1) self.assertEqual( self.messages[0], - "pyramid.tests.test_authentication.MyAuthenticationPolicy." + "tests.test_authentication.MyAuthenticationPolicy." "authenticated_userid: use of userid 'system.Authenticated' is " "disallowed by any built-in Pyramid security policy, returning " "None") @@ -96,7 +96,7 @@ self.assertEqual(len(self.messages), 1) self.assertEqual( self.messages[0], - "pyramid.tests.test_authentication.MyAuthenticationPolicy." + "tests.test_authentication.MyAuthenticationPolicy." "authenticated_userid: use of userid 'system.Everyone' is " "disallowed by any built-in Pyramid security policy, returning " "None") @@ -109,7 +109,7 @@ self.assertEqual(len(self.messages), 1) self.assertEqual( self.messages[0], - "pyramid.tests.test_authentication.MyAuthenticationPolicy." + "tests.test_authentication.MyAuthenticationPolicy." "effective_principals: unauthenticated_userid returned None; " "returning ['system.Everyone']") @@ -122,12 +122,12 @@ self.assertEqual(len(self.messages), 2) self.assertEqual( self.messages[0], - 'pyramid.tests.test_authentication.MyAuthenticationPolicy.' + 'tests.test_authentication.MyAuthenticationPolicy.' 'effective_principals: groupfinder callback is None, so groups ' 'is []') self.assertEqual( self.messages[1], - "pyramid.tests.test_authentication.MyAuthenticationPolicy." + "tests.test_authentication.MyAuthenticationPolicy." "effective_principals: returning effective principals: " "['system.Everyone', 'system.Authenticated', 'fred']") @@ -141,12 +141,12 @@ self.assertEqual(len(self.messages), 2) self.assertEqual( self.messages[0], - 'pyramid.tests.test_authentication.MyAuthenticationPolicy.' + 'tests.test_authentication.MyAuthenticationPolicy.' 'effective_principals: groupfinder callback returned None as ' 'groups') self.assertEqual( self.messages[1], - "pyramid.tests.test_authentication.MyAuthenticationPolicy." + "tests.test_authentication.MyAuthenticationPolicy." "effective_principals: returning effective principals: " "['system.Everyone']") @@ -161,11 +161,11 @@ self.assertEqual(len(self.messages), 2) self.assertEqual( self.messages[0], - 'pyramid.tests.test_authentication.MyAuthenticationPolicy.' + 'tests.test_authentication.MyAuthenticationPolicy.' 'effective_principals: groupfinder callback returned [] as groups') self.assertEqual( self.messages[1], - "pyramid.tests.test_authentication.MyAuthenticationPolicy." + "tests.test_authentication.MyAuthenticationPolicy." "effective_principals: returning effective principals: " "['system.Everyone', 'system.Authenticated', 'fred']") @@ -178,7 +178,7 @@ self.assertEqual(len(self.messages), 1) self.assertEqual( self.messages[0], - "pyramid.tests.test_authentication.MyAuthenticationPolicy." + "tests.test_authentication.MyAuthenticationPolicy." "effective_principals: unauthenticated_userid returned disallowed " "'system.Authenticated'; returning ['system.Everyone'] as if it " "was None") @@ -192,7 +192,7 @@ self.assertEqual(len(self.messages), 1) self.assertEqual( self.messages[0], - "pyramid.tests.test_authentication.MyAuthenticationPolicy." + "tests.test_authentication.MyAuthenticationPolicy." "effective_principals: unauthenticated_userid returned disallowed " "'system.Everyone'; returning ['system.Everyone'] as if it " "was None") -- Gitblit v1.9.3