Bugzilla – Attachment 158873 Details for
Bug 30287
Notices using HTML render differently in notices.pl
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 30287: (follow-up) Make unit test more reliable in ktd
Bug-30287-follow-up-Make-unit-test-more-reliable-i.patch (text/plain), 1.90 KB, created by
Martin Renvoize (ashimema)
on 2023-11-13 10:33:56 UTC
(
hide
)
Description:
Bug 30287: (follow-up) Make unit test more reliable in ktd
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2023-11-13 10:33:56 UTC
Size:
1.90 KB
patch
obsolete
>From 87b71947578c2311b2db216485e4db70348dbfbf Mon Sep 17 00:00:00 2001 >From: Martin Renvoize <martin.renvoize@ptfs-europe.com> >Date: Sat, 11 Nov 2023 11:06:32 +0000 >Subject: [PATCH] Bug 30287: (follow-up) Make unit test more reliable in ktd > >This patch mocks NoticeCSS earlier to ensure we're not inadvertantly >failing due to a local setup in ktd having added to the preference. >--- > t/db_dependent/Koha/Notice/Message.t | 7 +++++-- > 1 file changed, 5 insertions(+), 2 deletions(-) > >diff --git a/t/db_dependent/Koha/Notice/Message.t b/t/db_dependent/Koha/Notice/Message.t >index 27265987fde..72192655f9c 100755 >--- a/t/db_dependent/Koha/Notice/Message.t >+++ b/t/db_dependent/Koha/Notice/Message.t >@@ -72,6 +72,8 @@ subtest 'html_content() tests' => sub { > } > ); > >+ t::lib::Mocks::mock_preference( 'NoticeCSS', '' ); >+ my $css_import = ''; > my $message = Koha::Notice::Messages->find($message_id); > my $wrapped_compare = <<"WRAPPED"; > <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" >@@ -80,7 +82,7 @@ subtest 'html_content() tests' => sub { > <head> > <title>$firstname</title> > <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> >- >+ $css_import > </head> > <body> > This is a test template using borrower $borrowernumber >@@ -92,6 +94,7 @@ WRAPPED > > my $css_sheet = 'https://localhost/shiny.css'; > t::lib::Mocks::mock_preference( 'NoticeCSS', $css_sheet ); >+ $css_import = qq{<link rel="stylesheet" type="text/css" href="$css_sheet">}; > > $wrapped_compare = <<"WRAPPED"; > <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" >@@ -100,7 +103,7 @@ WRAPPED > <head> > <title>$firstname</title> > <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> >- <link rel="stylesheet" type="text/css" href="$css_sheet"> >+ $css_import > </head> > <body> > This is a test template using borrower $borrowernumber >-- >2.41.0
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 30287
:
158517
|
158519
|
158520
|
158648
|
158649
|
158650
|
158651
|
158652
|
158653
|
158654
|
158655
|
158656
|
158834
|
158869
|
158870
|
158871
|
158872
|
158873
|
158892
|
158893
|
158894
|
158895
|
159431
|
159432
|
159433
|
159434