Skip to content

Commit

Permalink
tests: fix test for new openapi docs
Browse files Browse the repository at this point in the history
  • Loading branch information
JonasKs committed Nov 10, 2022
1 parent b8c93a4 commit 66ad9de
Showing 1 changed file with 26 additions and 25 deletions.
51 changes: 26 additions & 25 deletions tests/test_openapi_scheme.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,32 +71,33 @@
},
'securitySchemes': {
'APIKeyHeader': {'in': 'header', 'name': 'TEST-API-KEY', 'type': 'apiKey'},
'Azure AD - PKCE, Multi-tenant': {
'Azure AD - PKCE, B2C Multi-tenant': {
'description': '`Leave ' 'client_secret ' 'blank`',
'flows': {
'authorizationCode': {
'authorizationUrl': 'https://login.microsoftonline.com/common/oauth2/v2.0/authorize',
'authorizationUrl': 'https://dummy.com/',
'scopes': {
'api://oauth299-9999-9999-abcd-efghijkl1234567890/user_impersonation': 'User '
'impersonation'
},
'tokenUrl': 'https://login.microsoftonline.com/common/oauth2/v2.0/token',
'tokenUrl': 'https://dummy.com/',
}
},
'type': 'oauth2',
},
'Azure AD - PKCE, B2C Multi-tenant': {
'type': 'oauth2',
'description': '`Leave client_secret blank`',
'Azure AD - PKCE, Multi-tenant': {
'description': '`Leave ' 'client_secret ' 'blank`',
'flows': {
'authorizationCode': {
'authorizationUrl': 'https://login.microsoftonline.com/common/oauth2/v2.0/authorize',
'scopes': {
'api://oauth299-9999-9999-abcd-efghijkl1234567890/user_impersonation': 'User impersonation'
'api://oauth299-9999-9999-abcd-efghijkl1234567890/user_impersonation': 'User '
'impersonation'
},
'authorizationUrl': 'https://dummy.com/',
'tokenUrl': 'https://dummy.com/',
'tokenUrl': 'https://login.microsoftonline.com/common/oauth2/v2.0/token',
}
},
'type': 'oauth2',
},
'Azure AD - PKCE, Single-tenant': {
'description': '`Leave ' 'client_secret ' 'blank`',
Expand Down Expand Up @@ -125,21 +126,6 @@
},
'openapi': '3.0.2',
'paths': {
'/api/v1/hello-multi-auth-b2c': {
'get': {
'description': 'Wonder how ' 'this auth is ' 'done?',
'operationId': 'helloWorldApiKey',
'responses': {
'200': {
'content': {'application/json': {'schema': {'$ref': '#/components/schemas/TokenType'}}},
'description': 'Successful ' 'Response',
}
},
'security': [{'Azure AD - PKCE, B2C Multi-tenant': []}, {'APIKeyHeader': []}],
'summary': 'Say hello with an ' 'API key',
'tags': ['hello'],
}
},
'/api/v1/hello': {
'get': {
'description': 'Wonder who we say hello ' 'to?',
Expand All @@ -152,7 +138,7 @@
'description': 'Successful ' 'Response',
}
},
'security': [{'Azure AD - PKCE, Single-tenant': []}],
'security': [{'Azure AD - PKCE, Single-tenant': []}, {'Azure AD - PKCE, Single-tenant': []}],
'summary': 'Say hello',
'tags': ['hello'],
}
Expand Down Expand Up @@ -189,6 +175,21 @@
'tags': ['hello'],
}
},
'/api/v1/hello-multi-auth-b2c': {
'get': {
'description': 'Wonder how ' 'this auth ' 'is done?',
'operationId': 'helloWorldApiKey',
'responses': {
'200': {
'content': {'application/json': {'schema': {'$ref': '#/components/schemas/TokenType'}}},
'description': 'Successful ' 'Response',
}
},
'security': [{'Azure AD - PKCE, B2C Multi-tenant': []}, {'APIKeyHeader': []}],
'summary': 'Say hello with ' 'an API key',
'tags': ['hello'],
}
},
},
}

Expand Down

0 comments on commit 66ad9de

Please sign in to comment.