Sha256: 46e0c9e380f6ada494afb91247a2a36b3548f0fa3dc0ed9b35549bd18564654e
Contents?: true
Size: 458 Bytes
Versions: 2
Compression:
Stored size: 458 Bytes
Contents
# -*- encoding: utf-8 -*- require "spec_helper" describe Aitch::XMLParser do it "instantiates Nokogiri" do expect(Nokogiri).to receive(:XML).with("XML", nil, "utf-8") Aitch::XMLParser.load("XML") end it "converts ISO-8859-1 to UTF-8" do xml = Aitch::XMLParser.load(File.read("./spec/fixtures/iso8859-1.xml")) expect(xml.encoding).to eql("utf-8") expect(xml.to_xml).to include(%[<?xml version="1.0" encoding="utf-8"?>]) end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
aitch-0.4.1 | spec/aitch/xml_parser_spec.rb |
aitch-0.4.0 | spec/aitch/xml_parser_spec.rb |