Skip to content

Commit c8ac448

Browse files
committed
test: sometimes pytest directories have a "popen" component
Those have to be scrubbed too. I'm not sure why it's sometimes there, sometimes not. Maybe xdist?
1 parent bb2bc1a commit c8ac448

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

tests/test_html.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -581,7 +581,7 @@ def compare_html(expected, actual, extra_scrubs=None):
581581
(filepath_to_regex(flat_rootname(str(os.getcwd()))), '_TEST_TMPDIR'),
582582
(filepath_to_regex(abs_file(os.getcwd())), 'TEST_TMPDIR'),
583583
(filepath_to_regex(flat_rootname(str(abs_file(os.getcwd())))), '_TEST_TMPDIR'),
584-
(r'/private/var/folders/[\w/]{35}/pytest-of-\w+/pytest-\d+/t\d+', 'TEST_TMPDIR'),
584+
(r'/private/var/[\w/]+/pytest-of-\w+/pytest-\d+/(popen-gw\d+/)?t\d+', 'TEST_TMPDIR'),
585585
]
586586
if env.WINDOWS:
587587
# For file paths...
@@ -852,9 +852,10 @@ def test_other(self):
852852
],
853853
)
854854
contains(
855-
"out/other/index.html",
855+
'out/other/index.html',
856856
'<a href="here_py.html">here.py</a>',
857-
'other_py.html">', 'other.py</a>',
857+
'other_py.html">',
858+
'other.py</a>',
858859
)
859860

860861
def test_partial(self):

0 commit comments

Comments
 (0)