Skip to content

Commit

Permalink
Fix Header OneOf check in OpenAPI 3.1 (#120)
Browse files Browse the repository at this point in the history
  • Loading branch information
vearutop authored Jun 25, 2024
1 parent 1177f44 commit b360d58
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 23 deletions.
32 changes: 10 additions & 22 deletions openapi31/entities.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 10 additions & 1 deletion openapi31/entities_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ func TestSpec_UnmarshalYAML(t *testing.T) {
func TestSpec_UnmarshalYAML_refsInResponseHeaders(t *testing.T) {
var s openapi31.Spec

spec := `openapi: 3.1.0f
spec := `openapi: 3.1.0
info:
description: description
license:
Expand Down Expand Up @@ -47,6 +47,15 @@ paths:
headers:
Cache-Control:
$ref: '#/components/headers/CacheControl'
Authorisation:
schema:
type: string
Custom:
content:
"text/plain":
schema:
type: string
components:
headers:
CacheControl:
Expand Down

0 comments on commit b360d58

Please sign in to comment.