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

Replace pytest-lazyfixture for pytest >= 8.0 #2732

Closed
mraspaud opened this issue Jan 30, 2024 · 2 comments
Closed

Replace pytest-lazyfixture for pytest >= 8.0 #2732

mraspaud opened this issue Jan 30, 2024 · 2 comments
Labels

Comments

@mraspaud
Copy link
Member

Pytest-lazyfixture does not support pytest >=8 and seems to be unmaintained.

A possible solution is to apply some of the fixes mentionned here:
TvoroG/pytest-lazy-fixture#65

@mraspaud mraspaud added the bug label Jan 30, 2024
@verduijn
Copy link
Contributor

Would this be an acceptable implementation?

@pytest.mark.parametrize("some_lazy_fixture_string", ["fixture_1", "fixture_2"])
def test_function(some_lazy_fixture_string, request):
    some_lazy_fixture_string = request.getfixturevalue(some_lazy_fixture_string)
    ...

The conftest.py custom lazy_fixture example seem a little magical, but that might just be my preference.

@djhoese
Copy link
Member

djhoese commented Jun 24, 2024

Hm this was actually fixed a while ago in #2801 but it looks like the issue never got closed.

@djhoese djhoese closed this as completed Jun 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants