Skip to content

Commit 8111d82

Browse files
committed
Correct the regex matching the printed error.
1 parent 41ed908 commit 8111d82

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Lib/test/test_import/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -377,7 +377,7 @@ def test_from_import_missing_attr_has_name_and_so_path(self):
377377
self.assertEqual(cm.exception.path, _testcapi.__spec__.origin)
378378
self.assertRegex(
379379
str(cm.exception),
380-
r"cannot import name 'i_dont_exist' from '_testcapi' \(.*\.(so|pyd)?\)"
380+
r"cannot import name 'i_dont_exist' from '_testcapi' \(.*(\.(so|pyd))?\)"
381381
)
382382
else:
383383
self.assertEqual(

0 commit comments

Comments
 (0)