diff --git a/Pipfile b/Pipfile
index 0adb922..494dca0 100644
--- a/Pipfile
+++ b/Pipfile
@@ -5,6 +5,7 @@ name = "pypi"
[packages]
typing = "*"
+lxml = "*"
[dev-packages]
pytest = "==3.8.0"
@@ -15,7 +16,7 @@ coverage = "*"
sphinx = "*"
"doc8" = "*"
codecov = "*"
-cosmic-ray-pytest-runner = {version = "*", python_version = ">= '3.6'"}
-cosmic-ray = {version = "*", python_version = ">= '3.6'"}
+cosmic-ray-pytest-runner = {version = "*",python_version = ">= '3.6'"}
+cosmic-ray = {version = "*",python_version = ">= '3.6'"}
attrs = "*"
-mypy = {version = "==0.630", python_version = ">= '3.6'"}
+mypy = {version = "==0.630",python_version = ">= '3.6'"}
diff --git a/declxml.py b/declxml.py
index 3053852..e296eb0 100644
--- a/declxml.py
+++ b/declxml.py
@@ -68,7 +68,7 @@
)
import warnings
from xml.dom import minidom # type: ignore
-import xml.etree.ElementTree as ET
+from lxml import etree as ET
_PY2 = sys.version_info[0] == 2
diff --git a/tests/test_hooks_value_transforms.py b/tests/test_hooks_value_transforms.py
index d5be532..762e095 100644
--- a/tests/test_hooks_value_transforms.py
+++ b/tests/test_hooks_value_transforms.py
@@ -493,7 +493,7 @@ def test_primitive_transform_attribute():
"""Transform a primitive value that is an attribute"""
xml_string = strip_xml("""
-
+
""")
diff --git a/tests/test_serialization.py b/tests/test_serialization.py
index e9b5135..9add532 100644
--- a/tests/test_serialization.py
+++ b/tests/test_serialization.py
@@ -112,7 +112,7 @@ def test_array_serialize_array_of_arrays_omit_empty():
2
4
-
+
12
32
@@ -123,7 +123,6 @@ def test_array_serialize_array_of_arrays_omit_empty():
""")
actual = xml.serialize_to_string(processor, value)
-
assert expected == actual
@@ -180,7 +179,7 @@ def test_array_serialize_missing_optional_nested():
expected = strip_xml("""
Hello
-
+
""")
@@ -366,7 +365,7 @@ def test_array_serialize_primitive_omit_empty():
expected = strip_xml("""
Hello
-
+
Hola
Bonjour
@@ -447,7 +446,7 @@ def test_attribute_serialize():
expected = strip_xml("""
-
+
""")
@@ -468,7 +467,7 @@ def test_attribute_serialize_aliased():
expected = strip_xml("""
-
+
""")
@@ -1027,7 +1026,7 @@ def test_primitive_values_serialize_falsey():
False
0.0
0
-
+
""")
@@ -1053,7 +1052,7 @@ def test_primitive_values_serialize_falsey_omitted():
])
expected = strip_xml("""
-
+
""")
actual = xml.serialize_to_string(processor, value)
@@ -1074,10 +1073,10 @@ def test_primitive_values_serialize_none_default():
expected = strip_xml("""
-
-
-
-
+
+
+
+
""")
diff --git a/tests/test_xpath.py b/tests/test_xpath.py
index d30718c..dbd01a3 100644
--- a/tests/test_xpath.py
+++ b/tests/test_xpath.py
@@ -28,8 +28,8 @@ class TestDot(_ProcessorTestCase):
xml_string = strip_xml("""
-
-
+
+
""")
@@ -218,9 +218,9 @@ class TestSlashFromRootArray(_ProcessorTestCase):
xml_string = strip_xml("""
-
-
-
+
+
+
""")