middleman-xmlvalidator 0.0.23 → 0.0.24
Sign up to get free protection for your applications and to get access to all the features.
@@ -50,13 +50,13 @@ module Middleman
|
|
50
50
|
end
|
51
51
|
|
52
52
|
def self.validate(document_path, schema_path)
|
53
|
-
schema = Nokogiri::XML::Schema(File.read(
|
53
|
+
schema = Nokogiri::XML::Schema(File.read(schema_path))
|
54
54
|
document = Nokogiri::XML(File.read(document_path))
|
55
55
|
schema.validate(document)
|
56
56
|
end
|
57
57
|
|
58
58
|
def self.valid(document_path, schema_path)
|
59
|
-
schema = Nokogiri::XML::Schema(File.read(
|
59
|
+
schema = Nokogiri::XML::Schema(File.read(schema_path))
|
60
60
|
document = Nokogiri::XML(File.read(document_path))
|
61
61
|
schema.valid?(document)
|
62
62
|
end
|