diff options
author | Guido van Rossum <guido@python.org> | 2001-08-14 20:00:33 (GMT) |
---|---|---|
committer | Guido van Rossum <guido@python.org> | 2001-08-14 20:00:33 (GMT) |
commit | 80e36750c8f6bfd41bb392ec223f4815acf8ae72 (patch) | |
tree | 8b51252fd1a3fb841e6645ba4119804f06d4e037 | |
parent | d3ba10f4b5000d42e84def72306afb633651f4e0 (diff) | |
download | cpython-80e36750c8f6bfd41bb392ec223f4815acf8ae72.zip cpython-80e36750c8f6bfd41bb392ec223f4815acf8ae72.tar.gz cpython-80e36750c8f6bfd41bb392ec223f4815acf8ae72.tar.bz2 |
Add a test for a weird bug I just discovered: a dynamic subclass
doesn't have a __dict__!
-rw-r--r-- | Lib/test/test_descr.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Lib/test/test_descr.py b/Lib/test/test_descr.py index bdde451..e461526 100644 --- a/Lib/test/test_descr.py +++ b/Lib/test/test_descr.py @@ -613,6 +613,11 @@ def dynamics(): else: verify(0, "expected AttributeError") verify(a.spam == "spam") + class D(C): + pass + d = D() + d.foo = 1 + verify(d.foo == 1) def errors(): if verbose: print "Testing errors..." |