diff --git a/tests/test_htmlhelp.py b/tests/test_htmlhelp.py index a74c66a..8774d4b 100644 --- a/tests/test_htmlhelp.py +++ b/tests/test_htmlhelp.py @@ -21,7 +21,7 @@ def test_build_htmlhelp(app, status, warning): app.build() - hhp = (app.outdir / 'pythondoc.hhp').text() + hhp = (app.outdir / 'pythondoc.hhp').read_text() assert 'Compiled file=pythondoc.chm' in hhp assert 'Contents file=pythondoc.hhc' in hhp assert 'Default Window=pythondoc' in hhp @@ -84,7 +84,7 @@ def assert_sitemap(node, name, filename): assert node[1].attrib == {'name': 'Local', 'value': filename} # .hhc file - hhc = (app.outdir / 'pythondoc.hhc').text() + hhc = (app.outdir / 'pythondoc.hhc').read_text() tree = HTMLParser(namespaceHTMLElements=False).parse(hhc) items = tree.find('.//body/ul') assert len(items) == 4