Skip Menu |

This queue is for tickets about the XML-Atom CPAN distribution.

Report information
The Basics
Id: 27796
Status: resolved
Priority: 0/
Queue: XML-Atom

People
Owner: Nobody in particular
Requestors: SMPETERS [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: [PATCH] Test failures with older libexpat's
Solaris Express comes with a fairly old libexpat by default. The results is some odd looking, but apparently valid XML. Unfortunately, the test scripts are expecting the XML to come out in a different format. So, a couple of test script modifications to handle the differences appear to be needed. There are some additional test failures, so I'll continue to look into these. --- t/11-entry.t.old Thu Jun 28 09:12:03 2007 +++ t/11-entry.t Thu Jun 28 09:34:15 2007 @@ -146,17 +146,22 @@ $entry->set($dc, "subject" => "Weblog"); -like $entry->as_xml, qr/<dc:subject .*>Weblog<\/dc:subject>/; +like $entry->as_xml, qr/<(?:dc:subject|subject xmlns:dc).*>Weblog<\/(dc:)?subject>/; $entry->add($dc, "subject" => "Tech"); -like $entry->as_xml, qr/<dc:subject .*>Weblog<\/dc:subject>/; -like $entry->as_xml, qr/<dc:subject .*>Tech<\/dc:subject>/; +like $entry->as_xml, qr/<(?:dc:subject|subject xmlns:dc).*>Weblog<\/(dc:)?subject>/; +like $entry->as_xml, qr/<(?:dc:subject|subject xmlns:dc).*>Tech<\/(dc:)?subject>/; # re-set $entry->set($dc, "subject" => "Weblog"); -like $entry->as_xml, qr/<dc:subject .*>Weblog<\/dc:subject>/; +like $entry->as_xml, qr/<(?:dc:subject|subject xmlns:dc).*>Weblog<\/(dc:)?subject>/; # euc-jp feed -$entry = XML::Atom::Entry->new('t/samples/entry-euc.xml'); -is $entry->title, 'ã²ã¹ããªã¼ãµã¼'; -is $entry->content->body, '<p>æ¥æ¬èªã®ãã£ã¼ã</p>'; +SKIP:{ + eval { + $entry = XML::Atom::Entry->new('t/samples/entry-euc.xml'); + }; + skip "Cannot handle euc-jp encoded feed", 2 if($@ =~ /Couldn't open encmap euc-jp.enc/); + is $entry->title, 'ã²ã¹ããªã¼ãµã¼'; + is $entry->content->body, '<p>æ¥æ¬èªã®ãã£ã¼ã</p>'; +}
I believe it's fixed with 0.27