use warnings;
use strict;
-use Test::More tests => 3;
+use Test::More tests => 4;
use Test::WWW::Mechanize;
use File::Slurp;
my $mech = Test::WWW::Mechanize->new;
my $save_count = 1;
-sub save { write_file "/tmp/login-$save_count.html", @_; $save_count++; }
+sub save {
+ my $path = '/tmp/login-' . $save_count++ . '.html';
+ write_file $path, @_;
+ warn "# save $path ", -s $path, " bytes\n";
+}
$mech->get_ok( 'https://localhost', 'opac' );
}, 'login');
save $mech->content;
+$mech->follow_link_ok({ url_regex => qr/logout/ }, 'logout' );