5 use Test::More tests => 5;
8 delete @ENV{qw(PATH IFS CDPATH ENV BASH_ENV)}; # Placates taint-unsafe Cwd.pm in 5.6.1
9 use_ok( 'WWW::Mechanize' );
11 my $mech = WWW::Mechanize->new( cookie_jar => undef );
12 isa_ok( $mech, 'WWW::Mechanize' );
14 my $uri = URI::file->new_abs( 't/tick.html' )->as_string;
16 ok( $mech->success, $uri );
18 $mech->form_number( 1 );
19 $mech->tick('foo','hello');
20 $mech->tick('foo','bye');
21 $mech->untick('foo','hello');
23 my $form = $mech->form_number(1);
24 isa_ok( $form, 'HTML::Form' );
26 my $reqstring = $form->click->as_string;
29 POST http://localhost/
31 Content-Type: application/x-www-form-urlencoded
36 is( $reqstring, $wanted, 'Proper posting' );