diff options
author | Christian Heimes <christian@python.org> | 2019-04-14 12:12:48 +0200 |
---|---|---|
committer | Christian Heimes <christian@python.org> | 2019-04-14 12:13:48 +0200 |
commit | 4ecaeda4d95abbec74de65728271e11b8ca3cda6 (patch) | |
tree | 486ed9ccefeefe210d6eb9ecfe9bf59be7e66630 /tests.py | |
parent | 34d0a1b58fa963b965cf98ff2970b3df54189ec3 (diff) | |
download | defusedxml-git-4ecaeda4d95abbec74de65728271e11b8ca3cda6.tar.gz |
Fix XMLParse typo
The defusedxml.ElementTree and defusedxml.cElementTree modules had a typo
and used XMLParse instead of XMLParser as an alias for DefusedXMLParser.
Both the old and fixed name are now available.
Signed-off-by: Christian Heimes <christian@python.org>
Diffstat (limited to 'tests.py')
-rw-r--r-- | tests.py | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -200,6 +200,12 @@ class TestDefusedElementTree(BaseTests): with self.assertRaises(TypeError): ElementTree.XMLParse(html=1) + def test_aliases(self): + parser = self.module.DefusedXMLParser + assert self.module.XMLTreeBuilder is parser + assert self.module.XMLParser is parser + assert self.module.XMLParse is parser + class TestDefusedcElementTree(TestDefusedElementTree): module = cElementTree |