Sha256: 5dd174902d9c924930ae68cfecebf374499bbaef5767529ea28311032f8f73fd
Contents?: true
Size: 556 Bytes
Versions: 24
Compression:
Stored size: 556 Bytes
Contents
# encoding: UTF-8 require 'tc_helper.rb' class TestDefault < Test::Unit::TestCase def test_content_type_restriction assert_raise(ArgumentError, "raises argument error if invlalid ContentType is") { Axlsx::Default.new :ContentType=>"asdf" } end def test_to_xml_string type = Axlsx::Default.new :Extension=>"xml", :ContentType=>Axlsx::XML_CT doc = Nokogiri::XML(type.to_xml_string) assert_equal(doc.xpath("Default[@ContentType='#{Axlsx::XML_CT}']").size, 1) assert_equal(doc.xpath("Default[@Extension='xml']").size, 1) end end
Version data entries
24 entries across 24 versions & 6 rubygems