示例#1
0
 def test_read_northwest_out_of_bounds(self):
     cursor = Cursor([['A']])
     cursor._position = (0, 0)
     self.assertIsNone(cursor.read(-1, -1))
示例#2
0
 def test_read_northwest_value(self):
     cursor = Cursor([['A']])
     cursor._position = (1, 1)
     self.assertEqual(cursor.read(-1, -1), 'A')
示例#3
0
 def test_read_out_of_range(self):
     cursor = Cursor([[]])
     self.assertIsNone(cursor.read())
示例#4
0
 def test_read_value(self):
     cursor = Cursor([[1]])
     self.assertEqual(cursor.read(), 1)
示例#5
0
 def test_read_value_x_y(self):
     cursor = Cursor([[1], [2]])
     cursor.advance_row()
     self.assertEqual(cursor.read(), 2)