Bugzilla – Attachment 185662 Details for
Bug 39345
Koha must support COUNTER 5.1
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 39345: (QA follow-up): Fix data provider tests
Bug-39345-QA-follow-up-Fix-data-provider-tests.patch (text/plain), 3.29 KB, created by
Eric Phetteplace
on 2025-08-21 19:46:30 UTC
(
hide
)
Description:
Bug 39345: (QA follow-up): Fix data provider tests
Filename:
MIME Type:
Creator:
Eric Phetteplace
Created:
2025-08-21 19:46:30 UTC
Size:
3.29 KB
patch
obsolete
>From e93e9075eaf003b008d2d20d0e1204e6802bf559 Mon Sep 17 00:00:00 2001 >From: Pedro Amorim <pedro.amorim@openfifth.co.uk> >Date: Thu, 21 Aug 2025 08:21:11 +0000 >Subject: [PATCH] Bug 39345: (QA follow-up): Fix data provider tests > >Update original tests to consider COUNTER 5 specifically. >Add new test for COUNTER 5.1. > >Signed-off-by: Eric Phetteplace <phette23@gmail.com> >--- > .../Koha/ERM/EUsage/UsageDataProvider.t | 41 +++++++++++++++++-- > 1 file changed, 37 insertions(+), 4 deletions(-) > >diff --git a/t/db_dependent/Koha/ERM/EUsage/UsageDataProvider.t b/t/db_dependent/Koha/ERM/EUsage/UsageDataProvider.t >index 7bee25b881..b95c50d5ef 100755 >--- a/t/db_dependent/Koha/ERM/EUsage/UsageDataProvider.t >+++ b/t/db_dependent/Koha/ERM/EUsage/UsageDataProvider.t >@@ -32,7 +32,7 @@ my $builder = t::lib::TestBuilder->new; > > subtest '_build_url_query' => sub { > >- plan tests => 2; >+ plan tests => 3; > > $schema->storage->txn_begin; > >@@ -47,7 +47,7 @@ subtest '_build_url_query' => sub { > class => 'Koha::ERM::EUsage::UsageDataProviders', > value => { > service_url => $service_url, api_key => $api_key, requestor_id => $requestor_id, >- customer_id => $customer_id, name => $name, service_platform => undef >+ customer_id => $customer_id, name => $name, service_platform => undef, report_release => 5 > } > } > ); >@@ -79,8 +79,8 @@ subtest '_build_url_query' => sub { > { > class => 'Koha::ERM::EUsage::UsageDataProviders', > value => { >- service_url => $service_url, api_key => $api_key, requestor_id => $requestor_id, >- customer_id => $customer_id, name => $name, service_platform => $test_platform >+ service_url => $service_url, api_key => $api_key, requestor_id => $requestor_id, >+ customer_id => $customer_id, name => $name, service_platform => $test_platform, report_release => 5 > } > } > ); >@@ -108,6 +108,39 @@ subtest '_build_url_query' => sub { > . $test_platform > ); > >+ my $usage_data_provider_51 = $builder->build_object( >+ { >+ class => 'Koha::ERM::EUsage::UsageDataProviders', >+ value => { >+ service_url => $service_url, api_key => $api_key, requestor_id => $requestor_id, >+ customer_id => $customer_id, name => $name, service_platform => $test_platform, report_release => '5.1' >+ } >+ } >+ ); >+ >+ $usage_data_provider_51->{report_type} = 'TR_J1'; >+ $usage_data_provider_51->{begin_date} = '2023-08-01'; >+ $usage_data_provider_51->{end_date} = '2023-09-30'; >+ >+ is( >+ $usage_data_provider_51->_build_url_query, >+ $service_url >+ . '/r51/reports/' >+ . lc( $usage_data_provider->{report_type} ) >+ . '?customer_id=' >+ . $customer_id >+ . '&requestor_id=' >+ . $requestor_id >+ . '&api_key=' >+ . $api_key >+ . '&begin_date=' >+ . substr( $usage_data_provider->{begin_date}, 0, 7 ) >+ . '&end_date=' >+ . substr( $usage_data_provider->{end_date}, 0, 7 ) >+ . '&platform=' >+ . $test_platform >+ ); >+ > $schema->storage->txn_rollback; > > }; >-- >2.51.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 39345
:
185593
|
185594
|
185595
|
185596
|
185618
|
185619
|
185620
|
185621
|
185658
|
185659
|
185660
|
185661
|
185662
|
185663
|
185664
|
185922
|
185923
|
185924
|
185925
|
185926
|
185927
|
185928
|
186016
|
186042
|
186043
|
186044
|
186060
|
186061
|
186062
|
186063
|
186064
|
186065
|
186066
|
186067
|
186068