Add the original source packages to maemo, source lenny
[dh-make-perl] / dev / i386 / libwww-mechanize-perl / libwww-mechanize-perl-1.34 / t / find_frame.t
1 #!perl -Tw
2
3 use warnings;
4 use strict;
5 use Test::More tests => 5;
6 use URI::file;
7
8 BEGIN {
9     delete @ENV{qw(PATH IFS CDPATH ENV BASH_ENV)};  # Placates taint-unsafe Cwd.pm in 5.6.1
10     use_ok( 'WWW::Mechanize' );
11 }
12
13 my $mech = WWW::Mechanize->new( cookie_jar => undef );
14 isa_ok( $mech, 'WWW::Mechanize' );
15
16 my $uri = URI::file->new_abs( 't/find_frame.html' )->as_string;
17
18 $mech->get( $uri );
19 ok( $mech->success, "Fetched $uri" ) or die q{Can't get test page};
20
21 my $x;
22 $x = $mech->find_link();
23 isa_ok( $x, 'WWW::Mechanize::Link' );
24 is( $x->url, 'bastro.html', 'First link sequentially' );