Beispiel #1
0
 def test_safe_write_empty_returns_true(self):
     safeWrite(self.portal, self.request)
     transform = ProtectTransform(self.portal, self.request)
     transform._registered_objects = lambda: [self.portal]
     self.assertTrue(transform._check())
Beispiel #2
0
 def test_safe_write_empty_returns_true(self):
     safeWrite(self.portal, self.request)
     transform = ProtectTransform(self.portal, self.request)
     transform._registered_objects = lambda: [self.portal]
     self.assertTrue(transform._check())
Beispiel #3
0
 def test_safe_write_empty_returns_false(self):
     transform = ProtectTransform(self.portal, self.request)
     transform._registered_objects = lambda: [self.portal]
     self.assertRaises(Forbidden, transform._check)
Beispiel #4
0
 def test_safe_write_empty_returns_false(self):
     transform = ProtectTransform(self.portal, self.request)
     transform._registered_objects = lambda: [self.portal]
     self.assertRaises(Forbidden, transform._check)