From 4309451080a1d6ac35742b4b630022623c1d2aa1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thor=20Anker=20Kvisg=C3=A5rd=20Lange?= Date: Sun, 7 Jul 2024 16:13:01 +0200 Subject: [PATCH] fix: Further upgrades --- pom.xml | 4 ++-- src/test/resources/expectedOutput/full/open-api.json | 2 +- src/test/resources/expectedOutput/full/open-api.yaml | 1 + 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/pom.xml b/pom.xml index 1d856e6..dca81cb 100644 --- a/pom.xml +++ b/pom.xml @@ -50,13 +50,13 @@ UTF-8 UTF-8 - 2.12.2 + 2.16.2 30.0-jre 1.8.0 2.7.0-01 2.0.4-04 1.0.8 - 2.2.4 + 2.2.22 2.3.0 2.1 4.13.1 diff --git a/src/test/resources/expectedOutput/full/open-api.json b/src/test/resources/expectedOutput/full/open-api.json index 7ff8c06..1a71fc2 100644 --- a/src/test/resources/expectedOutput/full/open-api.json +++ b/src/test/resources/expectedOutput/full/open-api.json @@ -1 +1 @@ -{"openapi":"3.0.1","info":{"title":"Title","description":"# Description\n\nThis is some description to be included.","termsOfService":"Terms","contact":{"name":"My Name","url":"https://google.com","email":"e@mail.com"},"license":{"name":"MIT","url":"https://license"},"version":"1.0.0","x-custom-property":"In Info"},"externalDocs":{"description":"Some external doc at config level","url":"https://example.org","x-custom-property":"In configs's external document"},"servers":[{"url":"https://{sub}.example.it/base/path","description":"Example URL","variables":{"sub":{"description":"The Subdomain","default":"services","enum":["services","web","main"],"x-custom-property":"In ServerVariable"}},"x-custom-property":"In Server"}],"security":[{"first":[]},{"third":["requiredScope1","requiredScope2"]}],"tags":[{"name":"MyTag","description":"MyDescription","externalDocs":{"description":"Some tag's external doc","url":"https://tag.example.org","x-custom-property":"In tag's external document"},"x-custom-property":"In tag"}],"paths":{"/accounts":{"get":{"operationId":"list","responses":{"default":{"description":"default response","content":{"application/hal+json":{}}}}}},"/accounts/{regNo}-{accountNo}":{"get":{"description":"Get single account","operationId":"get","parameters":[{"name":"regNo","in":"path","required":true,"schema":{"pattern":"^[0-9]{4}$","type":"string"}},{"name":"accountNo","in":"path","required":true,"schema":{"pattern":"^[0-9]+$","type":"string"}}],"responses":{"404":{"description":"No account found."}}},"put":{"description":"Create new or update existing account","operationId":"createOrUpdate","parameters":[{"name":"regNo","in":"path","required":true,"schema":{"pattern":"^[0-9]{4}$","type":"string"}},{"name":"accountNo","in":"path","required":true,"schema":{"pattern":"^[0-9]+$","type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountUpdateRepresentation"}}}},"responses":{"404":{"description":"No updating possible"}}}}},"components":{"schemas":{"AccountUpdateRepresentation":{"required":["name"],"type":"object","properties":{"accountNo":{"pattern":"^[0-9]+$","type":"string"},"name":{"pattern":".{1,40}","type":"string"},"regNo":{"pattern":"^[0-9]{4}$","type":"string"}}}},"securitySchemes":{"first":{"type":"apiKey","description":"Via web gateway","name":"X-API-TOKEN","in":"header"},"fourth":{"type":"openIdConnect","openIdConnectUrl":"https://id.example.org"},"second":{"type":"http","scheme":"MyCredentials","bearerFormat":"password"},"third":{"type":"oauth2","flows":{"implicit":{"authorizationUrl":"https://auth.example.org","refreshUrl":"https://refresh.example.org","scopes":{"x":"y"},"x-custom-property":"In third SecurityScheme's implicit flow"},"password":{"tokenUrl":"https://token.example.org"},"clientCredentials":{"tokenUrl":"https://client.token.example.org"},"authorizationCode":{"authorizationUrl":"https://code.auth.example.org","tokenUrl":"https://code.token.example.org"},"x-custom-property":"In third SecurityScheme's flow"}}}},"x-custom-property":"In Config"} \ No newline at end of file +{"openapi":"3.0.1","info":{"title":"Title","description":"# Description\n\nThis is some description to be included.","termsOfService":"Terms","contact":{"name":"My Name","url":"https://google.com","email":"e@mail.com"},"license":{"name":"MIT","url":"https://license"},"version":"1.0.0","x-custom-property":"In Info"},"externalDocs":{"description":"Some external doc at config level","url":"https://example.org","x-custom-property":"In configs's external document"},"servers":[{"url":"https://{sub}.example.it/base/path","description":"Example URL","variables":{"sub":{"description":"The Subdomain","default":"services","enum":["services","web","main"],"x-custom-property":"In ServerVariable"}},"x-custom-property":"In Server"}],"security":[{"first":[]},{"third":["requiredScope1","requiredScope2"]}],"tags":[{"name":"MyTag","description":"MyDescription","externalDocs":{"description":"Some tag's external doc","url":"https://tag.example.org","x-custom-property":"In tag's external document"},"x-custom-property":"In tag"}],"paths":{"/accounts":{"get":{"operationId":"list","responses":{"default":{"description":"default response","content":{"application/hal+json":{}}}}}},"/accounts/{regNo}-{accountNo}":{"get":{"description":"Get single account","operationId":"get","parameters":[{"name":"regNo","in":"path","required":true,"schema":{"pattern":"^[0-9]{4}$","type":"string"}},{"name":"accountNo","in":"path","required":true,"schema":{"pattern":"^[0-9]+$","type":"string"}}],"responses":{"404":{"description":"No account found."}}},"put":{"description":"Create new or update existing account","operationId":"createOrUpdate","parameters":[{"name":"regNo","in":"path","required":true,"schema":{"pattern":"^[0-9]{4}$","type":"string"}},{"name":"accountNo","in":"path","required":true,"schema":{"pattern":"^[0-9]+$","type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountUpdateRepresentation"}}}},"responses":{"404":{"description":"No updating possible"}}}}},"components":{"schemas":{"AccountUpdateRepresentation":{"required":["name"],"type":"object","properties":{"accountNo":{"pattern":"^[0-9]+$","type":"string"},"name":{"pattern":".{1,40}","type":"string"},"regNo":{"pattern":"^[0-9]{4}$","type":"string"}}}},"securitySchemes":{"first":{"type":"apiKey","description":"Via web gateway","name":"X-API-TOKEN","in":"header","x-custom-property":"In first SecurityScheme"},"fourth":{"type":"openIdConnect","openIdConnectUrl":"https://id.example.org"},"second":{"type":"http","scheme":"MyCredentials","bearerFormat":"password"},"third":{"type":"oauth2","flows":{"implicit":{"authorizationUrl":"https://auth.example.org","refreshUrl":"https://refresh.example.org","scopes":{"x":"y"},"x-custom-property":"In third SecurityScheme's implicit flow"},"password":{"tokenUrl":"https://token.example.org"},"clientCredentials":{"tokenUrl":"https://client.token.example.org"},"authorizationCode":{"authorizationUrl":"https://code.auth.example.org","tokenUrl":"https://code.token.example.org"},"x-custom-property":"In third SecurityScheme's flow"}}}},"x-custom-property":"In Config"} \ No newline at end of file diff --git a/src/test/resources/expectedOutput/full/open-api.yaml b/src/test/resources/expectedOutput/full/open-api.yaml index d7edb5f..530e257 100644 --- a/src/test/resources/expectedOutput/full/open-api.yaml +++ b/src/test/resources/expectedOutput/full/open-api.yaml @@ -120,6 +120,7 @@ components: description: Via web gateway name: X-API-TOKEN in: header + x-custom-property: In first SecurityScheme fourth: type: openIdConnect openIdConnectUrl: https://id.example.org