json_schemer 0.2.7 → 0.2.12

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.
Files changed (233) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/ci.yml +1 -6
  3. data/Gemfile.lock +7 -7
  4. data/json_schemer.gemspec +3 -3
  5. data/lib/json_schemer.rb +2 -0
  6. data/lib/json_schemer/errors.rb +31 -0
  7. data/lib/json_schemer/format.rb +25 -58
  8. data/lib/json_schemer/schema/base.rb +52 -32
  9. data/lib/json_schemer/version.rb +1 -1
  10. metadata +8 -229
  11. data/JSON-Schema-Test-Suite/.gitignore +0 -1
  12. data/JSON-Schema-Test-Suite/.travis.yml +0 -8
  13. data/JSON-Schema-Test-Suite/LICENSE +0 -19
  14. data/JSON-Schema-Test-Suite/README.md +0 -181
  15. data/JSON-Schema-Test-Suite/bin/jsonschema_suite +0 -295
  16. data/JSON-Schema-Test-Suite/index.js +0 -45
  17. data/JSON-Schema-Test-Suite/package.json +0 -28
  18. data/JSON-Schema-Test-Suite/remotes/folder/folderInteger.json +0 -3
  19. data/JSON-Schema-Test-Suite/remotes/integer.json +0 -3
  20. data/JSON-Schema-Test-Suite/remotes/name-defs.json +0 -11
  21. data/JSON-Schema-Test-Suite/remotes/name.json +0 -11
  22. data/JSON-Schema-Test-Suite/remotes/subSchemas.json +0 -8
  23. data/JSON-Schema-Test-Suite/test-schema.json +0 -59
  24. data/JSON-Schema-Test-Suite/tests/draft2019-08/additionalItems.json +0 -87
  25. data/JSON-Schema-Test-Suite/tests/draft2019-08/additionalProperties.json +0 -133
  26. data/JSON-Schema-Test-Suite/tests/draft2019-08/allOf.json +0 -218
  27. data/JSON-Schema-Test-Suite/tests/draft2019-08/anyOf.json +0 -189
  28. data/JSON-Schema-Test-Suite/tests/draft2019-08/boolean_schema.json +0 -104
  29. data/JSON-Schema-Test-Suite/tests/draft2019-08/const.json +0 -170
  30. data/JSON-Schema-Test-Suite/tests/draft2019-08/contains.json +0 -95
  31. data/JSON-Schema-Test-Suite/tests/draft2019-08/default.json +0 -49
  32. data/JSON-Schema-Test-Suite/tests/draft2019-08/defs.json +0 -24
  33. data/JSON-Schema-Test-Suite/tests/draft2019-08/dependencies.json +0 -268
  34. data/JSON-Schema-Test-Suite/tests/draft2019-08/enum.json +0 -179
  35. data/JSON-Schema-Test-Suite/tests/draft2019-08/exclusiveMaximum.json +0 -30
  36. data/JSON-Schema-Test-Suite/tests/draft2019-08/exclusiveMinimum.json +0 -30
  37. data/JSON-Schema-Test-Suite/tests/draft2019-08/if-then-else.json +0 -188
  38. data/JSON-Schema-Test-Suite/tests/draft2019-08/items.json +0 -250
  39. data/JSON-Schema-Test-Suite/tests/draft2019-08/maxItems.json +0 -28
  40. data/JSON-Schema-Test-Suite/tests/draft2019-08/maxLength.json +0 -33
  41. data/JSON-Schema-Test-Suite/tests/draft2019-08/maxProperties.json +0 -38
  42. data/JSON-Schema-Test-Suite/tests/draft2019-08/maximum.json +0 -28
  43. data/JSON-Schema-Test-Suite/tests/draft2019-08/minItems.json +0 -28
  44. data/JSON-Schema-Test-Suite/tests/draft2019-08/minLength.json +0 -33
  45. data/JSON-Schema-Test-Suite/tests/draft2019-08/minProperties.json +0 -38
  46. data/JSON-Schema-Test-Suite/tests/draft2019-08/minimum.json +0 -59
  47. data/JSON-Schema-Test-Suite/tests/draft2019-08/multipleOf.json +0 -60
  48. data/JSON-Schema-Test-Suite/tests/draft2019-08/not.json +0 -117
  49. data/JSON-Schema-Test-Suite/tests/draft2019-08/oneOf.json +0 -206
  50. data/JSON-Schema-Test-Suite/tests/draft2019-08/optional/bignum.json +0 -105
  51. data/JSON-Schema-Test-Suite/tests/draft2019-08/optional/content.json +0 -77
  52. data/JSON-Schema-Test-Suite/tests/draft2019-08/optional/ecmascript-regex.json +0 -13
  53. data/JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/date-time.json +0 -53
  54. data/JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/date.json +0 -23
  55. data/JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/email.json +0 -18
  56. data/JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/hostname.json +0 -33
  57. data/JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/idn-email.json +0 -18
  58. data/JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/idn-hostname.json +0 -28
  59. data/JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/ipv4.json +0 -33
  60. data/JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/ipv6.json +0 -28
  61. data/JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/iri-reference.json +0 -43
  62. data/JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/iri.json +0 -53
  63. data/JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/json-pointer.json +0 -168
  64. data/JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/regex.json +0 -18
  65. data/JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/relative-json-pointer.json +0 -33
  66. data/JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/time.json +0 -23
  67. data/JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/uri-reference.json +0 -43
  68. data/JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/uri-template.json +0 -28
  69. data/JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/uri.json +0 -103
  70. data/JSON-Schema-Test-Suite/tests/draft2019-08/optional/zeroTerminatedFloats.json +0 -15
  71. data/JSON-Schema-Test-Suite/tests/draft2019-08/pattern.json +0 -34
  72. data/JSON-Schema-Test-Suite/tests/draft2019-08/patternProperties.json +0 -151
  73. data/JSON-Schema-Test-Suite/tests/draft2019-08/properties.json +0 -167
  74. data/JSON-Schema-Test-Suite/tests/draft2019-08/propertyNames.json +0 -78
  75. data/JSON-Schema-Test-Suite/tests/draft2019-08/ref.json +0 -443
  76. data/JSON-Schema-Test-Suite/tests/draft2019-08/refRemote.json +0 -167
  77. data/JSON-Schema-Test-Suite/tests/draft2019-08/required.json +0 -105
  78. data/JSON-Schema-Test-Suite/tests/draft2019-08/type.json +0 -464
  79. data/JSON-Schema-Test-Suite/tests/draft2019-08/uniqueItems.json +0 -89
  80. data/JSON-Schema-Test-Suite/tests/draft3/additionalItems.json +0 -82
  81. data/JSON-Schema-Test-Suite/tests/draft3/additionalProperties.json +0 -133
  82. data/JSON-Schema-Test-Suite/tests/draft3/default.json +0 -49
  83. data/JSON-Schema-Test-Suite/tests/draft3/dependencies.json +0 -118
  84. data/JSON-Schema-Test-Suite/tests/draft3/disallow.json +0 -80
  85. data/JSON-Schema-Test-Suite/tests/draft3/divisibleBy.json +0 -60
  86. data/JSON-Schema-Test-Suite/tests/draft3/enum.json +0 -71
  87. data/JSON-Schema-Test-Suite/tests/draft3/extends.json +0 -94
  88. data/JSON-Schema-Test-Suite/tests/draft3/items.json +0 -46
  89. data/JSON-Schema-Test-Suite/tests/draft3/maxItems.json +0 -28
  90. data/JSON-Schema-Test-Suite/tests/draft3/maxLength.json +0 -33
  91. data/JSON-Schema-Test-Suite/tests/draft3/maximum.json +0 -42
  92. data/JSON-Schema-Test-Suite/tests/draft3/minItems.json +0 -28
  93. data/JSON-Schema-Test-Suite/tests/draft3/minLength.json +0 -33
  94. data/JSON-Schema-Test-Suite/tests/draft3/minimum.json +0 -73
  95. data/JSON-Schema-Test-Suite/tests/draft3/optional/bignum.json +0 -107
  96. data/JSON-Schema-Test-Suite/tests/draft3/optional/format.json +0 -227
  97. data/JSON-Schema-Test-Suite/tests/draft3/optional/jsregex.json +0 -18
  98. data/JSON-Schema-Test-Suite/tests/draft3/optional/zeroTerminatedFloats.json +0 -15
  99. data/JSON-Schema-Test-Suite/tests/draft3/pattern.json +0 -34
  100. data/JSON-Schema-Test-Suite/tests/draft3/patternProperties.json +0 -115
  101. data/JSON-Schema-Test-Suite/tests/draft3/properties.json +0 -97
  102. data/JSON-Schema-Test-Suite/tests/draft3/ref.json +0 -192
  103. data/JSON-Schema-Test-Suite/tests/draft3/refRemote.json +0 -74
  104. data/JSON-Schema-Test-Suite/tests/draft3/required.json +0 -53
  105. data/JSON-Schema-Test-Suite/tests/draft3/type.json +0 -489
  106. data/JSON-Schema-Test-Suite/tests/draft3/uniqueItems.json +0 -79
  107. data/JSON-Schema-Test-Suite/tests/draft4/additionalItems.json +0 -87
  108. data/JSON-Schema-Test-Suite/tests/draft4/additionalProperties.json +0 -133
  109. data/JSON-Schema-Test-Suite/tests/draft4/allOf.json +0 -185
  110. data/JSON-Schema-Test-Suite/tests/draft4/anyOf.json +0 -156
  111. data/JSON-Schema-Test-Suite/tests/draft4/default.json +0 -49
  112. data/JSON-Schema-Test-Suite/tests/draft4/definitions.json +0 -32
  113. data/JSON-Schema-Test-Suite/tests/draft4/dependencies.json +0 -194
  114. data/JSON-Schema-Test-Suite/tests/draft4/enum.json +0 -179
  115. data/JSON-Schema-Test-Suite/tests/draft4/items.json +0 -195
  116. data/JSON-Schema-Test-Suite/tests/draft4/maxItems.json +0 -28
  117. data/JSON-Schema-Test-Suite/tests/draft4/maxLength.json +0 -33
  118. data/JSON-Schema-Test-Suite/tests/draft4/maxProperties.json +0 -38
  119. data/JSON-Schema-Test-Suite/tests/draft4/maximum.json +0 -73
  120. data/JSON-Schema-Test-Suite/tests/draft4/minItems.json +0 -28
  121. data/JSON-Schema-Test-Suite/tests/draft4/minLength.json +0 -33
  122. data/JSON-Schema-Test-Suite/tests/draft4/minProperties.json +0 -38
  123. data/JSON-Schema-Test-Suite/tests/draft4/minimum.json +0 -104
  124. data/JSON-Schema-Test-Suite/tests/draft4/multipleOf.json +0 -60
  125. data/JSON-Schema-Test-Suite/tests/draft4/not.json +0 -96
  126. data/JSON-Schema-Test-Suite/tests/draft4/oneOf.json +0 -162
  127. data/JSON-Schema-Test-Suite/tests/draft4/optional/bignum.json +0 -107
  128. data/JSON-Schema-Test-Suite/tests/draft4/optional/ecmascript-regex.json +0 -13
  129. data/JSON-Schema-Test-Suite/tests/draft4/optional/format.json +0 -253
  130. data/JSON-Schema-Test-Suite/tests/draft4/optional/zeroTerminatedFloats.json +0 -15
  131. data/JSON-Schema-Test-Suite/tests/draft4/pattern.json +0 -34
  132. data/JSON-Schema-Test-Suite/tests/draft4/patternProperties.json +0 -120
  133. data/JSON-Schema-Test-Suite/tests/draft4/properties.json +0 -136
  134. data/JSON-Schema-Test-Suite/tests/draft4/ref.json +0 -411
  135. data/JSON-Schema-Test-Suite/tests/draft4/refRemote.json +0 -171
  136. data/JSON-Schema-Test-Suite/tests/draft4/required.json +0 -89
  137. data/JSON-Schema-Test-Suite/tests/draft4/type.json +0 -464
  138. data/JSON-Schema-Test-Suite/tests/draft4/uniqueItems.json +0 -89
  139. data/JSON-Schema-Test-Suite/tests/draft6/additionalItems.json +0 -87
  140. data/JSON-Schema-Test-Suite/tests/draft6/additionalProperties.json +0 -133
  141. data/JSON-Schema-Test-Suite/tests/draft6/allOf.json +0 -218
  142. data/JSON-Schema-Test-Suite/tests/draft6/anyOf.json +0 -189
  143. data/JSON-Schema-Test-Suite/tests/draft6/boolean_schema.json +0 -104
  144. data/JSON-Schema-Test-Suite/tests/draft6/const.json +0 -170
  145. data/JSON-Schema-Test-Suite/tests/draft6/contains.json +0 -100
  146. data/JSON-Schema-Test-Suite/tests/draft6/default.json +0 -49
  147. data/JSON-Schema-Test-Suite/tests/draft6/definitions.json +0 -32
  148. data/JSON-Schema-Test-Suite/tests/draft6/dependencies.json +0 -268
  149. data/JSON-Schema-Test-Suite/tests/draft6/enum.json +0 -179
  150. data/JSON-Schema-Test-Suite/tests/draft6/exclusiveMaximum.json +0 -30
  151. data/JSON-Schema-Test-Suite/tests/draft6/exclusiveMinimum.json +0 -30
  152. data/JSON-Schema-Test-Suite/tests/draft6/items.json +0 -250
  153. data/JSON-Schema-Test-Suite/tests/draft6/maxItems.json +0 -28
  154. data/JSON-Schema-Test-Suite/tests/draft6/maxLength.json +0 -33
  155. data/JSON-Schema-Test-Suite/tests/draft6/maxProperties.json +0 -38
  156. data/JSON-Schema-Test-Suite/tests/draft6/maximum.json +0 -28
  157. data/JSON-Schema-Test-Suite/tests/draft6/minItems.json +0 -28
  158. data/JSON-Schema-Test-Suite/tests/draft6/minLength.json +0 -33
  159. data/JSON-Schema-Test-Suite/tests/draft6/minProperties.json +0 -38
  160. data/JSON-Schema-Test-Suite/tests/draft6/minimum.json +0 -59
  161. data/JSON-Schema-Test-Suite/tests/draft6/multipleOf.json +0 -60
  162. data/JSON-Schema-Test-Suite/tests/draft6/not.json +0 -117
  163. data/JSON-Schema-Test-Suite/tests/draft6/oneOf.json +0 -206
  164. data/JSON-Schema-Test-Suite/tests/draft6/optional/bignum.json +0 -105
  165. data/JSON-Schema-Test-Suite/tests/draft6/optional/ecmascript-regex.json +0 -13
  166. data/JSON-Schema-Test-Suite/tests/draft6/optional/format.json +0 -491
  167. data/JSON-Schema-Test-Suite/tests/draft6/optional/zeroTerminatedFloats.json +0 -15
  168. data/JSON-Schema-Test-Suite/tests/draft6/pattern.json +0 -34
  169. data/JSON-Schema-Test-Suite/tests/draft6/patternProperties.json +0 -151
  170. data/JSON-Schema-Test-Suite/tests/draft6/properties.json +0 -167
  171. data/JSON-Schema-Test-Suite/tests/draft6/propertyNames.json +0 -78
  172. data/JSON-Schema-Test-Suite/tests/draft6/ref.json +0 -443
  173. data/JSON-Schema-Test-Suite/tests/draft6/refRemote.json +0 -171
  174. data/JSON-Schema-Test-Suite/tests/draft6/required.json +0 -105
  175. data/JSON-Schema-Test-Suite/tests/draft6/type.json +0 -464
  176. data/JSON-Schema-Test-Suite/tests/draft6/uniqueItems.json +0 -89
  177. data/JSON-Schema-Test-Suite/tests/draft7/additionalItems.json +0 -87
  178. data/JSON-Schema-Test-Suite/tests/draft7/additionalProperties.json +0 -133
  179. data/JSON-Schema-Test-Suite/tests/draft7/allOf.json +0 -218
  180. data/JSON-Schema-Test-Suite/tests/draft7/anyOf.json +0 -189
  181. data/JSON-Schema-Test-Suite/tests/draft7/boolean_schema.json +0 -104
  182. data/JSON-Schema-Test-Suite/tests/draft7/const.json +0 -170
  183. data/JSON-Schema-Test-Suite/tests/draft7/contains.json +0 -100
  184. data/JSON-Schema-Test-Suite/tests/draft7/default.json +0 -49
  185. data/JSON-Schema-Test-Suite/tests/draft7/definitions.json +0 -32
  186. data/JSON-Schema-Test-Suite/tests/draft7/dependencies.json +0 -268
  187. data/JSON-Schema-Test-Suite/tests/draft7/enum.json +0 -179
  188. data/JSON-Schema-Test-Suite/tests/draft7/exclusiveMaximum.json +0 -30
  189. data/JSON-Schema-Test-Suite/tests/draft7/exclusiveMinimum.json +0 -30
  190. data/JSON-Schema-Test-Suite/tests/draft7/if-then-else.json +0 -188
  191. data/JSON-Schema-Test-Suite/tests/draft7/items.json +0 -250
  192. data/JSON-Schema-Test-Suite/tests/draft7/maxItems.json +0 -28
  193. data/JSON-Schema-Test-Suite/tests/draft7/maxLength.json +0 -33
  194. data/JSON-Schema-Test-Suite/tests/draft7/maxProperties.json +0 -38
  195. data/JSON-Schema-Test-Suite/tests/draft7/maximum.json +0 -28
  196. data/JSON-Schema-Test-Suite/tests/draft7/minItems.json +0 -28
  197. data/JSON-Schema-Test-Suite/tests/draft7/minLength.json +0 -33
  198. data/JSON-Schema-Test-Suite/tests/draft7/minProperties.json +0 -38
  199. data/JSON-Schema-Test-Suite/tests/draft7/minimum.json +0 -59
  200. data/JSON-Schema-Test-Suite/tests/draft7/multipleOf.json +0 -60
  201. data/JSON-Schema-Test-Suite/tests/draft7/not.json +0 -117
  202. data/JSON-Schema-Test-Suite/tests/draft7/oneOf.json +0 -206
  203. data/JSON-Schema-Test-Suite/tests/draft7/optional/bignum.json +0 -105
  204. data/JSON-Schema-Test-Suite/tests/draft7/optional/content.json +0 -77
  205. data/JSON-Schema-Test-Suite/tests/draft7/optional/ecmascript-regex.json +0 -13
  206. data/JSON-Schema-Test-Suite/tests/draft7/optional/format/date-time.json +0 -53
  207. data/JSON-Schema-Test-Suite/tests/draft7/optional/format/date.json +0 -23
  208. data/JSON-Schema-Test-Suite/tests/draft7/optional/format/email.json +0 -18
  209. data/JSON-Schema-Test-Suite/tests/draft7/optional/format/hostname.json +0 -33
  210. data/JSON-Schema-Test-Suite/tests/draft7/optional/format/idn-email.json +0 -18
  211. data/JSON-Schema-Test-Suite/tests/draft7/optional/format/idn-hostname.json +0 -28
  212. data/JSON-Schema-Test-Suite/tests/draft7/optional/format/ipv4.json +0 -33
  213. data/JSON-Schema-Test-Suite/tests/draft7/optional/format/ipv6.json +0 -28
  214. data/JSON-Schema-Test-Suite/tests/draft7/optional/format/iri-reference.json +0 -43
  215. data/JSON-Schema-Test-Suite/tests/draft7/optional/format/iri.json +0 -53
  216. data/JSON-Schema-Test-Suite/tests/draft7/optional/format/json-pointer.json +0 -168
  217. data/JSON-Schema-Test-Suite/tests/draft7/optional/format/regex.json +0 -18
  218. data/JSON-Schema-Test-Suite/tests/draft7/optional/format/relative-json-pointer.json +0 -33
  219. data/JSON-Schema-Test-Suite/tests/draft7/optional/format/time.json +0 -23
  220. data/JSON-Schema-Test-Suite/tests/draft7/optional/format/uri-reference.json +0 -43
  221. data/JSON-Schema-Test-Suite/tests/draft7/optional/format/uri-template.json +0 -28
  222. data/JSON-Schema-Test-Suite/tests/draft7/optional/format/uri.json +0 -103
  223. data/JSON-Schema-Test-Suite/tests/draft7/optional/zeroTerminatedFloats.json +0 -15
  224. data/JSON-Schema-Test-Suite/tests/draft7/pattern.json +0 -34
  225. data/JSON-Schema-Test-Suite/tests/draft7/patternProperties.json +0 -151
  226. data/JSON-Schema-Test-Suite/tests/draft7/properties.json +0 -167
  227. data/JSON-Schema-Test-Suite/tests/draft7/propertyNames.json +0 -78
  228. data/JSON-Schema-Test-Suite/tests/draft7/ref.json +0 -443
  229. data/JSON-Schema-Test-Suite/tests/draft7/refRemote.json +0 -171
  230. data/JSON-Schema-Test-Suite/tests/draft7/required.json +0 -105
  231. data/JSON-Schema-Test-Suite/tests/draft7/type.json +0 -464
  232. data/JSON-Schema-Test-Suite/tests/draft7/uniqueItems.json +0 -89
  233. data/JSON-Schema-Test-Suite/tox.ini +0 -8
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: cc49528384df791b69a3ece8516d588f385761f64328d3738f4432e5acb05d99
4
- data.tar.gz: 0a58ef039ec6d5236a0028bb1b4476c38763ea9d44a25f118a3aa3829ad559ef
3
+ metadata.gz: 6d07c36d5981512e6980d79a12084d309b92db45490d3ea821d02713c71fd5fc
4
+ data.tar.gz: 20dad8f563ba3ca0dcb7586641cf804aea2f727ed4def911fb105fd7bb14965f
5
5
  SHA512:
6
- metadata.gz: 689fc86d72801d49e2baae326fd2ff0e2e36a6e3a14379ba9f00ceae74618b4cfb445797b52f0d558ec7ad96c0d02797c6e52eb0938e82fa465eb94128a38b79
7
- data.tar.gz: 68fff4ff624335455bec2d6273a81cbc9d995ffd94aa4e6cb82e5651375b2af9ea1a755e1c7e83aa87c2903f48cfd2006fdb47b6d653fe7cb92bb44e852435df
6
+ metadata.gz: 199c651105b1330a6946d7099d9c9c0d4f74d1922e03cf3855870660f32c81fb6f94d3748555d17cde6fb56b5b2029388099f7bf977f5585df8ec7dd5da726b5
7
+ data.tar.gz: e2acf5a285a724dc1c5c99fe35e081ab30f934554aa2f02c691926d75f3ac681594c015ef9224b7d2f70be98dd8d39404f8e4b0c3c87285f23314b523111d20e
@@ -4,19 +4,14 @@ jobs:
4
4
  ruby:
5
5
  strategy:
6
6
  matrix:
7
- ruby: [2.4.x, 2.5.x, 2.6.x]
7
+ ruby: [2.5.x, 2.6.x, 2.7.x]
8
8
  runs-on: ubuntu-latest
9
9
  steps:
10
10
  - uses: actions/checkout@v1
11
11
  - uses: actions/setup-ruby@v1
12
12
  with:
13
13
  ruby-version: ${{ matrix.ruby }}
14
- - uses: actions/setup-python@v1
15
- with:
16
- python-version: 3.x
17
14
  - run: |
18
- pip install --user Flask
19
- ./JSON-Schema-Test-Suite/bin/jsonschema_suite serve &
20
15
  gem install bundler
21
16
  bundle install
22
17
  bundle exec rake test
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- json_schemer (0.2.7)
4
+ json_schemer (0.2.12)
5
5
  ecma-re-validator (~> 0.2)
6
6
  hana (~> 1.3)
7
7
  regexp_parser (~> 1.5)
@@ -10,12 +10,12 @@ PATH
10
10
  GEM
11
11
  remote: https://rubygems.org/
12
12
  specs:
13
- ecma-re-validator (0.2.0)
13
+ ecma-re-validator (0.2.1)
14
14
  regexp_parser (~> 1.2)
15
- hana (1.3.5)
15
+ hana (1.3.6)
16
16
  minitest (5.11.3)
17
- rake (10.5.0)
18
- regexp_parser (1.6.0)
17
+ rake (13.0.1)
18
+ regexp_parser (1.7.1)
19
19
  uri_template (0.7.0)
20
20
 
21
21
  PLATFORMS
@@ -25,7 +25,7 @@ DEPENDENCIES
25
25
  bundler (~> 2.0)
26
26
  json_schemer!
27
27
  minitest (~> 5.0)
28
- rake (~> 10.0)
28
+ rake (~> 13.0)
29
29
 
30
30
  BUNDLED WITH
31
- 2.0.2
31
+ 2.1.4
@@ -14,16 +14,16 @@ Gem::Specification.new do |spec|
14
14
  spec.license = "MIT"
15
15
 
16
16
  spec.files = `git ls-files -z`.split("\x0").reject do |f|
17
- f.match(%r{^(test|spec|features)/})
17
+ f.match(%r{^(test|spec|features|JSON-Schema-Test-Suite)/})
18
18
  end
19
19
  spec.bindir = "exe"
20
20
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
21
21
  spec.require_paths = ["lib"]
22
22
 
23
- spec.required_ruby_version = '~> 2.4'
23
+ spec.required_ruby_version = '~> 2.5'
24
24
 
25
25
  spec.add_development_dependency "bundler", "~> 2.0"
26
- spec.add_development_dependency "rake", "~> 10.0"
26
+ spec.add_development_dependency "rake", "~> 13.0"
27
27
  spec.add_development_dependency "minitest", "~> 5.0"
28
28
 
29
29
  # spec.add_development_dependency "benchmark-ips", "~> 2.7.2"
@@ -14,6 +14,7 @@ require 'uri_template'
14
14
 
15
15
  require 'json_schemer/version'
16
16
  require 'json_schemer/format'
17
+ require 'json_schemer/errors'
17
18
  require 'json_schemer/cached_ref_resolver'
18
19
  require 'json_schemer/schema/base'
19
20
  require 'json_schemer/schema/draft4'
@@ -28,6 +29,7 @@ module JSONSchemer
28
29
  class InvalidSymbolKey < StandardError; end
29
30
 
30
31
  DRAFT_CLASS_BY_META_SCHEMA = {
32
+ 'http://json-schema.org/schema#' => Schema::Draft4, # Version-less $schema deprecated after Draft 4
31
33
  'http://json-schema.org/draft-04/schema#' => Schema::Draft4,
32
34
  'http://json-schema.org/draft-06/schema#' => Schema::Draft6,
33
35
  'http://json-schema.org/draft-07/schema#' => Schema::Draft7
@@ -0,0 +1,31 @@
1
+ # Based on code from @robacarp found in issue 48:
2
+ # https://github.com/davishmcclurg/json_schemer/issues/48
3
+ #
4
+ module JSONSchemer
5
+ module Errors
6
+ class << self
7
+ def pretty(error)
8
+ data_pointer, type, schema = error.values_at('data_pointer', 'type', 'schema')
9
+ location = data_pointer.empty? ? 'root' : "property '#{data_pointer}'"
10
+
11
+ case type
12
+ when 'required'
13
+ keys = error.fetch('details').fetch('missing_keys').join(', ')
14
+ "#{location} is missing required keys: #{keys}"
15
+ when 'null', 'string', 'boolean', 'integer', 'number', 'array', 'object'
16
+ "#{location} is not of type: #{type}"
17
+ when 'pattern'
18
+ "#{location} does not match pattern: #{schema.fetch('pattern')}"
19
+ when 'format'
20
+ "#{location} does not match format: #{schema.fetch('format')}"
21
+ when 'const'
22
+ "#{location} is not: #{schema.fetch('const').inspect}"
23
+ when 'enum'
24
+ "#{location} is not one of: #{schema.fetch('enum')}"
25
+ else
26
+ "#{location} is invalid: error_type=#{type}"
27
+ end
28
+ end
29
+ end
30
+ end
31
+ end
@@ -9,56 +9,7 @@ module JSONSchemer
9
9
  JSON_POINTER_REGEX = /\A#{JSON_POINTER_REGEX_STRING}\z/.freeze
10
10
  RELATIVE_JSON_POINTER_REGEX = /\A(0|[1-9]\d*)(#|#{JSON_POINTER_REGEX_STRING})?\z/.freeze
11
11
  DATE_TIME_OFFSET_REGEX = /(Z|[\+\-]([01][0-9]|2[0-3]):[0-5][0-9])\z/i.freeze
12
-
13
- # https://github.com/ruby-rdf/rdf
14
-
15
- # IRI components
16
- UCSCHAR = Regexp.compile(<<-EOS.gsub(/\s+/, ''))
17
- [\\u00A0-\\uD7FF]|[\\uF900-\\uFDCF]|[\\uFDF0-\\uFFEF]|
18
- [\\u{10000}-\\u{1FFFD}]|[\\u{20000}-\\u{2FFFD}]|[\\u{30000}-\\u{3FFFD}]|
19
- [\\u{40000}-\\u{4FFFD}]|[\\u{50000}-\\u{5FFFD}]|[\\u{60000}-\\u{6FFFD}]|
20
- [\\u{70000}-\\u{7FFFD}]|[\\u{80000}-\\u{8FFFD}]|[\\u{90000}-\\u{9FFFD}]|
21
- [\\u{A0000}-\\u{AFFFD}]|[\\u{B0000}-\\u{BFFFD}]|[\\u{C0000}-\\u{CFFFD}]|
22
- [\\u{D0000}-\\u{DFFFD}]|[\\u{E1000}-\\u{EFFFD}]
23
- EOS
24
- IPRIVATE = Regexp.compile("[\\uE000-\\uF8FF]|[\\u{F0000}-\\u{FFFFD}]|[\\u100000-\\u10FFFD]").freeze
25
- SCHEME = Regexp.compile("[A-Za-z](?:[A-Za-z0-9+-\.])*").freeze
26
- PORT = Regexp.compile("[0-9]*").freeze
27
- IP_LITERAL = Regexp.compile("\\[[0-9A-Fa-f:\\.]*\\]").freeze # Simplified, no IPvFuture
28
- PCT_ENCODED = Regexp.compile("%[0-9A-Fa-f][0-9A-Fa-f]").freeze
29
- GEN_DELIMS = Regexp.compile("[:/\\?\\#\\[\\]@]").freeze
30
- SUB_DELIMS = Regexp.compile("[!\\$&'\\(\\)\\*\\+,;=]").freeze
31
- RESERVED = Regexp.compile("(?:#{GEN_DELIMS}|#{SUB_DELIMS})").freeze
32
- UNRESERVED = Regexp.compile("[A-Za-z0-9\._~-]").freeze
33
-
34
- IUNRESERVED = Regexp.compile("[A-Za-z0-9\._~-]|#{UCSCHAR}").freeze
35
-
36
- IPCHAR = Regexp.compile("(?:#{IUNRESERVED}|#{PCT_ENCODED}|#{SUB_DELIMS}|:|@)").freeze
37
-
38
- IQUERY = Regexp.compile("(?:#{IPCHAR}|#{IPRIVATE}|/|\\?)*").freeze
39
-
40
- IFRAGMENT = Regexp.compile("(?:#{IPCHAR}|/|\\?)*").freeze.freeze
41
-
42
- ISEGMENT = Regexp.compile("(?:#{IPCHAR})*").freeze
43
- ISEGMENT_NZ = Regexp.compile("(?:#{IPCHAR})+").freeze
44
- ISEGMENT_NZ_NC = Regexp.compile("(?:(?:#{IUNRESERVED})|(?:#{PCT_ENCODED})|(?:#{SUB_DELIMS})|@)+").freeze
45
-
46
- IPATH_ABEMPTY = Regexp.compile("(?:/#{ISEGMENT})*").freeze
47
- IPATH_ABSOLUTE = Regexp.compile("/(?:(?:#{ISEGMENT_NZ})(/#{ISEGMENT})*)?").freeze
48
- IPATH_NOSCHEME = Regexp.compile("(?:#{ISEGMENT_NZ_NC})(?:/#{ISEGMENT})*").freeze
49
- IPATH_ROOTLESS = Regexp.compile("(?:#{ISEGMENT_NZ})(?:/#{ISEGMENT})*").freeze
50
- IPATH_EMPTY = Regexp.compile("").freeze
51
-
52
- IREG_NAME = Regexp.compile("(?:(?:#{IUNRESERVED})|(?:#{PCT_ENCODED})|(?:#{SUB_DELIMS}))*").freeze
53
- IHOST = Regexp.compile("(?:#{IP_LITERAL})|(?:#{IREG_NAME})").freeze
54
- IUSERINFO = Regexp.compile("(?:(?:#{IUNRESERVED})|(?:#{PCT_ENCODED})|(?:#{SUB_DELIMS})|:)*").freeze
55
- IAUTHORITY = Regexp.compile("(?:#{IUSERINFO}@)?#{IHOST}(?::#{PORT})?").freeze
56
-
57
- IRELATIVE_PART = Regexp.compile("(?:(?://#{IAUTHORITY}(?:#{IPATH_ABEMPTY}))|(?:#{IPATH_ABSOLUTE})|(?:#{IPATH_NOSCHEME})|(?:#{IPATH_EMPTY}))").freeze
58
- IRELATIVE_REF = Regexp.compile("^#{IRELATIVE_PART}(?:\\?#{IQUERY})?(?:\\##{IFRAGMENT})?$").freeze
59
-
60
- IHIER_PART = Regexp.compile("(?:(?://#{IAUTHORITY}#{IPATH_ABEMPTY})|(?:#{IPATH_ABSOLUTE})|(?:#{IPATH_ROOTLESS})|(?:#{IPATH_EMPTY}))").freeze
61
- IRI = Regexp.compile("^#{SCHEME}:(?:#{IHIER_PART})(?:\\?#{IQUERY})?(?:\\##{IFRAGMENT})?$").freeze
12
+ INVALID_QUERY_REGEX = /[[:space:]]/.freeze
62
13
 
63
14
  def valid_spec_format?(data, format)
64
15
  case format
@@ -81,13 +32,13 @@ module JSONSchemer
81
32
  when 'ipv6'
82
33
  valid_ip?(data, :v6)
83
34
  when 'uri'
84
- data.ascii_only? && valid_iri?(data)
35
+ valid_uri?(data)
85
36
  when 'uri-reference'
86
- data.ascii_only? && (valid_iri?(data) || valid_iri_reference?(data))
37
+ valid_uri_reference?(data)
87
38
  when 'iri'
88
- valid_iri?(data)
39
+ valid_uri?(iri_escape(data))
89
40
  when 'iri-reference'
90
- valid_iri?(data) || valid_iri_reference?(data)
41
+ valid_uri_reference?(iri_escape(data))
91
42
  when 'uri-template'
92
43
  valid_uri_template?(data)
93
44
  when 'json-pointer'
@@ -129,12 +80,28 @@ module JSONSchemer
129
80
  false
130
81
  end
131
82
 
132
- def valid_iri?(data)
133
- IRI.match?(data)
83
+ def parse_uri_scheme(data)
84
+ scheme, _userinfo, _host, _port, _registry, _path, opaque, query, _fragment = URI::RFC3986_PARSER.split(data)
85
+ # URI::RFC3986_PARSER.parse allows spaces in these and I don't think it should
86
+ raise URI::InvalidURIError if INVALID_QUERY_REGEX.match?(query) || INVALID_QUERY_REGEX.match?(opaque)
87
+ scheme
88
+ end
89
+
90
+ def valid_uri?(data)
91
+ !!parse_uri_scheme(data)
92
+ rescue URI::InvalidURIError
93
+ false
94
+ end
95
+
96
+ def valid_uri_reference?(data)
97
+ parse_uri_scheme(data)
98
+ true
99
+ rescue URI::InvalidURIError
100
+ false
134
101
  end
135
102
 
136
- def valid_iri_reference?(data)
137
- IRELATIVE_REF.match?(data)
103
+ def iri_escape(data)
104
+ URI.escape(data, /[^[[:ascii:]]]/)
138
105
  end
139
106
 
140
107
  def valid_uri_template?(data)
@@ -4,15 +4,16 @@ module JSONSchemer
4
4
  class Base
5
5
  include Format
6
6
 
7
- Instance = Struct.new(:data, :data_pointer, :schema, :schema_pointer, :parent_uri) do
7
+ Instance = Struct.new(:data, :data_pointer, :schema, :schema_pointer, :parent_uri, :insert_property_defaults) do
8
8
  def merge(
9
9
  data: self.data,
10
10
  data_pointer: self.data_pointer,
11
11
  schema: self.schema,
12
12
  schema_pointer: self.schema_pointer,
13
- parent_uri: self.parent_uri
13
+ parent_uri: self.parent_uri,
14
+ insert_property_defaults: self.insert_property_defaults
14
15
  )
15
- self.class.new(data, data_pointer, schema, schema_pointer, parent_uri)
16
+ self.class.new(data, data_pointer, schema, schema_pointer, parent_uri, insert_property_defaults)
16
17
  end
17
18
  end
18
19
 
@@ -46,11 +47,11 @@ module JSONSchemer
46
47
  end
47
48
 
48
49
  def valid?(data)
49
- valid_instance?(Instance.new(data, '', root, '', nil))
50
+ valid_instance?(Instance.new(data, '', root, '', nil, !!@insert_property_defaults))
50
51
  end
51
52
 
52
53
  def validate(data)
53
- validate_instance(Instance.new(data, '', root, '', nil))
54
+ validate_instance(Instance.new(data, '', root, '', nil, !!@insert_property_defaults))
54
55
  end
55
56
 
56
57
  protected
@@ -115,20 +116,35 @@ module JSONSchemer
115
116
 
116
117
  if all_of
117
118
  all_of.each_with_index do |subschema, index|
118
- validate_instance(instance.merge(schema: subschema, schema_pointer: "#{instance.schema_pointer}/allOf/#{index}"), &block)
119
+ subinstance = instance.merge(
120
+ schema: subschema,
121
+ schema_pointer: "#{instance.schema_pointer}/allOf/#{index}",
122
+ insert_property_defaults: false
123
+ )
124
+ validate_instance(subinstance, &block)
119
125
  end
120
126
  end
121
127
 
122
128
  if any_of
123
129
  subschemas = any_of.lazy.with_index.map do |subschema, index|
124
- validate_instance(instance.merge(schema: subschema, schema_pointer: "#{instance.schema_pointer}/anyOf/#{index}"))
130
+ subinstance = instance.merge(
131
+ schema: subschema,
132
+ schema_pointer: "#{instance.schema_pointer}/anyOf/#{index}",
133
+ insert_property_defaults: false
134
+ )
135
+ validate_instance(subinstance)
125
136
  end
126
137
  subschemas.each { |subschema| subschema.each(&block) } unless subschemas.any?(&:none?)
127
138
  end
128
139
 
129
140
  if one_of
130
141
  subschemas = one_of.map.with_index do |subschema, index|
131
- validate_instance(instance.merge(schema: subschema, schema_pointer: "#{instance.schema_pointer}/oneOf/#{index}"))
142
+ subinstance = instance.merge(
143
+ schema: subschema,
144
+ schema_pointer: "#{instance.schema_pointer}/oneOf/#{index}",
145
+ insert_property_defaults: false
146
+ )
147
+ validate_instance(subinstance)
132
148
  end
133
149
  valid_subschema_count = subschemas.count(&:none?)
134
150
  if valid_subschema_count > 1
@@ -139,11 +155,15 @@ module JSONSchemer
139
155
  end
140
156
 
141
157
  unless not_schema.nil?
142
- subinstance = instance.merge(schema: not_schema, schema_pointer: "#{instance.schema_pointer}/not")
158
+ subinstance = instance.merge(
159
+ schema: not_schema,
160
+ schema_pointer: "#{instance.schema_pointer}/not",
161
+ insert_property_defaults: false
162
+ )
143
163
  yield error(subinstance, 'not') if valid_instance?(subinstance)
144
164
  end
145
165
 
146
- if if_schema && valid_instance?(instance.merge(schema: if_schema))
166
+ if if_schema && valid_instance?(instance.merge(schema: if_schema, insert_property_defaults: false))
147
167
  validate_instance(instance.merge(schema: then_schema, schema_pointer: "#{instance.schema_pointer}/then"), &block) unless then_schema.nil?
148
168
  elsif if_schema
149
169
  validate_instance(instance.merge(schema: else_schema, schema_pointer: "#{instance.schema_pointer}/else"), &block) unless else_schema.nil?
@@ -179,10 +199,6 @@ module JSONSchemer
179
199
  !!@format
180
200
  end
181
201
 
182
- def insert_property_defaults?
183
- !!@insert_property_defaults
184
- end
185
-
186
202
  def custom_format?(format)
187
203
  !!(formats && formats.key?(format))
188
204
  end
@@ -195,7 +211,6 @@ module JSONSchemer
195
211
  JSONSchemer.schema(
196
212
  schema,
197
213
  format: format?,
198
- insert_property_defaults: insert_property_defaults?,
199
214
  formats: formats,
200
215
  keywords: keywords,
201
216
  ref_resolver: ref_resolver
@@ -250,27 +265,32 @@ module JSONSchemer
250
265
  end
251
266
 
252
267
  def validate_ref(instance, ref, &block)
253
- ref_uri = join_uri(instance.parent_uri, ref)
254
-
255
- if valid_json_pointer?(ref_uri.fragment)
256
- ref_pointer = Hana::Pointer.new(URI.decode_www_form_component(ref_uri.fragment))
257
- if ref.start_with?('#')
268
+ if ref.start_with?('#')
269
+ schema_pointer = ref.slice(1..-1)
270
+ if valid_json_pointer?(schema_pointer)
271
+ ref_pointer = Hana::Pointer.new(URI.decode_www_form_component(schema_pointer))
258
272
  subinstance = instance.merge(
259
273
  schema: ref_pointer.eval(root),
260
- schema_pointer: ref_uri.fragment,
261
- parent_uri: (pointer_uri(root, ref_pointer) || ref_uri)
274
+ schema_pointer: schema_pointer,
275
+ parent_uri: (pointer_uri(root, ref_pointer) || instance.parent_uri)
262
276
  )
263
277
  validate_instance(subinstance, &block)
264
- else
265
- ref_root = resolve_ref(ref_uri)
266
- ref_object = child(ref_root)
267
- subinstance = instance.merge(
268
- schema: ref_pointer.eval(ref_root),
269
- schema_pointer: ref_uri.fragment,
270
- parent_uri: (pointer_uri(ref_root, ref_pointer) || ref_uri)
271
- )
272
- ref_object.validate_instance(subinstance, &block)
278
+ return
273
279
  end
280
+ end
281
+
282
+ ref_uri = join_uri(instance.parent_uri, ref)
283
+
284
+ if valid_json_pointer?(ref_uri.fragment)
285
+ ref_pointer = Hana::Pointer.new(URI.decode_www_form_component(ref_uri.fragment))
286
+ ref_root = resolve_ref(ref_uri)
287
+ ref_object = child(ref_root)
288
+ subinstance = instance.merge(
289
+ schema: ref_pointer.eval(ref_root),
290
+ schema_pointer: ref_uri.fragment,
291
+ parent_uri: (pointer_uri(ref_root, ref_pointer) || ref_uri)
292
+ )
293
+ ref_object.validate_instance(subinstance, &block)
274
294
  elsif id = ids[ref_uri.to_s]
275
295
  subinstance = instance.merge(
276
296
  schema: id.fetch(:schema),
@@ -467,7 +487,7 @@ module JSONSchemer
467
487
  dependencies = schema['dependencies']
468
488
  property_names = schema['propertyNames']
469
489
 
470
- if insert_property_defaults? && properties
490
+ if instance.insert_property_defaults && properties
471
491
  properties.each do |property, property_schema|
472
492
  if !data.key?(property) && property_schema.is_a?(Hash) && property_schema.key?('default')
473
493
  data[property] = property_schema.fetch('default').clone
@@ -1,4 +1,4 @@
1
1
  # frozen_string_literal: true
2
2
  module JSONSchemer
3
- VERSION = '0.2.7'
3
+ VERSION = '0.2.12'
4
4
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: json_schemer
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.7
4
+ version: 0.2.12
5
5
  platform: ruby
6
6
  authors:
7
7
  - David Harsha
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-09-23 00:00:00.000000000 Z
11
+ date: 2020-07-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -30,14 +30,14 @@ dependencies:
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: '10.0'
33
+ version: '13.0'
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: '10.0'
40
+ version: '13.0'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: minitest
43
43
  requirement: !ruby/object:Gem::Requirement
@@ -119,229 +119,6 @@ files:
119
119
  - ".gitignore"
120
120
  - Gemfile
121
121
  - Gemfile.lock
122
- - JSON-Schema-Test-Suite/.gitignore
123
- - JSON-Schema-Test-Suite/.travis.yml
124
- - JSON-Schema-Test-Suite/LICENSE
125
- - JSON-Schema-Test-Suite/README.md
126
- - JSON-Schema-Test-Suite/bin/jsonschema_suite
127
- - JSON-Schema-Test-Suite/index.js
128
- - JSON-Schema-Test-Suite/package.json
129
- - JSON-Schema-Test-Suite/remotes/folder/folderInteger.json
130
- - JSON-Schema-Test-Suite/remotes/integer.json
131
- - JSON-Schema-Test-Suite/remotes/name-defs.json
132
- - JSON-Schema-Test-Suite/remotes/name.json
133
- - JSON-Schema-Test-Suite/remotes/subSchemas.json
134
- - JSON-Schema-Test-Suite/test-schema.json
135
- - JSON-Schema-Test-Suite/tests/draft2019-08/additionalItems.json
136
- - JSON-Schema-Test-Suite/tests/draft2019-08/additionalProperties.json
137
- - JSON-Schema-Test-Suite/tests/draft2019-08/allOf.json
138
- - JSON-Schema-Test-Suite/tests/draft2019-08/anyOf.json
139
- - JSON-Schema-Test-Suite/tests/draft2019-08/boolean_schema.json
140
- - JSON-Schema-Test-Suite/tests/draft2019-08/const.json
141
- - JSON-Schema-Test-Suite/tests/draft2019-08/contains.json
142
- - JSON-Schema-Test-Suite/tests/draft2019-08/default.json
143
- - JSON-Schema-Test-Suite/tests/draft2019-08/defs.json
144
- - JSON-Schema-Test-Suite/tests/draft2019-08/dependencies.json
145
- - JSON-Schema-Test-Suite/tests/draft2019-08/enum.json
146
- - JSON-Schema-Test-Suite/tests/draft2019-08/exclusiveMaximum.json
147
- - JSON-Schema-Test-Suite/tests/draft2019-08/exclusiveMinimum.json
148
- - JSON-Schema-Test-Suite/tests/draft2019-08/if-then-else.json
149
- - JSON-Schema-Test-Suite/tests/draft2019-08/items.json
150
- - JSON-Schema-Test-Suite/tests/draft2019-08/maxItems.json
151
- - JSON-Schema-Test-Suite/tests/draft2019-08/maxLength.json
152
- - JSON-Schema-Test-Suite/tests/draft2019-08/maxProperties.json
153
- - JSON-Schema-Test-Suite/tests/draft2019-08/maximum.json
154
- - JSON-Schema-Test-Suite/tests/draft2019-08/minItems.json
155
- - JSON-Schema-Test-Suite/tests/draft2019-08/minLength.json
156
- - JSON-Schema-Test-Suite/tests/draft2019-08/minProperties.json
157
- - JSON-Schema-Test-Suite/tests/draft2019-08/minimum.json
158
- - JSON-Schema-Test-Suite/tests/draft2019-08/multipleOf.json
159
- - JSON-Schema-Test-Suite/tests/draft2019-08/not.json
160
- - JSON-Schema-Test-Suite/tests/draft2019-08/oneOf.json
161
- - JSON-Schema-Test-Suite/tests/draft2019-08/optional/bignum.json
162
- - JSON-Schema-Test-Suite/tests/draft2019-08/optional/content.json
163
- - JSON-Schema-Test-Suite/tests/draft2019-08/optional/ecmascript-regex.json
164
- - JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/date-time.json
165
- - JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/date.json
166
- - JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/email.json
167
- - JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/hostname.json
168
- - JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/idn-email.json
169
- - JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/idn-hostname.json
170
- - JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/ipv4.json
171
- - JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/ipv6.json
172
- - JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/iri-reference.json
173
- - JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/iri.json
174
- - JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/json-pointer.json
175
- - JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/regex.json
176
- - JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/relative-json-pointer.json
177
- - JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/time.json
178
- - JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/uri-reference.json
179
- - JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/uri-template.json
180
- - JSON-Schema-Test-Suite/tests/draft2019-08/optional/format/uri.json
181
- - JSON-Schema-Test-Suite/tests/draft2019-08/optional/zeroTerminatedFloats.json
182
- - JSON-Schema-Test-Suite/tests/draft2019-08/pattern.json
183
- - JSON-Schema-Test-Suite/tests/draft2019-08/patternProperties.json
184
- - JSON-Schema-Test-Suite/tests/draft2019-08/properties.json
185
- - JSON-Schema-Test-Suite/tests/draft2019-08/propertyNames.json
186
- - JSON-Schema-Test-Suite/tests/draft2019-08/ref.json
187
- - JSON-Schema-Test-Suite/tests/draft2019-08/refRemote.json
188
- - JSON-Schema-Test-Suite/tests/draft2019-08/required.json
189
- - JSON-Schema-Test-Suite/tests/draft2019-08/type.json
190
- - JSON-Schema-Test-Suite/tests/draft2019-08/uniqueItems.json
191
- - JSON-Schema-Test-Suite/tests/draft3/additionalItems.json
192
- - JSON-Schema-Test-Suite/tests/draft3/additionalProperties.json
193
- - JSON-Schema-Test-Suite/tests/draft3/default.json
194
- - JSON-Schema-Test-Suite/tests/draft3/dependencies.json
195
- - JSON-Schema-Test-Suite/tests/draft3/disallow.json
196
- - JSON-Schema-Test-Suite/tests/draft3/divisibleBy.json
197
- - JSON-Schema-Test-Suite/tests/draft3/enum.json
198
- - JSON-Schema-Test-Suite/tests/draft3/extends.json
199
- - JSON-Schema-Test-Suite/tests/draft3/items.json
200
- - JSON-Schema-Test-Suite/tests/draft3/maxItems.json
201
- - JSON-Schema-Test-Suite/tests/draft3/maxLength.json
202
- - JSON-Schema-Test-Suite/tests/draft3/maximum.json
203
- - JSON-Schema-Test-Suite/tests/draft3/minItems.json
204
- - JSON-Schema-Test-Suite/tests/draft3/minLength.json
205
- - JSON-Schema-Test-Suite/tests/draft3/minimum.json
206
- - JSON-Schema-Test-Suite/tests/draft3/optional/bignum.json
207
- - JSON-Schema-Test-Suite/tests/draft3/optional/format.json
208
- - JSON-Schema-Test-Suite/tests/draft3/optional/jsregex.json
209
- - JSON-Schema-Test-Suite/tests/draft3/optional/zeroTerminatedFloats.json
210
- - JSON-Schema-Test-Suite/tests/draft3/pattern.json
211
- - JSON-Schema-Test-Suite/tests/draft3/patternProperties.json
212
- - JSON-Schema-Test-Suite/tests/draft3/properties.json
213
- - JSON-Schema-Test-Suite/tests/draft3/ref.json
214
- - JSON-Schema-Test-Suite/tests/draft3/refRemote.json
215
- - JSON-Schema-Test-Suite/tests/draft3/required.json
216
- - JSON-Schema-Test-Suite/tests/draft3/type.json
217
- - JSON-Schema-Test-Suite/tests/draft3/uniqueItems.json
218
- - JSON-Schema-Test-Suite/tests/draft4/additionalItems.json
219
- - JSON-Schema-Test-Suite/tests/draft4/additionalProperties.json
220
- - JSON-Schema-Test-Suite/tests/draft4/allOf.json
221
- - JSON-Schema-Test-Suite/tests/draft4/anyOf.json
222
- - JSON-Schema-Test-Suite/tests/draft4/default.json
223
- - JSON-Schema-Test-Suite/tests/draft4/definitions.json
224
- - JSON-Schema-Test-Suite/tests/draft4/dependencies.json
225
- - JSON-Schema-Test-Suite/tests/draft4/enum.json
226
- - JSON-Schema-Test-Suite/tests/draft4/items.json
227
- - JSON-Schema-Test-Suite/tests/draft4/maxItems.json
228
- - JSON-Schema-Test-Suite/tests/draft4/maxLength.json
229
- - JSON-Schema-Test-Suite/tests/draft4/maxProperties.json
230
- - JSON-Schema-Test-Suite/tests/draft4/maximum.json
231
- - JSON-Schema-Test-Suite/tests/draft4/minItems.json
232
- - JSON-Schema-Test-Suite/tests/draft4/minLength.json
233
- - JSON-Schema-Test-Suite/tests/draft4/minProperties.json
234
- - JSON-Schema-Test-Suite/tests/draft4/minimum.json
235
- - JSON-Schema-Test-Suite/tests/draft4/multipleOf.json
236
- - JSON-Schema-Test-Suite/tests/draft4/not.json
237
- - JSON-Schema-Test-Suite/tests/draft4/oneOf.json
238
- - JSON-Schema-Test-Suite/tests/draft4/optional/bignum.json
239
- - JSON-Schema-Test-Suite/tests/draft4/optional/ecmascript-regex.json
240
- - JSON-Schema-Test-Suite/tests/draft4/optional/format.json
241
- - JSON-Schema-Test-Suite/tests/draft4/optional/zeroTerminatedFloats.json
242
- - JSON-Schema-Test-Suite/tests/draft4/pattern.json
243
- - JSON-Schema-Test-Suite/tests/draft4/patternProperties.json
244
- - JSON-Schema-Test-Suite/tests/draft4/properties.json
245
- - JSON-Schema-Test-Suite/tests/draft4/ref.json
246
- - JSON-Schema-Test-Suite/tests/draft4/refRemote.json
247
- - JSON-Schema-Test-Suite/tests/draft4/required.json
248
- - JSON-Schema-Test-Suite/tests/draft4/type.json
249
- - JSON-Schema-Test-Suite/tests/draft4/uniqueItems.json
250
- - JSON-Schema-Test-Suite/tests/draft6/additionalItems.json
251
- - JSON-Schema-Test-Suite/tests/draft6/additionalProperties.json
252
- - JSON-Schema-Test-Suite/tests/draft6/allOf.json
253
- - JSON-Schema-Test-Suite/tests/draft6/anyOf.json
254
- - JSON-Schema-Test-Suite/tests/draft6/boolean_schema.json
255
- - JSON-Schema-Test-Suite/tests/draft6/const.json
256
- - JSON-Schema-Test-Suite/tests/draft6/contains.json
257
- - JSON-Schema-Test-Suite/tests/draft6/default.json
258
- - JSON-Schema-Test-Suite/tests/draft6/definitions.json
259
- - JSON-Schema-Test-Suite/tests/draft6/dependencies.json
260
- - JSON-Schema-Test-Suite/tests/draft6/enum.json
261
- - JSON-Schema-Test-Suite/tests/draft6/exclusiveMaximum.json
262
- - JSON-Schema-Test-Suite/tests/draft6/exclusiveMinimum.json
263
- - JSON-Schema-Test-Suite/tests/draft6/items.json
264
- - JSON-Schema-Test-Suite/tests/draft6/maxItems.json
265
- - JSON-Schema-Test-Suite/tests/draft6/maxLength.json
266
- - JSON-Schema-Test-Suite/tests/draft6/maxProperties.json
267
- - JSON-Schema-Test-Suite/tests/draft6/maximum.json
268
- - JSON-Schema-Test-Suite/tests/draft6/minItems.json
269
- - JSON-Schema-Test-Suite/tests/draft6/minLength.json
270
- - JSON-Schema-Test-Suite/tests/draft6/minProperties.json
271
- - JSON-Schema-Test-Suite/tests/draft6/minimum.json
272
- - JSON-Schema-Test-Suite/tests/draft6/multipleOf.json
273
- - JSON-Schema-Test-Suite/tests/draft6/not.json
274
- - JSON-Schema-Test-Suite/tests/draft6/oneOf.json
275
- - JSON-Schema-Test-Suite/tests/draft6/optional/bignum.json
276
- - JSON-Schema-Test-Suite/tests/draft6/optional/ecmascript-regex.json
277
- - JSON-Schema-Test-Suite/tests/draft6/optional/format.json
278
- - JSON-Schema-Test-Suite/tests/draft6/optional/zeroTerminatedFloats.json
279
- - JSON-Schema-Test-Suite/tests/draft6/pattern.json
280
- - JSON-Schema-Test-Suite/tests/draft6/patternProperties.json
281
- - JSON-Schema-Test-Suite/tests/draft6/properties.json
282
- - JSON-Schema-Test-Suite/tests/draft6/propertyNames.json
283
- - JSON-Schema-Test-Suite/tests/draft6/ref.json
284
- - JSON-Schema-Test-Suite/tests/draft6/refRemote.json
285
- - JSON-Schema-Test-Suite/tests/draft6/required.json
286
- - JSON-Schema-Test-Suite/tests/draft6/type.json
287
- - JSON-Schema-Test-Suite/tests/draft6/uniqueItems.json
288
- - JSON-Schema-Test-Suite/tests/draft7/additionalItems.json
289
- - JSON-Schema-Test-Suite/tests/draft7/additionalProperties.json
290
- - JSON-Schema-Test-Suite/tests/draft7/allOf.json
291
- - JSON-Schema-Test-Suite/tests/draft7/anyOf.json
292
- - JSON-Schema-Test-Suite/tests/draft7/boolean_schema.json
293
- - JSON-Schema-Test-Suite/tests/draft7/const.json
294
- - JSON-Schema-Test-Suite/tests/draft7/contains.json
295
- - JSON-Schema-Test-Suite/tests/draft7/default.json
296
- - JSON-Schema-Test-Suite/tests/draft7/definitions.json
297
- - JSON-Schema-Test-Suite/tests/draft7/dependencies.json
298
- - JSON-Schema-Test-Suite/tests/draft7/enum.json
299
- - JSON-Schema-Test-Suite/tests/draft7/exclusiveMaximum.json
300
- - JSON-Schema-Test-Suite/tests/draft7/exclusiveMinimum.json
301
- - JSON-Schema-Test-Suite/tests/draft7/if-then-else.json
302
- - JSON-Schema-Test-Suite/tests/draft7/items.json
303
- - JSON-Schema-Test-Suite/tests/draft7/maxItems.json
304
- - JSON-Schema-Test-Suite/tests/draft7/maxLength.json
305
- - JSON-Schema-Test-Suite/tests/draft7/maxProperties.json
306
- - JSON-Schema-Test-Suite/tests/draft7/maximum.json
307
- - JSON-Schema-Test-Suite/tests/draft7/minItems.json
308
- - JSON-Schema-Test-Suite/tests/draft7/minLength.json
309
- - JSON-Schema-Test-Suite/tests/draft7/minProperties.json
310
- - JSON-Schema-Test-Suite/tests/draft7/minimum.json
311
- - JSON-Schema-Test-Suite/tests/draft7/multipleOf.json
312
- - JSON-Schema-Test-Suite/tests/draft7/not.json
313
- - JSON-Schema-Test-Suite/tests/draft7/oneOf.json
314
- - JSON-Schema-Test-Suite/tests/draft7/optional/bignum.json
315
- - JSON-Schema-Test-Suite/tests/draft7/optional/content.json
316
- - JSON-Schema-Test-Suite/tests/draft7/optional/ecmascript-regex.json
317
- - JSON-Schema-Test-Suite/tests/draft7/optional/format/date-time.json
318
- - JSON-Schema-Test-Suite/tests/draft7/optional/format/date.json
319
- - JSON-Schema-Test-Suite/tests/draft7/optional/format/email.json
320
- - JSON-Schema-Test-Suite/tests/draft7/optional/format/hostname.json
321
- - JSON-Schema-Test-Suite/tests/draft7/optional/format/idn-email.json
322
- - JSON-Schema-Test-Suite/tests/draft7/optional/format/idn-hostname.json
323
- - JSON-Schema-Test-Suite/tests/draft7/optional/format/ipv4.json
324
- - JSON-Schema-Test-Suite/tests/draft7/optional/format/ipv6.json
325
- - JSON-Schema-Test-Suite/tests/draft7/optional/format/iri-reference.json
326
- - JSON-Schema-Test-Suite/tests/draft7/optional/format/iri.json
327
- - JSON-Schema-Test-Suite/tests/draft7/optional/format/json-pointer.json
328
- - JSON-Schema-Test-Suite/tests/draft7/optional/format/regex.json
329
- - JSON-Schema-Test-Suite/tests/draft7/optional/format/relative-json-pointer.json
330
- - JSON-Schema-Test-Suite/tests/draft7/optional/format/time.json
331
- - JSON-Schema-Test-Suite/tests/draft7/optional/format/uri-reference.json
332
- - JSON-Schema-Test-Suite/tests/draft7/optional/format/uri-template.json
333
- - JSON-Schema-Test-Suite/tests/draft7/optional/format/uri.json
334
- - JSON-Schema-Test-Suite/tests/draft7/optional/zeroTerminatedFloats.json
335
- - JSON-Schema-Test-Suite/tests/draft7/pattern.json
336
- - JSON-Schema-Test-Suite/tests/draft7/patternProperties.json
337
- - JSON-Schema-Test-Suite/tests/draft7/properties.json
338
- - JSON-Schema-Test-Suite/tests/draft7/propertyNames.json
339
- - JSON-Schema-Test-Suite/tests/draft7/ref.json
340
- - JSON-Schema-Test-Suite/tests/draft7/refRemote.json
341
- - JSON-Schema-Test-Suite/tests/draft7/required.json
342
- - JSON-Schema-Test-Suite/tests/draft7/type.json
343
- - JSON-Schema-Test-Suite/tests/draft7/uniqueItems.json
344
- - JSON-Schema-Test-Suite/tox.ini
345
122
  - LICENSE.txt
346
123
  - README.md
347
124
  - Rakefile
@@ -350,6 +127,7 @@ files:
350
127
  - json_schemer.gemspec
351
128
  - lib/json_schemer.rb
352
129
  - lib/json_schemer/cached_ref_resolver.rb
130
+ - lib/json_schemer/errors.rb
353
131
  - lib/json_schemer/format.rb
354
132
  - lib/json_schemer/schema/base.rb
355
133
  - lib/json_schemer/schema/draft4.rb
@@ -368,14 +146,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
368
146
  requirements:
369
147
  - - "~>"
370
148
  - !ruby/object:Gem::Version
371
- version: '2.4'
149
+ version: '2.5'
372
150
  required_rubygems_version: !ruby/object:Gem::Requirement
373
151
  requirements:
374
152
  - - ">="
375
153
  - !ruby/object:Gem::Version
376
154
  version: '0'
377
155
  requirements: []
378
- rubygems_version: 3.0.3
156
+ rubyforge_project:
157
+ rubygems_version: 2.7.6
379
158
  signing_key:
380
159
  specification_version: 4
381
160
  summary: JSON Schema validator. Supports drafts 4, 6, and 7.