benchmark script tests: make the match string for invalid option errors more flexible

Because the actual output depends on the python version
This commit is contained in:
Erik Eckstein
2025-07-25 15:21:49 +02:00
parent ca50986f3a
commit ce86f65272
2 changed files with 2 additions and 2 deletions

View File

@@ -112,7 +112,7 @@ class Test_parse_args(unittest.TestCase):
[
"error:",
"argument -o/--optimization: invalid choice: 'bogus'",
"(choose from 'O', 'Onone', 'Osize')",
"(choose from ",
],
err.getvalue(),
)

View File

@@ -860,7 +860,7 @@ class Test_parse_args(unittest.TestCase):
)
self.assertIn(
"error: argument --format: invalid choice: 'bogus' "
"(choose from 'markdown', 'git', 'html')",
"(choose from ",
err.getvalue(),
)