package LogReportTest; BEGIN { # set test env otherwise development config settings loaded - unless explicitly # set at command-line: "export DANCER_ENVIRONMENT=development; prove -lv t/" $ENV{DANCER_ENVIRONMENT} ||= $ENV{PLACK_ENV} ||= 'test'; } use Import::Into; use Exporter (); use FindBin; # warn $FindBin::Bin; use Data::Printer; open my $fh, '>' . $FindBin::Bin . '/mech.htm' or die $!; sub print_output { my $response = shift; print $fh $response->content; } our @EXPORT = qw(print_output); sub import { Test::WWW::Mechanize->import::into(1); LWP::Protocol::PSGI->import::into(1); Data::Printer->import::into(1); Data::Dumper->import::into(1); Modern::Perl->import::into(1); Test::More->import::into(1); LogReport->import::into(1); goto &Exporter::import; } 1;