rspec-openapi 0.30.0 → 0.30.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/rspec/openapi/schema_builder.rb +3 -0
- data/lib/rspec/openapi/schema_cleaner.rb +3 -2
- data/lib/rspec/openapi/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: ac25084c38b7c495cf2197cfa26341339d3ea7bb6326a6d23fa35a41d4f1091b
|
|
4
|
+
data.tar.gz: 14b30d2bbb595dc55ffd5252b37e4ba3ce6a6fab6c7c38a1ddbe6aa3c4afb329
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 96cb0d669e6091b46ec82d86f69f427b3790ce390e73a6c1d654e46a59e70f615a394490abbefae0757fde329b1ab5d65cb392900f64a97b5769c7663da1e9a3
|
|
7
|
+
data.tar.gz: ec43dcd03bb3ff4444aa3a5cafd20bd4af26151717db730c7a36b9c25ede0aae95033b99fd3a52f20d38ca7f9c9abeb0d59871d534ed0461ae6663318e29270c
|
|
@@ -292,6 +292,9 @@ class << RSpec::OpenAPI::SchemaBuilder
|
|
|
292
292
|
|
|
293
293
|
# Convert an always-String param to an appropriate type
|
|
294
294
|
def try_cast(value)
|
|
295
|
+
return true if value == 'true'
|
|
296
|
+
return false if value == 'false'
|
|
297
|
+
|
|
295
298
|
Integer(value)
|
|
296
299
|
rescue TypeError, ArgumentError
|
|
297
300
|
value
|
|
@@ -101,9 +101,10 @@ class << RSpec::OpenAPI::SchemaCleaner = Object.new
|
|
|
101
101
|
end
|
|
102
102
|
|
|
103
103
|
def remove_parameters_conflicting_with_security_scheme!(path_definition, security_scheme, security_scheme_name)
|
|
104
|
-
|
|
104
|
+
security = path_definition[:security]
|
|
105
|
+
return if !security || security.empty?
|
|
105
106
|
return unless path_definition[:parameters]
|
|
106
|
-
return unless
|
|
107
|
+
return unless security[0].keys.include?(security_scheme_name)
|
|
107
108
|
|
|
108
109
|
path_definition[:parameters].reject! do |parameter|
|
|
109
110
|
parameter[:in] == security_scheme[:in] && # same location (ie. header)
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: rspec-openapi
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.30.
|
|
4
|
+
version: 0.30.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Takashi Kokubun
|
|
@@ -97,7 +97,7 @@ licenses:
|
|
|
97
97
|
metadata:
|
|
98
98
|
homepage_uri: https://github.com/exoego/rspec-openapi
|
|
99
99
|
source_code_uri: https://github.com/exoego/rspec-openapi
|
|
100
|
-
changelog_uri: https://github.com/exoego/rspec-openapi/releases/tag/v0.30.
|
|
100
|
+
changelog_uri: https://github.com/exoego/rspec-openapi/releases/tag/v0.30.1
|
|
101
101
|
rubygems_mfa_required: 'true'
|
|
102
102
|
rdoc_options: []
|
|
103
103
|
require_paths:
|