@@ -63,8 +63,7 @@ def test_invalid_function_definition_missing_function_file():
6363 create_asgi_app (target , source )
6464
6565 assert re .match (
66- r"File .* that is expected to define function doesn't exist" , str (
67- excinfo .value )
66+ r"File .* that is expected to define function doesn't exist" , str (excinfo .value )
6867 )
6968
7069
@@ -98,8 +97,7 @@ def test_asgi_background_event_not_supported():
9897async def test_lazy_asgi_app (monkeypatch ):
9998 actual_app = AsyncMock ()
10099 create_asgi_app_mock = Mock (return_value = actual_app )
101- monkeypatch .setattr (
102- "functions_framework.aio.create_asgi_app" , create_asgi_app_mock )
100+ monkeypatch .setattr ("functions_framework.aio.create_asgi_app" , create_asgi_app_mock )
103101
104102 # Test that it's lazy
105103 target , source , signature_type = "func" , "source.py" , "http"
@@ -119,8 +117,7 @@ async def test_lazy_asgi_app(monkeypatch):
119117 assert lazy_app .app is actual_app
120118 assert lazy_app ._app_initialized is True
121119 assert create_asgi_app_mock .call_count == 1
122- assert create_asgi_app_mock .call_args == call (
123- target , source , signature_type )
120+ assert create_asgi_app_mock .call_args == call (target , source , signature_type )
124121
125122 # Verify the app was called
126123 actual_app .assert_called_once_with (scope , receive , send )
@@ -132,8 +129,7 @@ async def test_lazy_asgi_app(monkeypatch):
132129 await lazy_app (scope , receive , send )
133130
134131 assert create_asgi_app_mock .call_count == 0 # Should not create app again
135- actual_app .assert_called_once_with (
136- scope , receive , send ) # Should be called again
132+ actual_app .assert_called_once_with (scope , receive , send ) # Should be called again
137133
138134
139135@pytest .mark .asyncio
0 commit comments