aboutsummaryrefslogtreecommitdiff
path: root/tests/docx/office_xml_tests.py
diff options
context:
space:
mode:
authorMichael Williamson <mike@zwobble.org>2022-11-25 22:50:05 +0000
committerMichael Williamson <mike@zwobble.org>2022-11-25 22:58:16 +0000
commit5093d72b9fece1a7c3d7a3d19e4161387ee6475a (patch)
treec4122b0f72c7864897d78333e75328ac8c22685b /tests/docx/office_xml_tests.py
parent20e3e61530bef546058124c3015ae240733cc974 (diff)
Use pytest instead of nose
Diffstat (limited to 'tests/docx/office_xml_tests.py')
-rw-r--r--tests/docx/office_xml_tests.py8
1 files changed, 3 insertions, 5 deletions
diff --git a/tests/docx/office_xml_tests.py b/tests/docx/office_xml_tests.py
index 5b8b1e1..f87fa75 100644
--- a/tests/docx/office_xml_tests.py
+++ b/tests/docx/office_xml_tests.py
@@ -2,13 +2,11 @@ from __future__ import unicode_literals
import io
-from nose.tools import istest, assert_equal
-
from mammoth.docx import xmlparser as xml, office_xml
+from ..testing import assert_equal
-@istest
-def alternate_content_is_replaced_by_contents_of_fallback():
+def test_alternate_content_is_replaced_by_contents_of_fallback():
xml_string = (
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>' +
'<numbering xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006">' +
@@ -21,6 +19,6 @@ def alternate_content_is_replaced_by_contents_of_fallback():
'</mc:Fallback>' +
'</mc:AlternateContent>' +
'</numbering>')
-
+
result = office_xml.read(io.StringIO(xml_string))
assert_equal([xml.element("fallback")], result.children)