From 7a529a45c653f6ddb4ee02fe0097d5a5472a0745 Mon Sep 17 00:00:00 2001 From: Jacob Heider Date: Mon, 22 Apr 2024 10:17:30 -0400 Subject: [PATCH] fix(swagger-v2) closes #5935 --- .../swagger.io/swagger-codegen/package.yml | 26 ++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) diff --git a/projects/swagger.io/swagger-codegen/package.yml b/projects/swagger.io/swagger-codegen/package.yml index 14245008..5418dcee 100644 --- a/projects/swagger.io/swagger-codegen/package.yml +++ b/projects/swagger.io/swagger-codegen/package.yml @@ -27,7 +27,8 @@ provides: test: - run: swagger-codegen generate -i $FIXTURE -l html - fixture: + if: '>=3' + fixture: content: | openapi: 3.0.0 info: @@ -40,5 +41,28 @@ test: 200: description: OK extname: yaml + - run: swagger-codegen generate -i $FIXTURE -l html + if: <3 + fixture: + content: | + { + "swaggerVersion": "2.0.0", + "info": { + "version": "0.0.0", + "title": "Simple API" + }, + "paths": { + "/": { + "get": { + "responses": { + "200": { + "description": "OK" + } + } + } + } + } + } + extname: json - cat index.html | grep "Simple API" - swagger-codegen version | grep {{version}}