Skip to content
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

autouse=True of lazy_fixture breaks nose tests #50

Open
MRigal opened this issue May 4, 2020 · 0 comments
Open

autouse=True of lazy_fixture breaks nose tests #50

MRigal opened this issue May 4, 2020 · 0 comments

Comments

@MRigal
Copy link

MRigal commented May 4, 2020

Hi all,

We have some legacy nose-style tests in our test suite. They are also run nicely via pytest (https://docs.pytest.org/en/latest/nose.html).

Today I've tried to add a fixture with parametrization using lazy_fixture in combination with autouse=True and the tests are now ERRORing with:

_____ ERROR at setup of MyNoseTestClass.test_foo ________
test_foo does not support fixtures, maybe unittest.TestCase subclass?
Node id: path/test_foo.py::MyNoseTestClass::test_foo
Function type: TestCaseFunction

The indication is right and maybe some check would avoid this issue.

Not that some other fixtures with autouse=True but without lazy_fixture are not changing the test behaviour

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant