Example #1
0
 def testRemoveExit(self):
     cell = Cell()
     cell.addExit(1, 0)
     
     cell.removeExit(1, 0)
     
     self.assertFalse(cell.hasExit(1, 0))
Example #2
0
 def testFromArrows(self):
     cell = Cell('^>')
     
     self.assertTrue(cell.hasExit(1, 0))
     self.assertFalse(cell.hasExit(-1, 0))
Example #3
0
 def testAddExit(self):
     cell = Cell()
     cell.addExit(1, 0)
     
     self.assertTrue(cell.hasExit(1, 0))
     self.assertFalse(cell.hasExit(-1, 0))
Example #4
0
 def testHasExit(self):
     cell = Cell((1, 0))
     
     self.assertTrue(cell.hasExit(1, 0))
     self.assertFalse(cell.hasExit(-1, 0))