5 use List
::AllUtils
'uniq';
10 use SGN
::Test
::WWW
::Mechanize
;
11 my $mech = SGN
::Test
::WWW
::Mechanize
->new;
17 # test for any broken images or other things that have a
19 { my @stuff = grep !m
|^https?
://|, uniq
map $_->attr('src'), $mech->findnodes('//*[@src]');
20 get_ok
( $mech, $_ ) for @stuff;
25 # test for any broken local links
27 my @links = grep !m
"^(https?|mailto):", uniq
map $_->attr('href'), $mech->findnodes('//a[@href]');
29 get_ok
( $mech, $_ ) for @links;
35 my ( $mech, $url ) = @_;
37 local $TODO = $url =~ m!^/gbrowse/! ?
'gbrowse not installed on all development machines' : undef;