From 8dbd0210911475ec48d23e741de192a09e23f101 Mon Sep 17 00:00:00 2001 From: Roald de Vries Date: Fri, 25 Nov 2016 15:52:52 +0100 Subject: pass url *fragment* as path argument to getChildWithDefault --- service/test/unit/resources/test_auth.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'service/test/unit/resources') diff --git a/service/test/unit/resources/test_auth.py b/service/test/unit/resources/test_auth.py index 10650e53..05d07130 100644 --- a/service/test/unit/resources/test_auth.py +++ b/service/test/unit/resources/test_auth.py @@ -29,7 +29,7 @@ class TestPixelatedAuthSessionWrapper(unittest.TestCase): def test_should_proxy_to_login_resource_when_the_user_is_not_logged_in(self): when(self.portal_mock).login(ANY(), None, IResource).thenReturn(succeed((IResource, ANONYMOUS, lambda: None))) - deferred_resource = self.session_wrapper.getChildWithDefault('/', self.request) + deferred_resource = self.session_wrapper.getChildWithDefault('', self.request) d = deferred_resource.d def assert_anonymous_resource(resource): @@ -41,7 +41,7 @@ class TestPixelatedAuthSessionWrapper(unittest.TestCase): def test_should_proxy_to_root_resource_when_the_user_is_logged_in(self): when(self.portal_mock).login(ANY(), None, IResource).thenReturn(succeed((IResource, self.user_uuid_mock, lambda: None))) - deferred_resource = self.session_wrapper.getChildWithDefault('/', self.request) + deferred_resource = self.session_wrapper.getChildWithDefault('', self.request) d = deferred_resource.d def assert_root_resource(resource): @@ -53,7 +53,7 @@ class TestPixelatedAuthSessionWrapper(unittest.TestCase): def test_should_proxy_to_unauthorized_resource_when_login_fails(self): when(self.portal_mock).login(ANY(), None, IResource).thenReturn(fail(failure.Failure(error.UnhandledCredentials('dummy message')))) - deferred_resource = self.session_wrapper.getChildWithDefault('/', self.request) + deferred_resource = self.session_wrapper.getChildWithDefault('', self.request) d = deferred_resource.d def assert_unauthorized_resource(resource): -- cgit v1.2.3