Bugzilla – Attachment 69618 Details for
Bug 19775
Search/History.t is failing randomly
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 19775: Try & prevent Search/History.t to fail randomly
Bug-19775-Try--prevent-SearchHistoryt-to-fail-rand.patch (text/plain), 2.15 KB, created by
Jonathan Druart
on 2017-12-07 16:42:19 UTC
(
hide
)
Description:
Bug 19775: Try & prevent Search/History.t to fail randomly
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2017-12-07 16:42:19 UTC
Size:
2.15 KB
patch
obsolete
>From 857fd1f7924c4d5d42cb7d6318a458c82b5f6152 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Thu, 7 Dec 2017 13:41:06 -0300 >Subject: [PATCH] Bug 19775: Try & prevent Search/History.t to fail randomly > > # Failed test 'There are still 8 searches after calling delete with an interval = 6 days' > # at t/db_dependent/Search/History.t line 185. > # got: '6' > # expected: '8' > > # Failed test 'There are still 2 searches after calling delete with an interval = 2 days' > # at t/db_dependent/Search/History.t line 191. > # got: '0' > # expected: '2' > # Looks like you failed 2 tests of 27. >[15:04:12] t/db_dependent/Search/History.t > >It looks like it does not longer fail with this change (date comparaison wrongly rounded to second in mysql?) >--- > t/db_dependent/Search/History.t | 8 ++++---- > 1 file changed, 4 insertions(+), 4 deletions(-) > >diff --git a/t/db_dependent/Search/History.t b/t/db_dependent/Search/History.t >index fc7f0634eb..92b3f4f204 100644 >--- a/t/db_dependent/Search/History.t >+++ b/t/db_dependent/Search/History.t >@@ -233,10 +233,10 @@ delete_all( $userid ); > sub add { > my ( $userid, $current_session_id, $previous_sessionid, $total, $query_cgi_b, $query_cgi_a ) = @_; > >- my $days_ago_2 = dt_from_string()->add_duration( DateTime::Duration->new( days => -2 ) ); >- my $days_ago_4 = dt_from_string()->add_duration( DateTime::Duration->new( days => -4 ) ); >- my $days_ago_6 = dt_from_string()->add_duration( DateTime::Duration->new( days => -6 ) ); >- my $days_ago_8 = dt_from_string()->add_duration( DateTime::Duration->new( days => -8 ) ); >+ my $days_ago_2 = dt_from_string()->add_duration( DateTime::Duration->new( days => -2, minutes => 1 ) ); >+ my $days_ago_4 = dt_from_string()->add_duration( DateTime::Duration->new( days => -4, minutes => 1 ) ); >+ my $days_ago_6 = dt_from_string()->add_duration( DateTime::Duration->new( days => -6, minutes => 1 ) ); >+ my $days_ago_8 = dt_from_string()->add_duration( DateTime::Duration->new( days => -8, minutes => 1 ) ); > > my $query_desc_b1_p = q{first previous biblio search}; > my $first_previous_biblio_search = { >-- >2.11.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 19775
: 69618