mirror of
https://github.com/python/cpython.git
synced 2026-05-31 16:49:25 -04:00
Except HierarchyRequestErr instead of TypeError.
This commit is contained in:
@@ -294,7 +294,7 @@ def testTooManyDocumentElements():
|
||||
elem = doc.createElement("extra")
|
||||
try:
|
||||
doc.appendChild(elem)
|
||||
except TypeError:
|
||||
except HierarchyRequestErr:
|
||||
print "Caught expected exception when adding extra document element."
|
||||
else:
|
||||
print "Failed to catch expected exception when" \
|
||||
|
||||
Reference in New Issue
Block a user