From 2c0bb8f579825fc970e900bb7dc1667c1bc34c46 Mon Sep 17 00:00:00 2001 From: Tomas Cohen Arazi Date: Fri, 26 Dec 2014 20:52:54 -0300 Subject: [PATCH 09/14] Bug 13264: (QA followup) prevent double-encoding on the tests Signed-off-by: Tomas Cohen Arazi --- t/db_dependent/www/search_utf8.t | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/t/db_dependent/www/search_utf8.t b/t/db_dependent/www/search_utf8.t index 01f5f2a..5e118ce 100644 --- a/t/db_dependent/www/search_utf8.t +++ b/t/db_dependent/www/search_utf8.t @@ -209,12 +209,12 @@ like( $intra_text, qr|Publisher: $publisher|, ); $agent->get_ok( "$intranet/cgi-bin/koha/catalogue/search.pl" , "got search on intranet"); $agent->form_number(1); $agent->field('idx', 'kw'); -$agent->field('q', Encode::encode('UTF-8', $publisher)); +$agent->field('q', $publisher); $agent->click(); $intra_text = $agent->text(); like( $intra_text, qr|Publisher: $publisher|, ); -my $expected_base = q|search.pl\?idx=kw&q=| . uri_escape_utf8( Encode::encode('UTF-8', $publisher ) ); +my $expected_base = q|search.pl\?idx=kw&q=| . uri_escape_utf8( $publisher ); $agent->base_like(qr|$expected_base|, ); ok ( ( length(Encode::encode('UTF-8', $intra_text)) != length($intra_text) ) , 'UTF-8 are multi-byte. Goog') ; @@ -237,7 +237,7 @@ $agent->click(); $opac_text = $agent->text(); like( $opac_text, qr|Publisher: $publisher|, ); -$expected_base = q|opac-search.pl\?q=| . uri_escape_utf8( $publisher ); +$expected_base = q|opac-search.pl\?idx=&q=| . uri_escape_utf8( $publisher ); $agent->base_like(qr|$expected_base|, ); ok ( ( length(Encode::encode('UTF-8', $opac_text)) != length($opac_text) ) , 'UTF-8 are multi-byte. Goog') ; -- 1.7.10.4