File tree Expand file tree Collapse file tree 1 file changed +20
-0
lines changed
tests/functional/event_handler/_pydantic Expand file tree Collapse file tree 1 file changed +20
-0
lines changed Original file line number Diff line number Diff line change 33 APIKey ,
44 APIKeyIn ,
55 HTTPBearer ,
6+ MutualTLS ,
67 OAuth2 ,
78 OAuthFlowImplicit ,
89 OAuthFlows ,
@@ -110,3 +111,22 @@ def handler():
110111 open_id_connect_scheme = security_schemes ["openIdConnect" ]
111112 assert open_id_connect_scheme .type_ .value == "openIdConnect"
112113 assert open_id_connect_scheme .openIdConnectUrl == "https://example.com/oauth2/authorize"
114+
115+
116+ def test_openapi_security_scheme_mtls ():
117+ app = APIGatewayRestResolver ()
118+
119+ @app .get ("/" )
120+ def handler ():
121+ raise NotImplementedError ()
122+
123+ schema = app .get_openapi_schema (
124+ security_schemes = {
125+ "mutualTLS" : MutualTLS (),
126+ },
127+ )
128+
129+ security_schemes = schema .components .securitySchemes
130+ assert security_schemes is not None
131+
132+ assert "mutualTLS" in security_schemes
You can’t perform that action at this time.
0 commit comments