use strict; use Test::Base; use Web::Scraper; plan tests => 1 * blocks; filters { selector => 'chomp', want => 'chomp', expected => 'chomp', }; run { my $block = shift; my $s = scraper { process $block->selector, want => $block->want; result 'want'; }; my $want = $s->scrape($block->html); is $want, $block->expected, $block->name; }; __DATA__ === TEXT --- html
foo bar
foo bar
foo bar & baz
foo bar & baz