コード例 #1
0
ファイル: test_auth.py プロジェクト: Python3pkg/CheesePrism
 def test_effective_p_without_groups(self):
     policy = self.makeone(lambda x, y: None)
     assert policy.effective_principals(self.req) == ['system.Everyone']
コード例 #2
0
ファイル: test_auth.py プロジェクト: Python3pkg/CheesePrism
 def test_effective_p_without_cred(self):
     self.req.environ['HTTP_AUTHORIZATION'] = 'Basic d2hpdCtzZWNyZXQ=\n'
     policy = self.makeone()
     assert policy.effective_principals(self.req) == ['system.Everyone']
コード例 #3
0
ファイル: test_auth.py プロジェクト: Python3pkg/CheesePrism
 def test_effective_principals(self):
     policy = self.makeone()
     princs = policy.effective_principals(self.req)
     assert princs == ['system.Everyone', 'system.Authenticated', 'whit']
コード例 #4
0
ファイル: test_auth.py プロジェクト: 19emtuck/CheesePrism
 def test_effective_p_without_groups(self):
     policy = self.makeone(lambda x, y: None)
     assert policy.effective_principals(self.req) == ['system.Everyone']
コード例 #5
0
ファイル: test_auth.py プロジェクト: 19emtuck/CheesePrism
 def test_effective_p_without_cred(self):
     self.req.environ['HTTP_AUTHORIZATION'] = 'Basic d2hpdCtzZWNyZXQ=\n'
     policy = self.makeone()
     assert policy.effective_principals(self.req) == ['system.Everyone']
コード例 #6
0
ファイル: test_auth.py プロジェクト: 19emtuck/CheesePrism
 def test_effective_principals(self):
     policy = self.makeone()
     princs = policy.effective_principals(self.req)
     assert princs == ['system.Everyone', 'system.Authenticated', 'whit']