Bugzilla – Attachment 176577 Details for
Bug 23898
New data to share on HEA
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 23898: Share more data to HEA : test plan
Bug-23898-Share-more-data-to-HEA--test-plan.patch (text/plain), 2.58 KB, created by
Arthur Suzuki
on 2025-01-15 15:41:10 UTC
(
hide
)
Description:
Bug 23898: Share more data to HEA : test plan
Filename:
MIME Type:
Creator:
Arthur Suzuki
Created:
2025-01-15 15:41:10 UTC
Size:
2.58 KB
patch
obsolete
>From 60e4ef9accad7ae99505bdb9b387c3f5177d678e Mon Sep 17 00:00:00 2001 >From: Arthur Suzuki <arthur.suzuki@biblibre.com> >Date: Wed, 15 Jan 2025 16:17:19 +0100 >Subject: [PATCH] Bug 23898: Share more data to HEA : test plan > >It would be nice to get more data about which functionnality are used >or not. >This could be achieved with sharing some systempreferences. >However some of the systempreferences may hold some private >information. >This patch propose a way to share some syspref usage without sharing >their values. > >Test plan : >- apply test patch >- prove t/db_dependent/UsageStats.t -> fail >- apply code patch >- prove t/db_dependent/UsageStats.t -> green > >Once this patch is applied to a production environment with HEA >enabled, more systempreferences will be shared but those which values >are meant to be private will only send "Empty" or "Used" value instead >of the actual value. >This will help the community find out about unused or rarely used >functionnality and debug some specific systempreference combinations >which may cause an issue. > >(this commit holds the tests) >--- > t/db_dependent/UsageStats.t | 5 ++++- > 1 file changed, 4 insertions(+), 1 deletion(-) > >diff --git a/t/db_dependent/UsageStats.t b/t/db_dependent/UsageStats.t >index 90bd7e10780..13e4685b87e 100755 >--- a/t/db_dependent/UsageStats.t >+++ b/t/db_dependent/UsageStats.t >@@ -68,7 +68,7 @@ subtest 'NeedUpdate() tests' => sub { > > subtest 'BuildReport() tests' => sub { > >- plan tests => 30; >+ plan tests => 32; > > $schema->storage->txn_begin; > >@@ -108,6 +108,7 @@ subtest 'BuildReport() tests' => sub { > t::lib::Mocks::mock_preference( "UsageStatsCountry", 'COUNTRY' ); > t::lib::Mocks::mock_preference( "UsageStatsLibrariesInfo", 1 ); > t::lib::Mocks::mock_preference( "UsageStatsGeolocation", 1 ); >+ t::lib::Mocks::mock_preference( "IntranetUserJS", 'This is some javascript' ); > > $report = C4::UsageStats->BuildReport(); > >@@ -121,6 +122,8 @@ subtest 'BuildReport() tests' => sub { > is( $report->{installation}->{country}, 'COUNTRY', "UsageStatsCountry is good" ); > is( $report->{installation}->{geolocation}, '1', "UsageStatsGeolocation is good" ); > ok( exists $report->{systempreferences}, 'systempreferences is present' ); >+ is( $report->{systempreferences}->{IntranetUserJS}, 'Used', "IntranetUserJS is good" ); >+ is( $report->{systempreferences}->{IntranetUserCSS}, 'Empty', "IntranetUserCSS is good" ); > > isa_ok( $report, 'HASH', '$report is a HASH' ); > isa_ok( $report->{volumetry}, 'HASH', '$report->{volumetry} is a HASH' ); >-- >2.39.5
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 23898
: 176577 |
176578