X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2Fdom.t;h=d80a3c33aa2c0d063a292e0ab329961401c0c240;hb=927f135111d601e084c5a50e2d806bddd5c9cefb;hp=ed69234a5c9e301219faf78fe149775a84de0a34;hpb=d6512b506041e5f51cb53585efc6823ec5f3b109;p=catagits%2FDOM-Tiny.git diff --git a/t/dom.t b/t/dom.t index ed69234..d80a3c3 100644 --- a/t/dom.t +++ b/t/dom.t @@ -774,9 +774,12 @@ is $dom->at('[test=""]')->tag, 'div', 'right tag'; is $dom->at('[test2=""]')->tag, 'div', 'right tag'; is $dom->at('[test3=""]'), undef, 'no result'; -# Multi-line in attribute -$dom = DOM::Tiny->new(qq{
}); -is $dom->at('div')->attr->{test}, "line1\nline2", 'multi-line attribute'; +# Multi-line attribute +$dom = DOM::Tiny->new(qq{
}); +is $dom->at('div')->attr->{class}, "line1\nline2", 'multi-line attribute value'; +is $dom->at('.line1')->tag, 'div', 'right tag'; +is $dom->at('.line2')->tag, 'div', 'right tag'; +is $dom->at('.line3'), undef, 'no result'; # Whitespaces before closing bracket $dom = DOM::Tiny->new('
content
');