예제 #1
0
    def test_add_family(self):
        cell = Cell(self.db_)
        cell.init_based_on_id(1)

        cell.clear_family()
        cell.add_to_family('SingleTx')
        self.assertEqual('SingleTx', cell.get_family())

        # check adding same content twice, this should not affect the value
        cell.add_to_family('SingleTx')
        self.assertEqual('SingleTx', cell.get_family())
        cell.clear_family()
예제 #2
0
 def test_clear_family(self):
     cell = Cell(self.db_)
     cell.init_based_on_id(1)
     cell.clear_family()
     self.assertIsNone(cell.get_family())