def test_width(self): image = Image(width=100) self.assertEqual(image.width, 100) with self.assertRaises(AttributeError): image.width = None
def test_width(self): image = Image(width=100) assert image.width == 100 with self.assertRaises(AttributeError): image.width = None