json_schema 0.20.7 → 0.20.8
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/bin/validate-schema +10 -12
- data/test/bin_test.rb +5 -6
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 239a8df86c5fd746683d265f47f53ee415ac40613c8411abc8e4492cc3e02e18
|
4
|
+
data.tar.gz: 5614b247d018816964ab128923d4a86fd1fd4e6c397309bb74864c06a4ee95fd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: fad2007fa5541c260baa72dd32527fba69ed292c7ec589959f023ef8a4edc206a1bb260dc0d3b6421586758f3d707c6284aac5c300d1dda00d30250d3f78c45f
|
7
|
+
data.tar.gz: cf384d7f97d445df492f9cb67737d852b725d63542d5da2bd30809a91a36c5277ea851c7502cda03724a13ab1eb2036122eaf4c1aeb5a661e25ec4bf81993cc7
|
data/bin/validate-schema
CHANGED
@@ -26,17 +26,15 @@ parser = OptionParser.new { |opts|
|
|
26
26
|
end
|
27
27
|
}
|
28
28
|
|
29
|
-
|
30
|
-
|
31
|
-
success = command.run(ARGV.dup)
|
29
|
+
parser.parse!
|
30
|
+
success = command.run(ARGV.dup)
|
32
31
|
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
end
|
32
|
+
if success
|
33
|
+
command.messages.each { |m| $stdout.puts(m) }
|
34
|
+
elsif !command.errors.empty?
|
35
|
+
command.errors.each { |e| $stderr.puts(e) }
|
36
|
+
exit(1)
|
37
|
+
else
|
38
|
+
print_usage!
|
39
|
+
exit(1)
|
42
40
|
end
|
data/test/bin_test.rb
CHANGED
@@ -1,12 +1,10 @@
|
|
1
1
|
require "test_helper"
|
2
2
|
|
3
3
|
#
|
4
|
-
# The purpose of this sets of tests is just to
|
5
|
-
# where possible so that we can get very basic sanity checks on their syntax
|
6
|
-
# (which is something that of course Ruby can't do by default).
|
4
|
+
# The purpose of this sets of tests is just to test our Ruby executables
|
5
|
+
# where possible so that we can get very basic sanity checks on their syntax.
|
7
6
|
#
|
8
|
-
# We can do this without actually executing them
|
9
|
-
# $0 == __FILE__` statements.
|
7
|
+
# We can do this without actually executing them with a "ruby -c" call.
|
10
8
|
#
|
11
9
|
|
12
10
|
describe "executables in bin/" do
|
@@ -15,6 +13,7 @@ describe "executables in bin/" do
|
|
15
13
|
end
|
16
14
|
|
17
15
|
it "has roughly valid Ruby structure for validate-schema" do
|
18
|
-
|
16
|
+
IO.popen(["ruby", "-c", File.join(@bin_dir, "validate-schema")]) { |io| io.read }
|
17
|
+
assert_equal $?.exitstatus, 0, "Ruby syntax check failed; see error above"
|
19
18
|
end
|
20
19
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: json_schema
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.20.
|
4
|
+
version: 0.20.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Brandur
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-
|
11
|
+
date: 2019-09-13 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description:
|
14
14
|
email:
|
@@ -69,7 +69,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
69
69
|
- !ruby/object:Gem::Version
|
70
70
|
version: '0'
|
71
71
|
requirements: []
|
72
|
-
rubygems_version: 3.0.
|
72
|
+
rubygems_version: 3.0.6
|
73
73
|
signing_key:
|
74
74
|
specification_version: 4
|
75
75
|
summary: A JSON Schema V4 and Hyperschema V4 parser and validator.
|