From 7f8d9bcb5314b54ae2d476c5009cff5ec672dd33 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Wed, 19 Aug 2020 14:50:23 +0200 Subject: [PATCH] Bug 25641: [19.11.x] Fix XSLT_Handler.t failures on U20 --- t/db_dependent/XSLT_Handler.t | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/t/db_dependent/XSLT_Handler.t b/t/db_dependent/XSLT_Handler.t index 349d637551..857154aa1f 100644 --- a/t/db_dependent/XSLT_Handler.t +++ b/t/db_dependent/XSLT_Handler.t @@ -63,7 +63,7 @@ is( $engine->err, Koha::XSLT_Handler::XSLTH_ERR_5, 'Engine returns error on non- # Malformed XML tests warning_like { $output = $engine->transform( '', $xsltfile_1 ) } - qr{parser error : Opening and ending tag mismatch: a line 1 and b}, + qr{parser error : Opening and ending tag mismatch: a line (0|1) and b}, "Malformed XML warning correctly displayed"; is( $engine->err, Koha::XSLT_Handler::XSLTH_ERR_5, 'Engine returns error on malformed xml' ); @@ -75,18 +75,18 @@ my $secondengine=Koha::XSLT_Handler->new( { }); $engine->do_not_return_source(1); warning_like { $output = $engine->transform( '', $xsltfile_1 ) } - qr{parser error : Opening and ending tag mismatch: a line 1 and b}, + qr{parser error : Opening and ending tag mismatch: a line (0|1) and b}, "Malformed XML warning correctly displayed"; is( defined $output? 1: 0, 0, 'Engine respects do_not_return_source==1'); $secondengine->print_warns(1); warning_like { $output = $secondengine->transform( '', $xsltfile_1 ) } - qr{parser error : Opening and ending tag mismatch: a line 1 and b}, + qr{parser error : Opening and ending tag mismatch: a line (0|1) and b}, "Malformed XML warning correctly displayed"; is( defined $output? 1: 0, 0, 'Second engine respects it too'); undef $secondengine; #bye $engine->do_not_return_source(0); warning_like { $output = $engine->transform( '', $xsltfile_1 ) } - qr{parser error : Opening and ending tag mismatch: a line 1 and b}, + qr{parser error : Opening and ending tag mismatch: a line (0|1) and b}, "Malformed XML warning correctly displayed"; is( defined $output? 1: 0, 1, 'Engine respects do_not_return_source==0'); -- 2.20.1