Пример #1
0
 def test_create_and_process(self):
     using_other = UsingOther()
     result = using_other.create()
     new_style = NewStyle(13)
     result.x = 13
     result.x = 14
     self.assertEqual(new_style, result)
     self.assertEqual(None, using_other.process(result))
Пример #2
0
 def test_incrx_returns_None_after_creation_with_3(self):
     new_style = NewStyle(3)
     self.assertEqual(None, new_style.incrx())
     self.assertEqual(4, new_style.x)
Пример #3
0
 def test_incrx_2_times_after_creation_with_13(self):
     new_style = NewStyle(13)
     self.assertEqual(None, new_style.incrx())
     self.assertEqual(14, new_style.x)
     self.assertEqual(None, new_style.incrx())
     self.assertEqual(15, new_style.x)
Пример #4
0
 def test_creation_with_100(self):
     new_style = NewStyle(100)
Пример #5
0
 def test_incrx_returns_None_after_creation_with_3(self):
     new_style = NewStyle(3)
     self.assertEqual(None, new_style.incrx())
     self.assertEqual(4, new_style.x)
Пример #6
0
 def test_incrx_2_times_after_creation_with_13(self):
     new_style = NewStyle(13)
     self.assertEqual(None, new_style.incrx())
     self.assertEqual(14, new_style.x)
     self.assertEqual(None, new_style.incrx())
     self.assertEqual(15, new_style.x)