openapi_contracts 0.12.0 → 0.13.0
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2e3c770fbbdd4c6d8a18f69f9deaf65959ce70088232ad8291a5aa10bf4b6f0e
|
4
|
+
data.tar.gz: 2248125b3e18a71d403f72b25eae01c2173628f0c58deaf7e004d501cb7f9b16
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 64d09afded34921b66bd12573998906882681cf68e62c277abb1f569afa3da93e856240877e9edffa1768c14d7a9766de0a9be57bf9f40a0b443c366187f8813
|
7
|
+
data.tar.gz: 3b93196eaaf631d853d693a6082b19399b2db334190cd0bc7d8d27d80ddf67260556249f284c515fb6c0bf207d9d6599a916a2bfbccdbb4c40d6637ae08004fd
|
@@ -25,7 +25,9 @@ module OpenapiContracts::Parser::Transformers
|
|
25
25
|
# A JSON Pointer
|
26
26
|
generate_absolute_pointer(pointer)
|
27
27
|
elsif %r{^(?<relpath>[^#]+)(?:#/(?<pointer>.*))?} =~ target
|
28
|
-
ptr = @parser.filenesting[@cwd.join(relpath)]
|
28
|
+
ptr = @parser.filenesting[@cwd.join(relpath).cleanpath]
|
29
|
+
raise "Unknown file: #{@cwd.join(relpath).cleanpath.inspect}" unless ptr
|
30
|
+
|
29
31
|
tgt = ptr.to_json_pointer
|
30
32
|
tgt += "/#{pointer}" if pointer
|
31
33
|
tgt
|
@@ -34,14 +34,14 @@ module OpenapiContracts
|
|
34
34
|
def build_file_list
|
35
35
|
list = {@rootfile.relative_path_from(@cwd) => Doc::Pointer[]}
|
36
36
|
Dir[File.expand_path('components/**/*.yaml', @cwd)].each do |file|
|
37
|
-
pathname = Pathname(file).relative_path_from(@cwd)
|
37
|
+
pathname = Pathname(file).relative_path_from(@cwd).cleanpath
|
38
38
|
pointer = Doc::Pointer.from_path pathname.sub_ext('')
|
39
39
|
list.merge! pathname => pointer
|
40
40
|
end
|
41
41
|
YAML.safe_load_file(@rootfile).fetch('paths') { {} }.each_pair do |k, v|
|
42
42
|
next unless v['$ref'] && !v['$ref'].start_with?('#')
|
43
43
|
|
44
|
-
list.merge! Pathname(v['$ref']) => Doc::Pointer['paths', k]
|
44
|
+
list.merge! Pathname(v['$ref']).cleanpath => Doc::Pointer['paths', k]
|
45
45
|
end
|
46
46
|
list
|
47
47
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: openapi_contracts
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.13.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- mkon
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-01-
|
11
|
+
date: 2024-01-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -98,14 +98,14 @@ dependencies:
|
|
98
98
|
requirements:
|
99
99
|
- - '='
|
100
100
|
- !ruby/object:Gem::Version
|
101
|
-
version: 1.
|
101
|
+
version: 1.59.0
|
102
102
|
type: :development
|
103
103
|
prerelease: false
|
104
104
|
version_requirements: !ruby/object:Gem::Requirement
|
105
105
|
requirements:
|
106
106
|
- - '='
|
107
107
|
- !ruby/object:Gem::Version
|
108
|
-
version: 1.
|
108
|
+
version: 1.59.0
|
109
109
|
- !ruby/object:Gem::Dependency
|
110
110
|
name: rubocop-rspec
|
111
111
|
requirement: !ruby/object:Gem::Requirement
|