7 |
|
|
8 |
BEGIN { |
BEGIN { |
9 |
use_ok('Frey::Test'); |
use_ok('Frey::Test'); |
10 |
|
use_ok('Test::WWW::Mechanize'); |
11 |
} |
} |
12 |
|
|
|
eval "use Test::WWW::Mechanize"; |
|
|
if($@) { |
|
|
plan skip_all => 'Test::WWW::Mechanize not installed'; |
|
|
exit; |
|
|
} |
|
13 |
|
|
14 |
ok( my $kid_out = Frey::Test->start_server, 'start_server' ); |
ok( my $url = Frey::Test->start_server, 'start_server' ); |
15 |
ok( my $server = Frey::Test->get_server( $kid_out ), 'get_server' ); |
diag $url; |
16 |
|
|
17 |
my $mech = Test::WWW::Mechanize->new; |
my $mech = Test::WWW::Mechanize->new; |
18 |
$mech->get_ok( $server ); |
$mech->get_ok( $url ); |
19 |
|
|
20 |
$mech->content_contains("Frey"); |
$mech->content_contains("Frey"); |
21 |
|
|
22 |
$mech->get_ok( '/ob/Strix::User' ); |
$mech->get_ok( '/ob/Strix::User' ); |
23 |
$mech->content_contains("Email"); |
$mech->content_contains("results"); |
24 |
|
|
25 |
$mech->get_ok( '/~/Frey::Introspect' ); |
$mech->get_ok( '/~/Frey::Introspect' ); |
26 |
$mech->content_contains("introspect.css"); |
$mech->content_contains("introspect.css"); |