json-schema 2.8.0 → 5.1.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (70) hide show
  1. checksums.yaml +5 -5
  2. data/README.md +82 -11
  3. data/lib/json-schema/attribute.rb +13 -14
  4. data/lib/json-schema/attributes/additionalitems.rb +1 -0
  5. data/lib/json-schema/attributes/additionalproperties.rb +3 -6
  6. data/lib/json-schema/attributes/allof.rb +6 -4
  7. data/lib/json-schema/attributes/anyof.rb +2 -2
  8. data/lib/json-schema/attributes/const.rb +15 -0
  9. data/lib/json-schema/attributes/dependencies.rb +1 -6
  10. data/lib/json-schema/attributes/dependencies_v4.rb +11 -0
  11. data/lib/json-schema/attributes/disallow.rb +2 -1
  12. data/lib/json-schema/attributes/divisibleby.rb +1 -1
  13. data/lib/json-schema/attributes/enum.rb +2 -2
  14. data/lib/json-schema/attributes/extends.rb +7 -7
  15. data/lib/json-schema/attributes/format.rb +2 -1
  16. data/lib/json-schema/attributes/formats/custom.rb +1 -1
  17. data/lib/json-schema/attributes/formats/date.rb +2 -1
  18. data/lib/json-schema/attributes/formats/date_time.rb +3 -2
  19. data/lib/json-schema/attributes/formats/date_time_v4.rb +2 -1
  20. data/lib/json-schema/attributes/formats/ip.rb +1 -1
  21. data/lib/json-schema/attributes/formats/time.rb +1 -1
  22. data/lib/json-schema/attributes/formats/uri.rb +2 -1
  23. data/lib/json-schema/attributes/items.rb +1 -0
  24. data/lib/json-schema/attributes/limit.rb +0 -127
  25. data/lib/json-schema/attributes/limits/items.rb +15 -0
  26. data/lib/json-schema/attributes/limits/length.rb +15 -0
  27. data/lib/json-schema/attributes/limits/max_items.rb +15 -0
  28. data/lib/json-schema/attributes/limits/max_length.rb +15 -0
  29. data/lib/json-schema/attributes/limits/max_properties.rb +15 -0
  30. data/lib/json-schema/attributes/limits/maximum.rb +15 -0
  31. data/lib/json-schema/attributes/limits/maximum_inclusive.rb +11 -0
  32. data/lib/json-schema/attributes/limits/min_items.rb +15 -0
  33. data/lib/json-schema/attributes/limits/min_length.rb +15 -0
  34. data/lib/json-schema/attributes/limits/min_properties.rb +15 -0
  35. data/lib/json-schema/attributes/limits/minimum.rb +15 -0
  36. data/lib/json-schema/attributes/limits/minimum_inclusive.rb +11 -0
  37. data/lib/json-schema/attributes/limits/numeric.rb +16 -0
  38. data/lib/json-schema/attributes/limits/properties.rb +15 -0
  39. data/lib/json-schema/attributes/maxdecimal.rb +1 -1
  40. data/lib/json-schema/attributes/not.rb +2 -2
  41. data/lib/json-schema/attributes/oneof.rb +2 -4
  42. data/lib/json-schema/attributes/patternproperties.rb +2 -1
  43. data/lib/json-schema/attributes/properties.rb +9 -17
  44. data/lib/json-schema/attributes/properties_v4.rb +13 -0
  45. data/lib/json-schema/attributes/propertynames.rb +23 -0
  46. data/lib/json-schema/attributes/ref.rb +8 -8
  47. data/lib/json-schema/attributes/required.rb +4 -3
  48. data/lib/json-schema/attributes/type.rb +3 -2
  49. data/lib/json-schema/attributes/type_v4.rb +1 -1
  50. data/lib/json-schema/errors/validation_error.rb +5 -6
  51. data/lib/json-schema/schema/reader.rb +3 -1
  52. data/lib/json-schema/schema/validator.rb +3 -3
  53. data/lib/json-schema/schema.rb +3 -4
  54. data/lib/json-schema/util/array_set.rb +1 -1
  55. data/lib/json-schema/util/uri.rb +98 -75
  56. data/lib/json-schema/util/uuid.rb +203 -226
  57. data/lib/json-schema/validator.rb +122 -115
  58. data/lib/json-schema/validators/draft1.rb +21 -23
  59. data/lib/json-schema/validators/draft2.rb +22 -24
  60. data/lib/json-schema/validators/draft3.rb +26 -28
  61. data/lib/json-schema/validators/draft4.rb +34 -36
  62. data/lib/json-schema/validators/draft6.rb +36 -36
  63. data/lib/json-schema/validators/hyper-draft1.rb +2 -3
  64. data/lib/json-schema/validators/hyper-draft2.rb +2 -3
  65. data/lib/json-schema/validators/hyper-draft3.rb +2 -3
  66. data/lib/json-schema/validators/hyper-draft4.rb +2 -3
  67. data/lib/json-schema/validators/hyper-draft6.rb +2 -3
  68. data/lib/json-schema.rb +2 -3
  69. data/resources/draft-06.json +41 -41
  70. metadata +67 -31
metadata CHANGED
@@ -1,87 +1,102 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: json-schema
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.8.0
4
+ version: 5.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kenny Hoxworth
8
+ - Vox Pupuli
8
9
  autorequire:
9
10
  bindir: bin
10
11
  cert_chain: []
11
- date: 2017-02-07 00:00:00.000000000 Z
12
+ date: 2024-12-02 00:00:00.000000000 Z
12
13
  dependencies:
13
14
  - !ruby/object:Gem::Dependency
14
- name: rake
15
+ name: minitest
15
16
  requirement: !ruby/object:Gem::Requirement
16
17
  requirements:
17
- - - ">="
18
+ - - "~>"
18
19
  - !ruby/object:Gem::Version
19
- version: '0'
20
+ version: '5.0'
20
21
  type: :development
21
22
  prerelease: false
22
23
  version_requirements: !ruby/object:Gem::Requirement
23
24
  requirements:
24
- - - ">="
25
+ - - "~>"
25
26
  - !ruby/object:Gem::Version
26
- version: '0'
27
+ version: '5.0'
27
28
  - !ruby/object:Gem::Dependency
28
- name: minitest
29
+ name: rake
29
30
  requirement: !ruby/object:Gem::Requirement
30
31
  requirements:
31
32
  - - "~>"
32
33
  - !ruby/object:Gem::Version
33
- version: '5.0'
34
+ version: '13.0'
34
35
  type: :development
35
36
  prerelease: false
36
37
  version_requirements: !ruby/object:Gem::Requirement
37
38
  requirements:
38
39
  - - "~>"
39
40
  - !ruby/object:Gem::Version
40
- version: '5.0'
41
+ version: '13.0'
41
42
  - !ruby/object:Gem::Dependency
42
- name: webmock
43
+ name: voxpupuli-rubocop
43
44
  requirement: !ruby/object:Gem::Requirement
44
45
  requirements:
45
- - - ">="
46
+ - - "~>"
46
47
  - !ruby/object:Gem::Version
47
- version: '0'
48
+ version: 3.0.0
48
49
  type: :development
49
50
  prerelease: false
50
51
  version_requirements: !ruby/object:Gem::Requirement
51
52
  requirements:
52
- - - ">="
53
+ - - "~>"
53
54
  - !ruby/object:Gem::Version
54
- version: '0'
55
+ version: 3.0.0
55
56
  - !ruby/object:Gem::Dependency
56
- name: bundler
57
+ name: webmock
57
58
  requirement: !ruby/object:Gem::Requirement
58
59
  requirements:
59
- - - ">="
60
+ - - "~>"
60
61
  - !ruby/object:Gem::Version
61
- version: '0'
62
+ version: '3.23'
62
63
  type: :development
63
64
  prerelease: false
64
65
  version_requirements: !ruby/object:Gem::Requirement
65
66
  requirements:
66
- - - ">="
67
+ - - "~>"
67
68
  - !ruby/object:Gem::Version
68
- version: '0'
69
+ version: '3.23'
69
70
  - !ruby/object:Gem::Dependency
70
71
  name: addressable
71
72
  requirement: !ruby/object:Gem::Requirement
72
73
  requirements:
73
- - - ">="
74
+ - - "~>"
75
+ - !ruby/object:Gem::Version
76
+ version: '2.8'
77
+ type: :runtime
78
+ prerelease: false
79
+ version_requirements: !ruby/object:Gem::Requirement
80
+ requirements:
81
+ - - "~>"
82
+ - !ruby/object:Gem::Version
83
+ version: '2.8'
84
+ - !ruby/object:Gem::Dependency
85
+ name: bigdecimal
86
+ requirement: !ruby/object:Gem::Requirement
87
+ requirements:
88
+ - - "~>"
74
89
  - !ruby/object:Gem::Version
75
- version: '2.4'
90
+ version: '3.1'
76
91
  type: :runtime
77
92
  prerelease: false
78
93
  version_requirements: !ruby/object:Gem::Requirement
79
94
  requirements:
80
- - - ">="
95
+ - - "~>"
81
96
  - !ruby/object:Gem::Version
82
- version: '2.4'
97
+ version: '3.1'
83
98
  description:
84
- email: hoxworth@gmail.com
99
+ email: voxpupuli@groups.io
85
100
  executables: []
86
101
  extensions: []
87
102
  extra_rdoc_files:
@@ -96,7 +111,9 @@ files:
96
111
  - lib/json-schema/attributes/additionalproperties.rb
97
112
  - lib/json-schema/attributes/allof.rb
98
113
  - lib/json-schema/attributes/anyof.rb
114
+ - lib/json-schema/attributes/const.rb
99
115
  - lib/json-schema/attributes/dependencies.rb
116
+ - lib/json-schema/attributes/dependencies_v4.rb
100
117
  - lib/json-schema/attributes/disallow.rb
101
118
  - lib/json-schema/attributes/divisibleby.rb
102
119
  - lib/json-schema/attributes/enum.rb
@@ -111,6 +128,20 @@ files:
111
128
  - lib/json-schema/attributes/formats/uri.rb
112
129
  - lib/json-schema/attributes/items.rb
113
130
  - lib/json-schema/attributes/limit.rb
131
+ - lib/json-schema/attributes/limits/items.rb
132
+ - lib/json-schema/attributes/limits/length.rb
133
+ - lib/json-schema/attributes/limits/max_items.rb
134
+ - lib/json-schema/attributes/limits/max_length.rb
135
+ - lib/json-schema/attributes/limits/max_properties.rb
136
+ - lib/json-schema/attributes/limits/maximum.rb
137
+ - lib/json-schema/attributes/limits/maximum_inclusive.rb
138
+ - lib/json-schema/attributes/limits/min_items.rb
139
+ - lib/json-schema/attributes/limits/min_length.rb
140
+ - lib/json-schema/attributes/limits/min_properties.rb
141
+ - lib/json-schema/attributes/limits/minimum.rb
142
+ - lib/json-schema/attributes/limits/minimum_inclusive.rb
143
+ - lib/json-schema/attributes/limits/numeric.rb
144
+ - lib/json-schema/attributes/limits/properties.rb
114
145
  - lib/json-schema/attributes/maxdecimal.rb
115
146
  - lib/json-schema/attributes/multipleof.rb
116
147
  - lib/json-schema/attributes/not.rb
@@ -119,6 +150,8 @@ files:
119
150
  - lib/json-schema/attributes/patternproperties.rb
120
151
  - lib/json-schema/attributes/properties.rb
121
152
  - lib/json-schema/attributes/properties_optional.rb
153
+ - lib/json-schema/attributes/properties_v4.rb
154
+ - lib/json-schema/attributes/propertynames.rb
122
155
  - lib/json-schema/attributes/ref.rb
123
156
  - lib/json-schema/attributes/required.rb
124
157
  - lib/json-schema/attributes/type.rb
@@ -153,10 +186,14 @@ files:
153
186
  - resources/draft-03.json
154
187
  - resources/draft-04.json
155
188
  - resources/draft-06.json
156
- homepage: http://github.com/ruby-json-schema/json-schema/tree/master
189
+ homepage: https://github.com/voxpupuli/json-schema/
157
190
  licenses:
158
191
  - MIT
159
- metadata: {}
192
+ metadata:
193
+ source_code_uri: https://github.com/voxpupuli/json-schema/
194
+ changelog_uri: https://github.com/voxpupuli/json-schema//blob/master/CHANGELOG.md
195
+ bug_tracker_uri: https://github.com/voxpupuli/json-schema//issues
196
+ funding_uri: https://github.com/sponsors/voxpupuli
160
197
  post_install_message:
161
198
  rdoc_options: []
162
199
  require_paths:
@@ -165,15 +202,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
165
202
  requirements:
166
203
  - - ">="
167
204
  - !ruby/object:Gem::Version
168
- version: '1.9'
205
+ version: '2.7'
169
206
  required_rubygems_version: !ruby/object:Gem::Requirement
170
207
  requirements:
171
208
  - - ">="
172
209
  - !ruby/object:Gem::Version
173
- version: '1.8'
210
+ version: '0'
174
211
  requirements: []
175
- rubyforge_project:
176
- rubygems_version: 2.6.8
212
+ rubygems_version: 3.5.22
177
213
  signing_key:
178
214
  specification_version: 4
179
215
  summary: Ruby JSON Schema Validator