summaryrefslogtreecommitdiff
path: root/tests/test_intl.py
diff options
context:
space:
mode:
authorTakeshi KOMIYA <i.tkomiya@gmail.com>2016-12-15 13:12:13 +0900
committerTakeshi KOMIYA <i.tkomiya@gmail.com>2016-12-15 17:15:49 +0900
commit9fc53cecf74fae33ac8509d34eea334ad4193d2b (patch)
tree330d9f4269b752216684512d90cf99ffae7f2d0f /tests/test_intl.py
parent108491d49ea37f8e42ad32242167bc8a00f89cd8 (diff)
downloadsphinx-git-9fc53cecf74fae33ac8509d34eea334ad4193d2b.tar.gz
Reduce deprecation warnings (refs: #3192)
Diffstat (limited to 'tests/test_intl.py')
-rw-r--r--tests/test_intl.py15
1 files changed, 7 insertions, 8 deletions
diff --git a/tests/test_intl.py b/tests/test_intl.py
index 4a517c111..21d6f763b 100644
--- a/tests/test_intl.py
+++ b/tests/test_intl.py
@@ -16,7 +16,6 @@ import re
import pickle
from docutils import nodes
from subprocess import Popen, PIPE
-from xml.etree import ElementTree
from babel.messages import pofile
from nose.tools import assert_equal
@@ -24,7 +23,7 @@ from six import string_types
from util import tempdir, rootdir, path, gen_with_app, with_app, SkipTest, \
assert_re_search, assert_not_re_search, assert_in, assert_not_in, \
- assert_startswith, assert_node, repr_as
+ assert_startswith, assert_node, repr_as, etree_parse
root = tempdir / 'test-intl'
@@ -502,7 +501,7 @@ def test_xml_builder(app, status, warning):
# --- footnotes: regression test for fix #955, #1176
- et = ElementTree.parse(app.outdir / 'footnote.xml')
+ et = etree_parse(app.outdir / 'footnote.xml')
secs = et.findall('section')
para0 = secs[0].findall('paragraph')
@@ -542,7 +541,7 @@ def test_xml_builder(app, status, warning):
# --- footnote backlinks: i18n test for #1058
- et = ElementTree.parse(app.outdir / 'footnote.xml')
+ et = etree_parse(app.outdir / 'footnote.xml')
secs = et.findall('section')
para0 = secs[0].findall('paragraph')
@@ -558,7 +557,7 @@ def test_xml_builder(app, status, warning):
# --- refs in the Python domain
- et = ElementTree.parse(app.outdir / 'refs_python_domain.xml')
+ et = etree_parse(app.outdir / 'refs_python_domain.xml')
secs = et.findall('section')
# regression test for fix #1363
@@ -570,7 +569,7 @@ def test_xml_builder(app, status, warning):
# --- keep external links: regression test for #1044
- et = ElementTree.parse(app.outdir / 'external_links.xml')
+ et = etree_parse(app.outdir / 'external_links.xml')
secs = et.findall('section')
para0 = secs[0].findall('paragraph')
@@ -623,7 +622,7 @@ def test_xml_builder(app, status, warning):
# --- role xref: regression test for #1090, #1193
- et = ElementTree.parse(app.outdir / 'role_xref.xml')
+ et = etree_parse(app.outdir / 'role_xref.xml')
sec1, sec2 = et.findall('section')
para1, = sec1.findall('paragraph')
@@ -674,7 +673,7 @@ def test_xml_builder(app, status, warning):
# --- label targets: regression test for #1193, #1265
- et = ElementTree.parse(app.outdir / 'label_target.xml')
+ et = etree_parse(app.outdir / 'label_target.xml')
secs = et.findall('section')
para0 = secs[0].findall('paragraph')