File tree Expand file tree Collapse file tree 1 file changed +21
-2
lines changed
Expand file tree Collapse file tree 1 file changed +21
-2
lines changed Original file line number Diff line number Diff line change @@ -547,8 +547,8 @@ def test_batch_supports_post_json_query_with_json_variables(app):
547547 assert response_json (response ) == [{
548548 'data' : {'test' : "Hello Dolly" },
549549 }]
550-
551-
550+
551+
552552@parametrize_sync_async_app_test ('app' , batch = True )
553553def test_batch_allows_post_with_operation_name (app ):
554554 _ , response = app .client .post (
@@ -588,3 +588,22 @@ def test_async_schema(app):
588588 'a' : 'hey' , 'b' : 'hey2' , 'c' : 'hey3'
589589 }
590590 }
591+
592+
593+ @parametrize_sync_async_app_test ('app' )
594+ def test_preflight_request (app ):
595+ _ , response = app .client .options (uri = url_string (), headers = {
596+ 'Access-Control-Request-Method' : 'POST' ,
597+ })
598+
599+ assert response .status == 200
600+
601+
602+ @parametrize_sync_async_app_test ('app' )
603+ def test_preflight_incorrect_request (app ):
604+ _ , response = app .client .options (uri = url_string (), headers = {
605+ 'Access-Control-Request-Method' : 'OPTIONS' ,
606+ })
607+
608+ assert response .status == 400
609+
You can’t perform that action at this time.
0 commit comments