Compare commits

...

4 Commits

Author SHA1 Message Date
Joonas Kylmälä 92dce6465e Bug 29381: Prevent sending of automatic renewal messages on every cron run 2 years ago
Jonathan Druart ee76f80a7b Bug 29524: (bug 28935 follow-up) Restore modification of some patron's attributes 2 years ago
Jonathan Druart 53956232f9 Bug 29565: Prevent regressions.t to fail on slow boxes 2 years ago
Jonathan Druart 65edbe5af2 Bug 29485: (follow-up) Trying to prevent administration_tasks.t to fail randomly 2 years ago
  1. 2
      members/memberentry.pl
  2. 6
      misc/cronjobs/automatic_renewals.pl
  3. 10
      t/db_dependent/selenium/administration_tasks.t
  4. 2
      t/lib/Selenium.pm

2
members/memberentry.pl

@ -216,7 +216,7 @@ if ( $op eq 'insert' || $op eq 'modify' || $op eq 'save' || $op eq 'duplicate' )
# remove keys from %newdata that is not part of patron's attributes
{
my @keys_to_delete = (
qr/^(borrowernumber|date_renewed|debarred|debarredcomment|flags|privacy|privacy_guarantor_fines|privacy_guarantor_checkouts|checkprevcheckout|updated_on|lastseen|lang|login_attempts|overdrive_auth_token|anonymized)$/, # Bug 28935
qr/^(borrowernumber|date_renewed|debarred|debarredcomment|flags|privacy|updated_on|lastseen|login_attempts|overdrive_auth_token|anonymized)$/, # Bug 28935
qr/^BorrowerMandatoryField$/,
qr/^category_type$/,
qr/^check_member$/,

6
misc/cronjobs/automatic_renewals.pl

@ -179,15 +179,15 @@ while ( my $auto_renew = $auto_renews->next ) {
}
}
if ( $borrower_preferences && $borrower_preferences->{transports} && $borrower_preferences->{transports}->{email} && $borrower_preferences->{'wants_digest'} ) {
if ( $error ne 'auto_too_soon' && $borrower_preferences && $borrower_preferences->{transports} && $borrower_preferences->{transports}->{email} && $borrower_preferences->{'wants_digest'} ) {
# cache this one to process after we've run through all of the items.
if ($digest_per_branch) {
$renew_digest->{ $auto_renew->branchcode }->{ $auto_renew->borrowernumber }->{success}++ if $error eq 'auto_renew';
$renew_digest->{ $auto_renew->branchcode }->{ $auto_renew->borrowernumber }->{error}++ unless $error eq 'auto_renew' || $error eq 'auto_too_soon' ;
$renew_digest->{ $auto_renew->branchcode }->{ $auto_renew->borrowernumber }->{error}++ unless $error eq 'auto_renew';
push @{$renew_digest->{ $auto_renew->branchcode }->{ $auto_renew->borrowernumber }->{issues}}, $auto_renew->itemnumber;
} else {
$renew_digest->{ $auto_renew->borrowernumber }->{success} ++ if $error eq 'auto_renew';
$renew_digest->{ $auto_renew->borrowernumber }->{error}++ unless $error eq 'auto_renew' || $error eq 'auto_too_soon' ;
$renew_digest->{ $auto_renew->borrowernumber }->{error}++ unless $error eq 'auto_renew';
push @{$renew_digest->{ $auto_renew->borrowernumber }->{issues}}, $auto_renew->itemnumber;
}
}

10
t/db_dependent/selenium/administration_tasks.t

@ -181,14 +181,14 @@ SKIP: {
}
);
$s->driver->accept_alert; # Accept the modal "Are you sure you want to delete this authorized value?"
# For an unknown reason the click on the next admin-home link does not work
# We were still on the authorised value list view.
# A workaround (and dirty fix) is to wait for 1 second and see if it fixes the problem
sleep 1;
};
{ # Patron categories
# For an unknown reason the click on the admin-home link does not work
# At this point we were still on the authorised value list view.
# A workaround (and dirty fix) is to logout/login and see if it fixes the problem
$driver->get( $mainpage . q|?logout.x=1| );
$s->auth;
$driver->get($mainpage);
$s->click( { href => '/admin/admin-home.pl', main => 'container-main' } ); # Koha administration
$s->click( { href => '/admin/categories.pl', main_class => 'main container-fluid' } ); # Patron categories

2
t/lib/Selenium.pm

@ -47,7 +47,7 @@ sub new {
);
bless $self, $class;
$self->add_error_handler;
$self->driver->set_implicit_wait_timeout(5000);
$self->driver->set_implicit_wait_timeout(10000);
return $self;
}

Loading…
Cancel
Save