Skip to content

Commit

Permalink
Rename app_factory -> app_or_factory
Browse files Browse the repository at this point in the history
  • Loading branch information
asvetlov committed Aug 18, 2016
1 parent 9d873f2 commit 4599080
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions aiohttp/pytest_plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,13 +55,13 @@ def test_client(loop):
clients = []

@asyncio.coroutine
def _create_from_app_factory(app_factory, *args, **kwargs):
if not isinstance(app_factory, Application):
app = app_factory(loop, *args, **kwargs)
def _create_from_app_factory(app_or_factory, *args, **kwargs):
if not isinstance(app_or_factory, Application):
app = app_or_factory(loop, *args, **kwargs)
else:
assert not args, "args should be empty"
assert not kwargs, "kwargs should be empty"
app = app_factory
app = app_or_factory

assert app.loop is loop, \
"Application is attached to other event loop"
Expand Down

0 comments on commit 4599080

Please sign in to comment.