예제 #1
0
 def test_magic_base_min_cap(self):
     stats = Stats()
     stats._magic_base = 10
     stats._mana = 10
     self.assertEqual(10, stats.reduce_magic_base(11))
     self.assertEqual(0, stats._magic_base)
     self.assertEqual(0, stats._mana)
예제 #2
0
 def test_magic_base_reduce(self):
     stats = Stats()
     stats._magic_base = 10
     stats._mana = 10
     self.assertEqual(4, stats.reduce_magic_base(4))
     self.assertEqual(6, stats._magic_base)
     self.assertEqual(6, stats._mana)
예제 #3
0
 def test_mana_max_cap(self):
     stats = Stats()
     stats._magic_base = 10
     stats._mana = 5
     self.assertEqual(5, stats.increase_mana(6))
     self.assertEqual(10, stats._mana)
예제 #4
0
 def test_magic_base_increase(self):
     stats = Stats()
     stats._magic_base = 10
     self.assertEqual(6, stats.increase_magic_base(6))
     self.assertEqual(16, stats._magic_base)
예제 #5
0
 def test_mana_increase(self):
     stats = Stats()
     stats._magic_base = 10
     stats._mana = 5
     self.assertEqual(2, stats.increase_mana(2))
     self.assertEqual(7, stats._mana)