def test_find_none(self): table = Table(self.rows, self.columns) row = table.find(lambda r: r['one'] == 'FOO') self.assertIs(row, None)
def test_find(self): table = Table(self.rows, self.columns) row = table.find(lambda r: r['two'] - r['one'] == 1) self.assertIs(row, table.rows[1])