@@ -55,9 +55,9 @@ def access_protected():
5555
5656
5757def test_header_access (app , app_with_locations ):
58- for app in (app , app_with_locations ):
58+ for test_app in (app , app_with_locations ):
5959 test_client = app .test_client ()
60- with app .test_request_context ():
60+ with test_app .test_request_context ():
6161 access_token = create_access_token ("username" )
6262
6363 access_headers = {"Authorization" : "Bearer {}" .format (access_token )}
@@ -67,18 +67,18 @@ def test_header_access(app, app_with_locations):
6767
6868
6969def test_cookie_access (app , app_with_locations ):
70- for app in (app , app_with_locations ):
71- test_client = app .test_client ()
70+ for test_app in (app , app_with_locations ):
71+ test_client = test_app .test_client ()
7272 test_client .get ("/cookie_login" )
7373 response = test_client .get ("/protected" )
7474 assert response .status_code == 200
7575 assert response .get_json () == {"foo" : "bar" , "location" : "cookies" }
7676
7777
7878def test_query_string_access (app , app_with_locations ):
79- for app in (app , app_with_locations ):
80- test_client = app .test_client ()
81- with app .test_request_context ():
79+ for test_app in (app , app_with_locations ):
80+ test_client = test_app .test_client ()
81+ with test_app .test_request_context ():
8282 access_token = create_access_token ("username" )
8383
8484 url = "/protected?jwt={}" .format (access_token )
@@ -88,9 +88,9 @@ def test_query_string_access(app, app_with_locations):
8888
8989
9090def test_json_access (app , app_with_locations ):
91- for app in (app , app_with_locations ):
92- test_client = app .test_client ()
93- with app .test_request_context ():
91+ for test_app in (app , app_with_locations ):
92+ test_client = test_app .test_client ()
93+ with test_app .test_request_context ():
9494 access_token = create_access_token ("username" )
9595 data = {"access_token" : access_token }
9696 response = test_client .post ("/protected" , json = data )
0 commit comments