Skip to content

funcarg_prefix_warning: remove newline #1724

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion _pytest/fixtures.py
Original file line number Diff line number Diff line change
Expand Up @@ -868,7 +868,7 @@ def yield_fixture(scope="function", params=None, autouse=False, ids=None, name=N
defaultfuncargprefixmarker = fixture()
funcarg_prefix_warning = (
'{name}: declaring fixtures using "pytest_funcarg__" prefix is deprecated '
'and scheduled to be removed in pytest 4.0.\n'
'and scheduled to be removed in pytest 4.0. '
'Please remove the prefix and use the @pytest.fixture decorator instead.')


Expand Down
6 changes: 4 additions & 2 deletions testing/acceptance_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -789,7 +789,9 @@ def test_funcarg_prefix(value):
""")
result = testdir.runpytest('-ra')
result.stdout.fnmatch_lines([
'*declaring fixtures using "pytest_funcarg__" prefix is deprecated and scheduled to be removed in pytest 4.0*',
'*remove the prefix and use the @pytest.fixture decorator instead*',
('WC1 None pytest_funcarg__value: '
'declaring fixtures using "pytest_funcarg__" prefix is deprecated '
'and scheduled to be removed in pytest 4.0. '
'Please remove the prefix and use the @pytest.fixture decorator instead.'),
'*1 passed*',
])