def test_cannot_create_abstract_obj(self): a = Attribute() with self.assertRaises(NotImplementedError): a.to_obj()