diff options
author | ivan <ivan> | 2004-03-11 02:05:38 +0000 |
---|---|---|
committer | ivan <ivan> | 2004-03-11 02:05:38 +0000 |
commit | eb9668a6f3181ee02cb335272c5ee4616e61fd09 (patch) | |
tree | f5a22d9141723fd9e2fdb40430e4a38743b72604 /rt/lib/t/03web.pl | |
parent | 25953817e61fd252c18241699c0b6cdc3fa54121 (diff) | |
parent | 289340780927b5bac2c7604d7317c3063c6dd8cc (diff) |
This commit was generated by cvs2svn to compensate for changes in r3241,
which included commits to RCS files with non-trunk default branches.
Diffstat (limited to 'rt/lib/t/03web.pl')
-rw-r--r-- | rt/lib/t/03web.pl | 34 |
1 files changed, 33 insertions, 1 deletions
diff --git a/rt/lib/t/03web.pl b/rt/lib/t/03web.pl index 4500ff281..94ad3e97e 100644 --- a/rt/lib/t/03web.pl +++ b/rt/lib/t/03web.pl @@ -5,6 +5,7 @@ use WWW::Mechanize; use HTTP::Request::Common; use HTTP::Cookies; use LWP; +use Encode; my $cookie_jar = HTTP::Cookies->new; my $agent = WWW::Mechanize->new(); @@ -15,7 +16,7 @@ $agent->cookie_jar($cookie_jar); # get the top page -my $url = "http://localhost/"; +my $url = "http://localhost".$RT::WebPath."/"; $agent->get($url); is ($agent->{'status'}, 200, "Loaded a page"); @@ -37,6 +38,37 @@ is($agent->{'status'}, 200, "Fetched the page ok"); ok( $agent->{'content'} =~ /Logout/i, "Found a logout link"); + +$agent->get($url."Ticket/Create.html?Queue=1"); +is ($agent->{'status'}, 200, "Loaded Create.html"); +$agent->form(3); +# Start with a string containing characters in latin1 +my $string = "I18N Web Testing זרו"; +Encode::from_to($string, 'iso-8859-1', 'utf8'); +$agent->field('Subject' => "Foo"); +$agent->field('Content' => $string); +ok($agent->submit(), "Created new ticket with $string"); + +ok( $agent->{'content'} =~ qr{$string} , "Found the content"); + +$agent->get($url."Ticket/Create.html?Queue=1"); +is ($agent->{'status'}, 200, "Loaded Create.html"); +$agent->form(3); +# Start with a string containing characters in latin1 +my $string = "I18N Web Testing זרו"; +Encode::from_to($string, 'iso-8859-1', 'utf8'); +$agent->field('Subject' => $string); +$agent->field('Content' => "BAR"); +ok($agent->submit(), "Created new ticket with $string"); + +ok( $agent->{'content'} =~ qr{$string} , "Found the content"); + + + +# }}} + + + use File::Find; find ( \&wanted , 'html/'); |