Tmpfile fixture

This commit is contained in:
Eliot Berriot 2018-04-16 21:57:53 +02:00
parent 168b2f03d4
commit adcbe8852d
No known key found for this signature in database
GPG Key ID: DD6965E2476E5C27
1 changed files with 5 additions and 0 deletions

View File

@ -69,6 +69,11 @@ def tmpdir():
shutil.rmtree(d)
@pytest.fixture
def tmpfile():
yield tempfile.NamedTemporaryFile()
@pytest.fixture
def logged_in_client(db, factories, client):
user = factories['users.User']()