like(
HTML::Zoom
->from_html(q[<p class="first">Hi!</p>])
- ->add_to_attribute('p', {name => 'class', value => 'para'})
- ->to_html,
- qr/first para/,
- 'Got correct from add_to_attribute'
-);
-
-like(
- HTML::Zoom
- ->from_html(q[<p class="first">Hi!</p>])
->add_to_attribute('p', class => 'para')
->to_html,
qr/first para/,
'Got correct from set_attribute'
);
-like(
- HTML::Zoom
- ->from_html(q[<p class="first">Hi!</p>])
- ->set_attribute('p', {name => 'class', value => 'para'})
- ->to_html,
- qr/class="para"/,
- 'Got correct from set_attribute'
-);
-
is(
HTML::Zoom
->from_html(q[<p class="first">Hi!</p>])