summaryrefslogtreecommitdiff
path: root/service/test/unit/resources
diff options
context:
space:
mode:
authorRoald de Vries <rdevries@thoughtworks.com>2016-11-25 15:52:52 +0100
committerRoald de Vries <rdevries@thoughtworks.com>2016-11-25 15:52:52 +0100
commit8dbd0210911475ec48d23e741de192a09e23f101 (patch)
tree3c6dc09a2913fbcaac84226e82b92f1b9d53bbce /service/test/unit/resources
parente313d7c8880192ab3261cdd8cb263f5eef28d40a (diff)
pass url *fragment* as path argument to getChildWithDefault
Diffstat (limited to 'service/test/unit/resources')
-rw-r--r--service/test/unit/resources/test_auth.py6
1 files changed, 3 insertions, 3 deletions
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):