|
|
@ -1,5 +1,5 @@ |
|
|
|
require "json-schema" |
|
|
|
|
|
|
|
require "json" |
|
|
|
require "json" |
|
|
|
|
|
|
|
require "json-schema" |
|
|
|
|
|
|
|
|
|
|
|
def get_all_form_paths(directories) |
|
|
|
def get_all_form_paths(directories) |
|
|
|
form_paths = [] |
|
|
|
form_paths = [] |
|
|
@ -12,7 +12,6 @@ def get_all_form_paths(directories) |
|
|
|
end |
|
|
|
end |
|
|
|
|
|
|
|
|
|
|
|
begin |
|
|
|
begin |
|
|
|
|
|
|
|
|
|
|
|
path = "config/forms/schema/generic.json" |
|
|
|
path = "config/forms/schema/generic.json" |
|
|
|
|
|
|
|
|
|
|
|
file = File.open(path) |
|
|
|
file = File.open(path) |
|
|
@ -36,8 +35,6 @@ begin |
|
|
|
file = File.open(path) |
|
|
|
file = File.open(path) |
|
|
|
data = JSON.parse(file.read) |
|
|
|
data = JSON.parse(file.read) |
|
|
|
|
|
|
|
|
|
|
|
puts JSON::Validator.validate(schema, data, :strict => true) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
puts JSON::Validator.fully_validate(schema, data, :strict => true) |
|
|
|
puts JSON::Validator.fully_validate(schema, data, :strict => true) |
|
|
|
|
|
|
|
|
|
|
|
begin |
|
|
|
begin |
|
|
|