Пример #1
0
 def test_oldstyle(self):
     assert fnpe(Oldstyle())
Пример #2
0
 def test_BaseException(self):
     assert fnpe(Exception()) is None
Пример #3
0
 def test_unpickleable(self):
     self.assertIsInstance(fnpe(Unpickleable()), KeyError)
     self.assertIsNone(fnpe(Impossible()))
Пример #4
0
 def test_unpickleable(self):
     assert isinstance(fnpe(Unpickleable()), KeyError)
     assert fnpe(Impossible()) is None
Пример #5
0
 def test_oldstyle(self):
     self.assertIsNone(fnpe(Oldstyle()))
Пример #6
0
 def test_BaseException(self):
     self.assertIsNone(fnpe(Exception()))
Пример #7
0
 def test_BaseException(self):
     self.assertIsNone(fnpe(Exception()))
Пример #8
0
 def test_unpickleable(self):
     self.assertIsInstance(fnpe(Unpickleable()), KeyError)
     self.assertIsNone(fnpe(Impossible()))
Пример #9
0
 def test_oldstyle(self):
     if Oldstyle is None:
         raise SkipTest('py3k does not support old style classes')
     self.assertTrue(fnpe(Oldstyle()))
Пример #10
0
 def test_oldstyle(self):
     if Oldstyle is None:
         raise SkipTest('py3k does not support old style classes')
     self.assertTrue(fnpe(Oldstyle()))
Пример #11
0
 def test_oldstyle(self):
     self.assertTrue(fnpe(Oldstyle()))
Пример #12
0
 def test_oldstyle(self):
     self.assertIsNone(fnpe(Oldstyle()))
Пример #13
0
 def test_oldstyle(self):
     self.assertTrue(fnpe(Oldstyle()))