X-Git-Url: http://www.git.stargrave.org/?p=public-inbox.git;a=blobdiff_plain;f=t%2Fpsgi_v2.t;h=2c9387a496cb0d16b31019bf2297d12ecba3d834;hp=fc825acf621936c13b323e673d069fc268bf21dd;hb=a3cf35c675217ea60a461dd9be7cc5b55c2d5280;hpb=17e52476687e03fecd579f765ad6864cde0f4203 diff --git a/t/psgi_v2.t b/t/psgi_v2.t index fc825acf..2c9387a4 100644 --- a/t/psgi_v2.t +++ b/t/psgi_v2.t @@ -160,11 +160,11 @@ test_psgi(sub { $www->call(@_) }, sub { $res = $cb->(GET('/v2test/?q=m:a-mid@b&x=A')); is($res->code, 200, 'success with Atom search'); SKIP: { - require_mods(qw(XML::Feed), 2); - $raw = $res->content; - my $p = XML::Feed->parse(\$raw); - is($p->format, "Atom", "parsed atom feed"); - is(scalar $p->entries, 3, "parsed three entries"); + require_mods(qw(XML::TreePP), 2); + my $t = XML::TreePP->new->parse($res->content); + like($t->{feed}->{-xmlns}, qr/\bAtom\b/, + 'looks like an an Atom feed'); + is(scalar @{$t->{feed}->{entry}}, 3, 'parsed three entries'); }; local $SIG{__WARN__} = 'DEFAULT';