def test_moving_sw_from_odd_column(self): p = Program() p.q = 3 p.r = 3 p.move("sw") self.assertEqual(p.q, 2) self.assertEqual(p.r, 3)
def test_moving_sw_from_even_column(self): p = Program() p.q = 4 p.r = 3 p.move("sw") self.assertEqual(p.q, 3) self.assertEqual(p.r, 4)
def test_moving_ne_from_odd_column(self): p = Program() p.q = 3 p.r = 3 p.move("ne") self.assertEqual(p.q, 4) self.assertEqual(p.r, 2)
def test_moving_n(self): p = Program() p.q = 3 p.r = 3 p.move("n") self.assertEqual(p.q, 3) self.assertEqual(p.r, 2)
def test_moving_ne_from_even_column(self): p = Program() p.q = 4 p.r = 3 p.move("ne") self.assertEqual(p.q, 5) self.assertEqual(p.r, 3)