Bugzilla – Attachment 138460 Details for
Bug 29579
Show saved SQL report ID in database query
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 29579: (QA follow-up) Fix up t/db_dependent/Koha/Reports.t
Bug-29579-QA-follow-up-Fix-up-tdbdependentKohaRepo.patch (text/plain), 2.20 KB, created by
Kyle M Hall (khall)
on 2022-08-01 12:29:09 UTC
(
hide
)
Description:
Bug 29579: (QA follow-up) Fix up t/db_dependent/Koha/Reports.t
Filename:
MIME Type:
Creator:
Kyle M Hall (khall)
Created:
2022-08-01 12:29:09 UTC
Size:
2.20 KB
patch
obsolete
>From 13f1a9c98dcb003b4301a4b576e592e6fe4659fa Mon Sep 17 00:00:00 2001 >From: Kyle M Hall <kyle@bywatersolutions.com> >Date: Mon, 1 Aug 2022 12:28:20 +0000 >Subject: [PATCH] Bug 29579: (QA follow-up) Fix up > t/db_dependent/Koha/Reports.t > >--- > t/db_dependent/Koha/Reports.t | 7 ++++--- > 1 file changed, 4 insertions(+), 3 deletions(-) > >diff --git a/t/db_dependent/Koha/Reports.t b/t/db_dependent/Koha/Reports.t >index e580c12d5db..2b0e6300399 100755 >--- a/t/db_dependent/Koha/Reports.t >+++ b/t/db_dependent/Koha/Reports.t >@@ -55,17 +55,18 @@ subtest 'prep_report' => sub { > report_name => 'report_name_for_test_1', > savedsql => 'SELECT * FROM items WHERE itemnumber IN <<Test|list>>', > })->store; >+ my $id = $report->id; > > my ($sql, undef) = $report->prep_report( ['Test|list'],["1\n12\n\r243"] ); >- is( $sql, q{SELECT * FROM items WHERE itemnumber IN ('1','12','243')},'Expected sql generated correctly with single param and name'); >+ is( $sql, qq{SELECT * FROM items WHERE itemnumber IN ('1','12','243') /* saved_sql.id: $id */},'Expected sql generated correctly with single param and name'); > > $report->savedsql('SELECT * FROM items WHERE itemnumber IN <<Test|list>> AND <<Another>> AND <<Test|list>>')->store; > > ($sql, undef) = $report->prep_report( ['Test|list','Another'],["1\n12\n\r243",'the other'] ); >- is( $sql, q{SELECT * FROM items WHERE itemnumber IN ('1','12','243') AND 'the other' AND ('1','12','243')},'Expected sql generated correctly with multiple params and names'); >+ is( $sql, qq{SELECT * FROM items WHERE itemnumber IN ('1','12','243') AND 'the other' AND ('1','12','243') /* saved_sql.id: $id */},'Expected sql generated correctly with multiple params and names'); > > ($sql, undef) = $report->prep_report( [],["1\n12\n\r243",'the other',"42\n32\n22\n12"] ); >- is( $sql, q{SELECT * FROM items WHERE itemnumber IN ('1','12','243') AND 'the other' AND ('42','32','22','12')},'Expected sql generated correctly with multiple params and no names'); >+ is( $sql, qq{SELECT * FROM items WHERE itemnumber IN ('1','12','243') AND 'the other' AND ('42','32','22','12') /* saved_sql.id: $id */},'Expected sql generated correctly with multiple params and no names'); > > }; > >-- >2.30.2
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 29579
:
128037
|
130496
|
130538
|
137989
|
137990
|
138068
|
138460
|
138466
|
138467