File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ def get_max_test_id_length() -> int:
1818def get_test_id_regex () -> None | re .Pattern [str ]:
1919 """Return regex to use for checking test ids."""
2020 if int (os .environ .get ("PYTEST_CHECK_TEST_ID_REGEX" , "1" )):
21- return re .compile (r"^\w +$" )
21+ return re .compile (r"^[\w_\-\.] +$" )
2222 return None
2323
2424
Original file line number Diff line number Diff line change @@ -60,7 +60,7 @@ def test_a(some: str):
6060 result = pytester .runpytest_inprocess ("--collect-only" , p1 )
6161 if not disable :
6262 assert (
63- "Test <Function test_a[invalid name]> has an id that does not match our safe pattern '^\\ w +$' for use with a terminal."
63+ "Test <Function test_a[invalid name]> has an id that does not match our safe pattern '^[ \\ w_ \\ - \\ .] +$' for use with a terminal."
6464 in result .stderr .lines
6565 )
6666 assert result .ret == rc
You can’t perform that action at this time.
0 commit comments