/usr/bin/mkdir: created directory 'test_dir'
running install
/usr/lib/python3.10/site-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
warnings.warn(
running install_lib
creating test_dir/usr
creating test_dir/usr/lib
creating test_dir/usr/lib/python3.10
creating test_dir/usr/lib/python3.10/site-packages
creating test_dir/usr/lib/python3.10/site-packages/pytest_html
creating test_dir/usr/lib/python3.10/site-packages/pytest_html/resources
copying build/lib/pytest_html/resources/main.js -> test_dir/usr/lib/python3.10/site-packages/pytest_html/resources
copying build/lib/pytest_html/resources/style.css -> test_dir/usr/lib/python3.10/site-packages/pytest_html/resources
copying build/lib/pytest_html/__init__.py -> test_dir/usr/lib/python3.10/site-packages/pytest_html
copying build/lib/pytest_html/__version.py -> test_dir/usr/lib/python3.10/site-packages/pytest_html
copying build/lib/pytest_html/extras.py -> test_dir/usr/lib/python3.10/site-packages/pytest_html
copying build/lib/pytest_html/hooks.py -> test_dir/usr/lib/python3.10/site-packages/pytest_html
copying build/lib/pytest_html/plugin.py -> test_dir/usr/lib/python3.10/site-packages/pytest_html
byte-compiling test_dir/usr/lib/python3.10/site-packages/pytest_html/__init__.py to __init__.cpython-310.pyc
byte-compiling test_dir/usr/lib/python3.10/site-packages/pytest_html/__version.py to __version.cpython-310.pyc
byte-compiling test_dir/usr/lib/python3.10/site-packages/pytest_html/extras.py to extras.cpython-310.pyc
byte-compiling test_dir/usr/lib/python3.10/site-packages/pytest_html/hooks.py to hooks.cpython-310.pyc
byte-compiling test_dir/usr/lib/python3.10/site-packages/pytest_html/plugin.py to plugin.cpython-310.pyc
writing byte-compilation script '/tmp/tmp_jete11_.py'
/usr/bin/python -Wignore:The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives:DeprecationWarning /tmp/tmp_jete11_.py
removing /tmp/tmp_jete11_.py
running install_egg_info
running egg_info
writing src/pytest_html.egg-info/PKG-INFO
writing dependency_links to src/pytest_html.egg-info/dependency_links.txt
writing entry points to src/pytest_html.egg-info/entry_points.txt
writing requirements to src/pytest_html.egg-info/requires.txt
writing top-level names to src/pytest_html.egg-info/top_level.txt
reading manifest file 'src/pytest_html.egg-info/SOURCES.txt'
adding license file 'LICENSE'
writing manifest file 'src/pytest_html.egg-info/SOURCES.txt'
Copying src/pytest_html.egg-info to test_dir/usr/lib/python3.10/site-packages/pytest_html-3.1.1-py3.10.egg-info
running install_scripts
============================= test session starts ==============================
platform linux -- Python 3.10.1, pytest-6.2.5, py-1.11.0, pluggy-0.13.1 -- /usr/bin/python
cachedir: .pytest_cache
rootdir: /build/python-pytest-html/src/python-pytest-html-3.1.1, configfile: tox.ini, testpaths: testing
plugins: html-3.1.1, xdist-2.5.0, forked-1.4.0, rerunfailures-10.2, mock-3.6.1
collecting ... collected 89 items
testing/test_pytest_html.py::TestHTML::test_durations PASSED [ 1%]
testing/test_pytest_html.py::TestHTML::test_can_format_duration_column[%f-
\\d{2} | ] PASSED [ 2%]
testing/test_pytest_html.py::TestHTML::test_can_format_duration_column[%S.%f-\\d{2}\\.\\d{2} | ] PASSED [ 3%]
testing/test_pytest_html.py::TestHTML::test_can_format_duration_column[ABC%H %M %S123-ABC\\d{2} \\d{2} \\d{2}123 | ] PASSED [ 4%]
testing/test_pytest_html.py::TestHTML::test_pass PASSED [ 5%]
testing/test_pytest_html.py::TestHTML::test_skip PASSED [ 6%]
testing/test_pytest_html.py::TestHTML::test_fail PASSED [ 7%]
testing/test_pytest_html.py::TestHTML::test_rerun PASSED [ 8%]
testing/test_pytest_html.py::TestHTML::test_no_rerun PASSED [ 10%]
testing/test_pytest_html.py::TestHTML::test_conditional_xfails PASSED [ 11%]
testing/test_pytest_html.py::TestHTML::test_setup_error PASSED [ 12%]
testing/test_pytest_html.py::TestHTML::test_xfail PASSED [ 13%]
testing/test_pytest_html.py::TestHTML::test_xpass PASSED [ 14%]
testing/test_pytest_html.py::TestHTML::test_create_report_path PASSED [ 15%]
testing/test_pytest_html.py::TestHTML::test_report_title[] PASSED [ 16%]
testing/test_pytest_html.py::TestHTML::test_report_title[directory] PASSED [ 17%]
testing/test_pytest_html.py::TestHTML::test_report_title_addopts_env_var PASSED [ 19%]
testing/test_pytest_html.py::TestHTML::test_resources_inline_css PASSED [ 20%]
testing/test_pytest_html.py::TestHTML::test_resources PASSED [ 21%]
testing/test_pytest_html.py::TestHTML::test_stdout[pass] PASSED [ 22%]
testing/test_pytest_html.py::TestHTML::test_stdout[fail] PASSED [ 23%]
testing/test_pytest_html.py::TestHTML::test_custom_content_in_summary PASSED [ 24%]
testing/test_pytest_html.py::TestHTML::test_extra_html PASSED [ 25%]
testing/test_pytest_html.py::TestHTML::test_extra_text[u'\x81'-woE=] PASSED [ 26%]
testing/test_pytest_html.py::TestHTML::test_extra_text['foo'-Zm9v] PASSED [ 28%]
testing/test_pytest_html.py::TestHTML::test_extra_text[b'\\xe2\\x80\\x93'-4oCT] PASSED [ 29%]
testing/test_pytest_html.py::TestHTML::test_extra_json PASSED [ 30%]
testing/test_pytest_html.py::TestHTML::test_extra_url PASSED [ 31%]
testing/test_pytest_html.py::TestHTML::test_extra_image[image/png-png] PASSED [ 32%]
testing/test_pytest_html.py::TestHTML::test_extra_image[image/png-image] PASSED [ 33%]
testing/test_pytest_html.py::TestHTML::test_extra_image[image/jpeg-jpg] PASSED [ 34%]
testing/test_pytest_html.py::TestHTML::test_extra_image[image/svg+xml-svg] PASSED [ 35%]
testing/test_pytest_html.py::TestHTML::test_extra_image_windows PASSED [ 37%]
testing/test_pytest_html.py::TestHTML::test_extra_video[video/mp4-mp4] PASSED [ 38%]
testing/test_pytest_html.py::TestHTML::test_extra_video_windows PASSED [ 39%]
testing/test_pytest_html.py::TestHTML::test_extra_text_separated[u'\x81'] PASSED [ 40%]
testing/test_pytest_html.py::TestHTML::test_extra_text_separated['foo'] PASSED [ 41%]
testing/test_pytest_html.py::TestHTML::test_extra_text_separated[b'\\xe2\\x80\\x93'] PASSED [ 42%]
testing/test_pytest_html.py::TestHTML::test_extra_image_separated[png-image] PASSED [ 43%]
testing/test_pytest_html.py::TestHTML::test_extra_image_separated[png-png] PASSED [ 44%]
testing/test_pytest_html.py::TestHTML::test_extra_image_separated[svg-svg] PASSED [ 46%]
testing/test_pytest_html.py::TestHTML::test_extra_image_separated[jpg-jpg] PASSED [ 47%]
testing/test_pytest_html.py::TestHTML::test_extra_image_separated_rerun[png-image] PASSED [ 48%]
testing/test_pytest_html.py::TestHTML::test_extra_image_separated_rerun[png-png] PASSED [ 49%]
testing/test_pytest_html.py::TestHTML::test_extra_image_separated_rerun[svg-svg] PASSED [ 50%]
testing/test_pytest_html.py::TestHTML::test_extra_image_separated_rerun[jpg-jpg] PASSED [ 51%]
testing/test_pytest_html.py::TestHTML::test_extra_image_non_b64[https://] PASSED [ 52%]
testing/test_pytest_html.py::TestHTML::test_extra_image_non_b64[file://] PASSED [ 53%]
testing/test_pytest_html.py::TestHTML::test_extra_image_non_b64[image.png] PASSED [ 55%]
testing/test_pytest_html.py::TestHTML::test_very_long_test_name[10] PASSED [ 56%]
testing/test_pytest_html.py::TestHTML::test_very_long_test_name[100] PASSED [ 57%]
testing/test_pytest_html.py::TestHTML::test_extra_fixture PASSED [ 58%]
testing/test_pytest_html.py::TestHTML::test_no_invalid_characters_in_filename PASSED [ 59%]
testing/test_pytest_html.py::TestHTML::test_no_environment PASSED [ 60%]
testing/test_pytest_html.py::TestHTML::test_environment FAILED [ 61%]
testing/test_pytest_html.py::TestHTML::test_environment_xdist FAILED [ 62%]
testing/test_pytest_html.py::TestHTML::test_environment_xdist_reruns FAILED [ 64%]
testing/test_pytest_html.py::TestHTML::test_environment_list_value[content0-123Go, Hello, fzWZP6vKRv, garAge, hello] FAILED [ 65%]
testing/test_pytest_html.py::TestHTML::test_environment_list_value[content1-1, 2, 2, 4, 54] FAILED [ 66%]
testing/test_pytest_html.py::TestHTML::test_environment_list_value[content2-400, 5.4, Yes] FAILED [ 67%]
testing/test_pytest_html.py::TestHTML::test_environment_unordered_dict_value[unordered_dict0-content | \\n\\s+{"123Go": 5, "Hello": 5, "fzWZP6vKRv": 10, "garAge": 6, "hello": 5} | ] FAILED [ 68%]
testing/test_pytest_html.py::TestHTML::test_environment_unordered_dict_value[unordered_dict1-content | \\n\\s+{"First Link": "W3Schools", "Second Link": "W2Schools", "Third Link": "W4Schools"} | ] FAILED [ 69%]
testing/test_pytest_html.py::TestHTML::test_environment_ordered PASSED [ 70%]
testing/test_pytest_html.py::TestHTML::test_xdist_crashing_worker PASSED [ 71%]
testing/test_pytest_html.py::TestHTML::test_utf8_surrogate PASSED [ 73%]
testing/test_pytest_html.py::TestHTML::test_ansi_color[True] PASSED [ 74%]
testing/test_pytest_html.py::TestHTML::test_ansi_color[False] PASSED [ 75%]
testing/test_pytest_html.py::TestHTML::test_ansi_escape_sequence_removed PASSED [ 76%]
testing/test_pytest_html.py::TestHTML::test_utf8_longrepr['foo'] PASSED [ 77%]
testing/test_pytest_html.py::TestHTML::test_utf8_longrepr[u'\x81'] PASSED [ 78%]
testing/test_pytest_html.py::TestHTML::test_collect_error PASSED [ 79%]
testing/test_pytest_html.py::TestHTML::test_css[colors0] PASSED [ 80%]
testing/test_pytest_html.py::TestHTML::test_css[colors1] PASSED [ 82%]
testing/test_pytest_html.py::TestHTML::test_css_invalid[style.css] PASSED [ 83%]
testing/test_pytest_html.py::TestHTML::test_css_invalid[files1] PASSED [ 84%]
testing/test_pytest_html.py::TestHTML::test_css_invalid[testdir.makefile('.css', * {color: 'white'}] PASSED [ 85%]
testing/test_pytest_html.py::TestHTML::test_css_invalid_no_html PASSED [ 86%]
testing/test_pytest_html.py::TestHTML::test_report_display_utf8 PASSED [ 87%]
testing/test_pytest_html.py::TestHTML::test_collapsed[True] PASSED [ 88%]
testing/test_pytest_html.py::TestHTML::test_collapsed[False] PASSED [ 89%]
testing/test_pytest_html.py::TestHTML::test_custom_content_report_title PASSED [ 91%]
testing/test_pytest_html.py::TestHTML::test_setup_and_teardown_in_html PASSED [ 92%]
testing/test_pytest_html.py::TestHTML::test_setup_failures_are_errors PASSED [ 93%]
testing/test_pytest_html.py::TestHTML::test_teardown_failures_are_errors PASSED [ 94%]
testing/test_pytest_html.py::TestHTML::test_extra_log_reporting_respects_capture_no[-s-False] PASSED [ 95%]
testing/test_pytest_html.py::TestHTML::test_extra_log_reporting_respects_capture_no[--capture=no-False] PASSED [ 96%]
testing/test_pytest_html.py::TestHTML::test_extra_log_reporting_respects_capture_no[--capture=sys-True] PASSED [ 97%]
testing/test_pytest_html.py::TestHTML::test_extra_log_reporting_respects_show_capture_no[--show-capture=no-False] PASSED [ 98%]
testing/test_pytest_html.py::TestHTML::test_extra_log_reporting_respects_show_capture_no[--show-capture=all-True] PASSED [100%]
=================================== FAILURES ===================================
__________________________ TestHTML.test_environment ___________________________
self =
testdir =
def test_environment(self, testdir):
content = str(random.random())
testdir.makeconftest(
f"""
def pytest_configure(config):
config._metadata['content'] = '{content}'
"""
)
testdir.makepyfile("def test_pass(): pass")
> result, html = run(testdir)
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:755:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:42: in run
return result, read_html(path)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
path = local('/tmp/pytest-of-builduser/pytest-0/test_environment0/report.html')
def read_html(path):
> with open(str(path)) as f:
E FileNotFoundError: [Errno 2] No such file or directory: '/tmp/pytest-of-builduser/pytest-0/test_environment0/report.html'
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:46: FileNotFoundError
----------------------------- Captured stderr call -----------------------------
INTERNALERROR> Traceback (most recent call last):
INTERNALERROR> File "/usr/lib/python3.10/site-packages/_pytest/main.py", line 265, in wrap_session
INTERNALERROR> config._do_configure()
INTERNALERROR> File "/usr/lib/python3.10/site-packages/_pytest/config/__init__.py", line 982, in _do_configure
INTERNALERROR> self.hook.pytest_configure.call_historic(kwargs=dict(config=self))
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/hooks.py", line 308, in call_historic
INTERNALERROR> res = self._hookexec(self, self.get_hookimpls(), kwargs)
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/manager.py", line 93, in _hookexec
INTERNALERROR> return self._inner_hookexec(hook, methods, kwargs)
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/manager.py", line 84, in
INTERNALERROR> self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall(
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 208, in _multicall
INTERNALERROR> return outcome.get_result()
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 80, in get_result
INTERNALERROR> raise ex[1].with_traceback(ex[2])
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 187, in _multicall
INTERNALERROR> res = hook_impl.function(*args)
INTERNALERROR> File "/tmp/pytest-of-builduser/pytest-0/test_environment0/conftest.py", line 2, in pytest_configure
INTERNALERROR> config._metadata['content'] = '0.48373451797033695'
INTERNALERROR> AttributeError: 'Config' object has no attribute '_metadata'
_______________________ TestHTML.test_environment_xdist ________________________
self =
testdir =
def test_environment_xdist(self, testdir):
content = str(random.random())
testdir.makeconftest(
f"""
def pytest_configure(config):
for i in range(2):
config._metadata['content'] = '{content}'
"""
)
testdir.makepyfile("def test_pass(): pass")
> result, html = run(testdir, "report.html", "-n", "1")
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:770:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:42: in run
return result, read_html(path)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
path = local('/tmp/pytest-of-builduser/pytest-0/test_environment_xdist0/report.html')
def read_html(path):
> with open(str(path)) as f:
E FileNotFoundError: [Errno 2] No such file or directory: '/tmp/pytest-of-builduser/pytest-0/test_environment_xdist0/report.html'
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:46: FileNotFoundError
----------------------------- Captured stderr call -----------------------------
INTERNALERROR> Traceback (most recent call last):
INTERNALERROR> File "/usr/lib/python3.10/site-packages/_pytest/main.py", line 265, in wrap_session
INTERNALERROR> config._do_configure()
INTERNALERROR> File "/usr/lib/python3.10/site-packages/_pytest/config/__init__.py", line 982, in _do_configure
INTERNALERROR> self.hook.pytest_configure.call_historic(kwargs=dict(config=self))
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/hooks.py", line 308, in call_historic
INTERNALERROR> res = self._hookexec(self, self.get_hookimpls(), kwargs)
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/manager.py", line 93, in _hookexec
INTERNALERROR> return self._inner_hookexec(hook, methods, kwargs)
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/manager.py", line 84, in
INTERNALERROR> self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall(
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 208, in _multicall
INTERNALERROR> return outcome.get_result()
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 80, in get_result
INTERNALERROR> raise ex[1].with_traceback(ex[2])
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 187, in _multicall
INTERNALERROR> res = hook_impl.function(*args)
INTERNALERROR> File "/tmp/pytest-of-builduser/pytest-0/test_environment_xdist0/conftest.py", line 3, in pytest_configure
INTERNALERROR> config._metadata['content'] = '0.47721576626653495'
INTERNALERROR> AttributeError: 'Config' object has no attribute '_metadata'
____________________ TestHTML.test_environment_xdist_reruns ____________________
self =
testdir =
def test_environment_xdist_reruns(self, testdir):
content = str(random.random())
testdir.makeconftest(
f"""
def pytest_configure(config):
for i in range(2):
config._metadata['content'] = '{content}'
"""
)
testdir.makepyfile("def test_fail(): assert False")
> result, html = run(testdir, "report.html", "-n", "1", "--reruns", "1")
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:785:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:42: in run
return result, read_html(path)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
path = local('/tmp/pytest-of-builduser/pytest-0/test_environment_xdist_reruns0/report.html')
def read_html(path):
> with open(str(path)) as f:
E FileNotFoundError: [Errno 2] No such file or directory: '/tmp/pytest-of-builduser/pytest-0/test_environment_xdist_reruns0/report.html'
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:46: FileNotFoundError
----------------------------- Captured stderr call -----------------------------
INTERNALERROR> Traceback (most recent call last):
INTERNALERROR> File "/usr/lib/python3.10/site-packages/_pytest/main.py", line 265, in wrap_session
INTERNALERROR> config._do_configure()
INTERNALERROR> File "/usr/lib/python3.10/site-packages/_pytest/config/__init__.py", line 982, in _do_configure
INTERNALERROR> self.hook.pytest_configure.call_historic(kwargs=dict(config=self))
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/hooks.py", line 308, in call_historic
INTERNALERROR> res = self._hookexec(self, self.get_hookimpls(), kwargs)
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/manager.py", line 93, in _hookexec
INTERNALERROR> return self._inner_hookexec(hook, methods, kwargs)
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/manager.py", line 84, in
INTERNALERROR> self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall(
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 208, in _multicall
INTERNALERROR> return outcome.get_result()
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 80, in get_result
INTERNALERROR> raise ex[1].with_traceback(ex[2])
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 187, in _multicall
INTERNALERROR> res = hook_impl.function(*args)
INTERNALERROR> File "/tmp/pytest-of-builduser/pytest-0/test_environment_xdist_reruns0/conftest.py", line 3, in pytest_configure
INTERNALERROR> config._metadata['content'] = '0.7328299014917118'
INTERNALERROR> AttributeError: 'Config' object has no attribute '_metadata'
_ TestHTML.test_environment_list_value[content0-123Go, Hello, fzWZP6vKRv, garAge, hello] _
self =
testdir =
content = ('Hello', 'fzWZP6vKRv', 'hello', 'garAge', '123Go')
expected_content = '123Go, Hello, fzWZP6vKRv, garAge, hello'
@pytest.mark.parametrize(
"content,expected_content", _test_environment_list_value_data_set
)
def test_environment_list_value(self, testdir, content, expected_content):
expected_html_re = fr"content | \n\s+{expected_content} | "
testdir.makeconftest(
f"""
def pytest_configure(config):
for i in range(2):
config._metadata['content'] = {content}
"""
)
testdir.makepyfile("def test_pass(): pass")
> result, html = run(testdir)
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:815:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:42: in run
return result, read_html(path)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
path = local('/tmp/pytest-of-builduser/pytest-0/test_environment_list_value0/report.html')
def read_html(path):
> with open(str(path)) as f:
E FileNotFoundError: [Errno 2] No such file or directory: '/tmp/pytest-of-builduser/pytest-0/test_environment_list_value0/report.html'
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:46: FileNotFoundError
----------------------------- Captured stderr call -----------------------------
INTERNALERROR> Traceback (most recent call last):
INTERNALERROR> File "/usr/lib/python3.10/site-packages/_pytest/main.py", line 265, in wrap_session
INTERNALERROR> config._do_configure()
INTERNALERROR> File "/usr/lib/python3.10/site-packages/_pytest/config/__init__.py", line 982, in _do_configure
INTERNALERROR> self.hook.pytest_configure.call_historic(kwargs=dict(config=self))
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/hooks.py", line 308, in call_historic
INTERNALERROR> res = self._hookexec(self, self.get_hookimpls(), kwargs)
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/manager.py", line 93, in _hookexec
INTERNALERROR> return self._inner_hookexec(hook, methods, kwargs)
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/manager.py", line 84, in
INTERNALERROR> self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall(
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 208, in _multicall
INTERNALERROR> return outcome.get_result()
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 80, in get_result
INTERNALERROR> raise ex[1].with_traceback(ex[2])
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 187, in _multicall
INTERNALERROR> res = hook_impl.function(*args)
INTERNALERROR> File "/tmp/pytest-of-builduser/pytest-0/test_environment_list_value0/conftest.py", line 3, in pytest_configure
INTERNALERROR> config._metadata['content'] = ('Hello', 'fzWZP6vKRv', 'hello', 'garAge', '123Go')
INTERNALERROR> AttributeError: 'Config' object has no attribute '_metadata'
________ TestHTML.test_environment_list_value[content1-1, 2, 2, 4, 54] _________
self =
testdir =
content = (2, 4, 2, 1, 54), expected_content = '1, 2, 2, 4, 54'
@pytest.mark.parametrize(
"content,expected_content", _test_environment_list_value_data_set
)
def test_environment_list_value(self, testdir, content, expected_content):
expected_html_re = fr"content | \n\s+{expected_content} | "
testdir.makeconftest(
f"""
def pytest_configure(config):
for i in range(2):
config._metadata['content'] = {content}
"""
)
testdir.makepyfile("def test_pass(): pass")
> result, html = run(testdir)
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:815:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:42: in run
return result, read_html(path)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
path = local('/tmp/pytest-of-builduser/pytest-0/test_environment_list_value1/report.html')
def read_html(path):
> with open(str(path)) as f:
E FileNotFoundError: [Errno 2] No such file or directory: '/tmp/pytest-of-builduser/pytest-0/test_environment_list_value1/report.html'
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:46: FileNotFoundError
----------------------------- Captured stderr call -----------------------------
INTERNALERROR> Traceback (most recent call last):
INTERNALERROR> File "/usr/lib/python3.10/site-packages/_pytest/main.py", line 265, in wrap_session
INTERNALERROR> config._do_configure()
INTERNALERROR> File "/usr/lib/python3.10/site-packages/_pytest/config/__init__.py", line 982, in _do_configure
INTERNALERROR> self.hook.pytest_configure.call_historic(kwargs=dict(config=self))
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/hooks.py", line 308, in call_historic
INTERNALERROR> res = self._hookexec(self, self.get_hookimpls(), kwargs)
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/manager.py", line 93, in _hookexec
INTERNALERROR> return self._inner_hookexec(hook, methods, kwargs)
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/manager.py", line 84, in
INTERNALERROR> self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall(
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 208, in _multicall
INTERNALERROR> return outcome.get_result()
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 80, in get_result
INTERNALERROR> raise ex[1].with_traceback(ex[2])
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 187, in _multicall
INTERNALERROR> res = hook_impl.function(*args)
INTERNALERROR> File "/tmp/pytest-of-builduser/pytest-0/test_environment_list_value1/conftest.py", line 3, in pytest_configure
INTERNALERROR> config._metadata['content'] = (2, 4, 2, 1, 54)
INTERNALERROR> AttributeError: 'Config' object has no attribute '_metadata'
_________ TestHTML.test_environment_list_value[content2-400, 5.4, Yes] _________
self =
testdir =
content = ('Yes', 400, '5.4'), expected_content = '400, 5.4, Yes'
@pytest.mark.parametrize(
"content,expected_content", _test_environment_list_value_data_set
)
def test_environment_list_value(self, testdir, content, expected_content):
expected_html_re = fr"content | \n\s+{expected_content} | "
testdir.makeconftest(
f"""
def pytest_configure(config):
for i in range(2):
config._metadata['content'] = {content}
"""
)
testdir.makepyfile("def test_pass(): pass")
> result, html = run(testdir)
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:815:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:42: in run
return result, read_html(path)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
path = local('/tmp/pytest-of-builduser/pytest-0/test_environment_list_value2/report.html')
def read_html(path):
> with open(str(path)) as f:
E FileNotFoundError: [Errno 2] No such file or directory: '/tmp/pytest-of-builduser/pytest-0/test_environment_list_value2/report.html'
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:46: FileNotFoundError
----------------------------- Captured stderr call -----------------------------
INTERNALERROR> Traceback (most recent call last):
INTERNALERROR> File "/usr/lib/python3.10/site-packages/_pytest/main.py", line 265, in wrap_session
INTERNALERROR> config._do_configure()
INTERNALERROR> File "/usr/lib/python3.10/site-packages/_pytest/config/__init__.py", line 982, in _do_configure
INTERNALERROR> self.hook.pytest_configure.call_historic(kwargs=dict(config=self))
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/hooks.py", line 308, in call_historic
INTERNALERROR> res = self._hookexec(self, self.get_hookimpls(), kwargs)
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/manager.py", line 93, in _hookexec
INTERNALERROR> return self._inner_hookexec(hook, methods, kwargs)
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/manager.py", line 84, in
INTERNALERROR> self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall(
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 208, in _multicall
INTERNALERROR> return outcome.get_result()
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 80, in get_result
INTERNALERROR> raise ex[1].with_traceback(ex[2])
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 187, in _multicall
INTERNALERROR> res = hook_impl.function(*args)
INTERNALERROR> File "/tmp/pytest-of-builduser/pytest-0/test_environment_list_value2/conftest.py", line 3, in pytest_configure
INTERNALERROR> config._metadata['content'] = ('Yes', 400, '5.4')
INTERNALERROR> AttributeError: 'Config' object has no attribute '_metadata'
_ TestHTML.test_environment_unordered_dict_value[unordered_dict0-content | \\n\\s+{"123Go": 5, "Hello": 5, "fzWZP6vKRv": 10, "garAge": 6, "hello": 5} | ] _
self =
testdir =
unordered_dict = {'123Go': 5, 'Hello': 5, 'fzWZP6vKRv': 10, 'garAge': 6, ...}
expected_output = 'content | \\n\\s+{"123Go": 5, "Hello": 5, "fzWZP6vKRv": 10, "garAge": 6, "hello": 5} | '
@pytest.mark.parametrize(
"unordered_dict,expected_output",
[
(_unordered_dict, _unordered_dict_expected),
(_unordered_dict_with_html, _unordered_dict_with_html_expected),
],
)
def test_environment_unordered_dict_value(
self, testdir, unordered_dict, expected_output
):
testdir.makeconftest(
f"""
def pytest_configure(config):
values = dict({json.dumps(unordered_dict)})
config._metadata['content'] = values
"""
)
testdir.makepyfile("def test_pass(): pass")
> result, html = run(testdir)
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:855:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:42: in run
return result, read_html(path)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
path = local('/tmp/pytest-of-builduser/pytest-0/test_environment_unordered_dict_value0/report.html')
def read_html(path):
> with open(str(path)) as f:
E FileNotFoundError: [Errno 2] No such file or directory: '/tmp/pytest-of-builduser/pytest-0/test_environment_unordered_dict_value0/report.html'
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:46: FileNotFoundError
----------------------------- Captured stderr call -----------------------------
INTERNALERROR> Traceback (most recent call last):
INTERNALERROR> File "/usr/lib/python3.10/site-packages/_pytest/main.py", line 265, in wrap_session
INTERNALERROR> config._do_configure()
INTERNALERROR> File "/usr/lib/python3.10/site-packages/_pytest/config/__init__.py", line 982, in _do_configure
INTERNALERROR> self.hook.pytest_configure.call_historic(kwargs=dict(config=self))
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/hooks.py", line 308, in call_historic
INTERNALERROR> res = self._hookexec(self, self.get_hookimpls(), kwargs)
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/manager.py", line 93, in _hookexec
INTERNALERROR> return self._inner_hookexec(hook, methods, kwargs)
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/manager.py", line 84, in
INTERNALERROR> self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall(
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 208, in _multicall
INTERNALERROR> return outcome.get_result()
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 80, in get_result
INTERNALERROR> raise ex[1].with_traceback(ex[2])
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 187, in _multicall
INTERNALERROR> res = hook_impl.function(*args)
INTERNALERROR> File "/tmp/pytest-of-builduser/pytest-0/test_environment_unordered_dict_value0/conftest.py", line 3, in pytest_configure
INTERNALERROR> config._metadata['content'] = values
INTERNALERROR> AttributeError: 'Config' object has no attribute '_metadata'
_ TestHTML.test_environment_unordered_dict_value[unordered_dict1-content | \\n\\s+{"First Link": "W3Schools", "Second Link": "W2Schools", "Third Link": "W4Schools"} | ] _
self =
testdir =
unordered_dict = {'First Link': 'W3Schools', 'Second Link': 'W2Schools', 'Third Link': 'W4Schools'}
expected_output = 'content | \\n\\s+{"First Link": "W3Schools", "Second Link":...www.w3schools.com\\\\">W2Schools", "Third Link": "W4Schools"} | '
@pytest.mark.parametrize(
"unordered_dict,expected_output",
[
(_unordered_dict, _unordered_dict_expected),
(_unordered_dict_with_html, _unordered_dict_with_html_expected),
],
)
def test_environment_unordered_dict_value(
self, testdir, unordered_dict, expected_output
):
testdir.makeconftest(
f"""
def pytest_configure(config):
values = dict({json.dumps(unordered_dict)})
config._metadata['content'] = values
"""
)
testdir.makepyfile("def test_pass(): pass")
> result, html = run(testdir)
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:855:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:42: in run
return result, read_html(path)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
path = local('/tmp/pytest-of-builduser/pytest-0/test_environment_unordered_dict_value1/report.html')
def read_html(path):
> with open(str(path)) as f:
E FileNotFoundError: [Errno 2] No such file or directory: '/tmp/pytest-of-builduser/pytest-0/test_environment_unordered_dict_value1/report.html'
/build/python-pytest-html/src/python-pytest-html-3.1.1/testing/test_pytest_html.py:46: FileNotFoundError
----------------------------- Captured stderr call -----------------------------
INTERNALERROR> Traceback (most recent call last):
INTERNALERROR> File "/usr/lib/python3.10/site-packages/_pytest/main.py", line 265, in wrap_session
INTERNALERROR> config._do_configure()
INTERNALERROR> File "/usr/lib/python3.10/site-packages/_pytest/config/__init__.py", line 982, in _do_configure
INTERNALERROR> self.hook.pytest_configure.call_historic(kwargs=dict(config=self))
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/hooks.py", line 308, in call_historic
INTERNALERROR> res = self._hookexec(self, self.get_hookimpls(), kwargs)
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/manager.py", line 93, in _hookexec
INTERNALERROR> return self._inner_hookexec(hook, methods, kwargs)
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/manager.py", line 84, in
INTERNALERROR> self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall(
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 208, in _multicall
INTERNALERROR> return outcome.get_result()
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 80, in get_result
INTERNALERROR> raise ex[1].with_traceback(ex[2])
INTERNALERROR> File "/usr/lib/python3.10/site-packages/pluggy/callers.py", line 187, in _multicall
INTERNALERROR> res = hook_impl.function(*args)
INTERNALERROR> File "/tmp/pytest-of-builduser/pytest-0/test_environment_unordered_dict_value1/conftest.py", line 3, in pytest_configure
INTERNALERROR> config._metadata['content'] = values
INTERNALERROR> AttributeError: 'Config' object has no attribute '_metadata'
=========================== short test summary info ============================
FAILED testing/test_pytest_html.py::TestHTML::test_environment - FileNotFound...
FAILED testing/test_pytest_html.py::TestHTML::test_environment_xdist - FileNo...
FAILED testing/test_pytest_html.py::TestHTML::test_environment_xdist_reruns
FAILED testing/test_pytest_html.py::TestHTML::test_environment_list_value[content0-123Go, Hello, fzWZP6vKRv, garAge, hello]
FAILED testing/test_pytest_html.py::TestHTML::test_environment_list_value[content1-1, 2, 2, 4, 54]
FAILED testing/test_pytest_html.py::TestHTML::test_environment_list_value[content2-400, 5.4, Yes]
FAILED testing/test_pytest_html.py::TestHTML::test_environment_unordered_dict_value[unordered_dict0-content | \\n\\s+{"123Go": 5, "Hello": 5, "fzWZP6vKRv": 10, "garAge": 6, "hello": 5} | ]
FAILED testing/test_pytest_html.py::TestHTML::test_environment_unordered_dict_value[unordered_dict1-content | \\n\\s+{"First Link": "W3Schools", "Second Link": "W2Schools", "Third Link": "W4Schools"} | ]
======================== 8 failed, 81 passed in 51.84s =========================
[1m[31m==> ERROR:[m[1m A failure occurred in check().[m
[1m Aborting...[m