use strictures 1; use Test::More qw(no_plan); use HTML::Zoom; my $root = HTML::Zoom ->from_html(< Default Title Default Content MAIN $root = $root ->select('body') ->set_attribute(class=>'main'); $root = $root ->select('body') ->add_to_attribute(class=>'one-column'); $root = $root ->select('title') ->replace_content('Hello World'); my $body = HTML::Zoom ->from_html(<

Well Now

Is the Time

BODY $root = $root ->select('body') ->replace_content($body); $root = $root ->select('p') ->set_attribute(class=>'para'); $root = $root ->select('body') ->remove_attribute('bad_attr'); my $output = $root->to_html; my $expect = < Hello World

Well Now

Is the Time

HTML is($output, $expect, 'Synopsis code works ok');