Bugzilla – Attachment 36591 Details for
Bug 11998
Syspref caching issues
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 11998 - fix test case so it's testing the cache properly
Bug-11998---fix-test-case-so-its-testing-the-cache.patch (text/plain), 1.31 KB, created by
Brendan Gallagher
on 2015-03-05 13:37:42 UTC
(
hide
)
Description:
Bug 11998 - fix test case so it's testing the cache properly
Filename:
MIME Type:
Creator:
Brendan Gallagher
Created:
2015-03-05 13:37:42 UTC
Size:
1.31 KB
patch
obsolete
>From 9dcf084b883a799e0a0aecd09be110cb9b1cff30 Mon Sep 17 00:00:00 2001 >From: Robin Sheat <robin@catalyst.net.nz> >Date: Thu, 20 Nov 2014 15:51:17 +1300 >Subject: [PATCH] Bug 11998 - fix test case so it's testing the cache properly > >Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com> >--- > t/db_dependent/Context.t | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > >diff --git a/t/db_dependent/Context.t b/t/db_dependent/Context.t >index f90fdab..40f6ed1 100755 >--- a/t/db_dependent/Context.t >+++ b/t/db_dependent/Context.t >@@ -53,7 +53,6 @@ $module->mock( > ); > > my $history; >-C4::Context->disable_syspref_cache(); > $dbh = C4::Context->dbh({ new => 1 }); > > $dbh->{mock_add_resultset} = [ ['value'], ['thing1'] ]; >@@ -82,7 +81,8 @@ is(scalar(@{$history}), 1, 'Retrieved syspref from database'); > > C4::Context->enable_syspref_cache(); > $dbh->{mock_clear_history} = 1; >-is(C4::Context->preference("SillyPreference"), 'thing3', "Retrieved syspref (value='thing3') successfully from cache"); >+# This gives us the value that was cached on the first call, when the cache was active. >+is(C4::Context->preference("SillyPreference"), 'thing1', "Retrieved syspref (value='thing1') successfully from cache"); > $history = $dbh->{mock_all_history}; > is(scalar(@{$history}), 0, 'Did not retrieve syspref from database'); > >-- >1.7.10.4
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 11998
:
26575
|
26621
|
26714
|
26716
|
26717
|
27382
|
31801
|
31802
|
32870
|
32871
|
32872
|
32873
|
32874
|
33183
|
33447
|
33670
|
33671
|
33685
|
33724
|
33725
|
33746
|
33829
|
33940
|
36523
|
36524
|
36525
|
36526
|
36527
|
36528
|
36529
|
36530
|
36531
|
36532
|
36533
|
36534
|
36571
|
36583
|
36584
|
36585
|
36586
|
36587
|
36588
|
36589
|
36590
|
36591
|
36592
|
36593
|
36594
|
36595
|
48640
|
48652
|
48655
|
48687
|
48688
|
48727
|
48758
|
48928
|
48929
|
48930
|
48931
|
48932
|
48933
|
48934
|
48935
|
48936
|
48961
|
49022
|
49023
|
49024
|
49025
|
49026
|
49027
|
49028
|
49029
|
49030
|
49100
|
49101
|
49102
|
49103
|
49104
|
49105
|
49106
|
49107
|
49108