Added Swagger

This commit is contained in:
2020-06-10 08:25:21 +02:00
parent 5c6f37eaf7
commit af76cbca87
257 changed files with 48861 additions and 12 deletions
@@ -0,0 +1,50 @@
import { expectNoErrors } from "../validate-helper.js"
describe("editor bug #1817 - path parameter semantic error with TRACE", function() {
it("should return no problems for a path parameter defined in a Swagger 2 TRACE operation", function () {
const spec = {
swagger: "2.0",
paths: {
"/CoolPath/{id}": {
trace: {
parameters: [
{
name: "id",
in: "path",
required: true,
schema: {
type: "string"
}
}
]
}
}
}
}
return expectNoErrors(spec)
})
it("should return no problems for a path parameter defined in an OpenAPI 3 TRACE operation", function () {
const spec = {
openapi: "3.0.0",
paths: {
"/CoolPath/{id}": {
trace: {
parameters: [
{
name: "id",
in: "path",
required: true,
schema: {
type: "string"
}
}
]
}
}
}
}
return expectNoErrors(spec)
})
})