Sha256: 639b75aad9315fbfd68b4004efd902cf63fc05eda09a871676fc8d1ce68ec540
Contents?: true
Size: 619 Bytes
Versions: 29
Compression:
Stored size: 619 Bytes
Contents
RSpec::Matchers.define :be_a_valid_ebics_doc do ## # use #open instead of #read to have the includes working # http://stackoverflow.com/questions/11996326/nokogirixmlschema-syntaxerror-on-schema-load/22971456#22971456 def xsd @xsd ||= Nokogiri::XML::Schema(File.open( File.join( File.dirname(__FILE__), '..', 'xsd', 'ebics_H004.xsd') )) end match do |actual| xsd.valid?(Nokogiri::XML(actual)) end failure_message do |actual| "expected that #{actual} would be a valid EBICS doc:\n\n #{xsd.validate(Nokogiri::XML(actual))}" end description do "be a valid EBCIS document" end end
Version data entries
29 entries across 29 versions & 1 rubygems