Commit 32bacbdf authored by Laurent Peuch's avatar Laurent Peuch
Browse files

test: migrate to pytest

parent ca91bedde898
...@@ -37,6 +37,7 @@ import os ...@@ -37,6 +37,7 @@ import os
import os.path as osp import os.path as osp
import errno import errno
import subprocess import subprocess
import pytest
DATAPATH = osp.dirname(__file__) DATAPATH = osp.dirname(__file__)
...@@ -64,8 +65,8 @@ class MiscTransformsTC(TestCase): ...@@ -64,8 +65,8 @@ class MiscTransformsTC(TestCase):
converted = ENGINE.convert(data, "text/plain").decode().strip() converted = ENGINE.convert(data, "text/plain").decode().strip()
self.assertEqual(converted, u"yo \nzogzog") self.assertEqual(converted, u"yo \nzogzog")
@pytest.mark.skip("Encoding detection with chardet does not work")
def test_html_to_text_noenc(self): def test_html_to_text_noenc(self):
self.skipTest("Encoding detection with chardet does not work")
# will trigger guess_encoding, check non-utf8 encoding # will trigger guess_encoding, check non-utf8 encoding
data = TransformData( data = TransformData(
u"<b>yo (l'tat l'oeuf)</b>".encode("latin1"), "text/html" u"<b>yo (l'tat l'oeuf)</b>".encode("latin1"), "text/html"
......
...@@ -6,8 +6,9 @@ deps = ...@@ -6,8 +6,9 @@ deps =
pygments pygments
pdflatex pdflatex
pillow pillow
pytest == 5.4.1
commands = commands =
logilab-pytest -t test {posargs} {envpython} -m pytest {posargs:{toxinidir}/test}
[testenv:py3-from-forge] [testenv:py3-from-forge]
deps = deps =
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment