2016-01-03 18:51:36 +00:00
|
|
|
|
|
|
|
class Foo:
|
|
|
|
|
|
|
|
def __init__(self):
|
|
|
|
self.a = 1
|
|
|
|
self.b = "bar"
|
|
|
|
|
|
|
|
o = Foo()
|
|
|
|
if not hasattr(o, "__dict__"):
|
|
|
|
print("SKIP")
|
2017-06-10 18:03:01 +01:00
|
|
|
raise SystemExit
|
2016-01-03 18:51:36 +00:00
|
|
|
|
|
|
|
print(o.__dict__ == {'a': 1, 'b': 'bar'})
|