We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9fc42b1 commit ffb9581Copy full SHA for ffb9581
testing/python/metafunc.py
@@ -1438,7 +1438,7 @@ def test_parametrize_scope_overrides(
1438
self, pytester: Pytester, scope: str, length: int
1439
) -> None:
1440
pytester.makepyfile(
1441
- """
+ f"""
1442
import pytest
1443
values = []
1444
def pytest_generate_tests(metafunc):
@@ -1454,9 +1454,9 @@ def test_hello(arg):
1454
def test_world(arg):
1455
assert arg in (1,2)
1456
def test_checklength():
1457
- assert len(values) == %d
1458
- """ # noqa: UP031 (str have no __repr__)
1459
- % (scope, length)
+ assert len(values) == {length}
+ """
+ % scope
1460
)
1461
reprec = pytester.inline_run()
1462
reprec.assertoutcome(passed=5)
0 commit comments