def test_copy(self): h = History([C, D, C], [C, C, C]) h2 = h.copy() self.assertEqual(h, h2)
def test_eq(self): h = History([C, D, C], [C, C, C]) with self.assertRaises(TypeError): h == 2
def test_init(self): h1 = History([C, C, D], [C, C, C]) self.assertEqual(list(h1), [C, C, D]) h1.extend([C, C], [D, D]) self.assertEqual(list(h1), [C, C, D, C, C])