Skip to content

Async fixtures appear to be broken with pytest==3.7 #90

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

Closed
orf opened this issue Aug 2, 2018 · 1 comment
Closed

Async fixtures appear to be broken with pytest==3.7 #90

orf opened this issue Aug 2, 2018 · 1 comment

Comments

@orf
Copy link

orf commented Aug 2, 2018

Given a simple async fixture and test:

@pytest.fixture()
async def my_client(aiohttp_client):
    return await aiohttp_client(make_app())

async def test_x(my_client):
    await my_client.get('/abc/')

Results in an exception: AttributeError: 'coroutine' object has no attribute 'get'

Downgrading to pytest<3.7 fixed this.

@nicoddemus
Copy link
Member

Thanks for reporting, this is a duplicate of #89.

This will be fixed with pytest 3.7.1, due to be released today. 👍

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

2 participants