def test_good_init_3(self): dt = DateTime.from_dict({ 'year': 2005, 'month': 7, 'day': 14, 'hour': 12, 'minute': 30, 'second': 10 }) self.assertIsInstance(dt, DateTime)
def test_bad_init_8(self): with self.assertRaises(TypeError): dt = DateTime.from_dict("ololo")