[Bug 21618] New: side-effects with timestamp columns with Test::DBIx::Class
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21618 Bug ID: 21618 Summary: side-effects with timestamp columns with Test::DBIx::Class Change sponsored?: --- Product: Koha Version: unspecified Hardware: All OS: All Status: NEW Severity: major Priority: P5 - low Component: Test Suite Assignee: chris@bigballofwax.co.nz Reporter: jonathan.druart@bugs.koha-community.org QA Contact: testopia@bugs.koha-community.org Since commit 5024cb3acffdfb9f67dce5587eb062ea3130bdbb Bug 21596: Handle empty string for other attributes when storing a patron There is a failure from t/Auth_with_shibboleth.t: DBI Exception: DBD::SQLite::st execute failed: NOT NULL constraint failed: borrowers.updated_on -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21618 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |21596 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21596 [Bug 21596] Handle default values when storing Koha::Patron -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21618 --- Comment #1 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- I have isolated the issue with this code. I do not understand why the default value (CURRENT_TIMESTAMP) is not picked. #!/usr/bin/perl use Modern::Perl; use Test::MockModule; use Koha::Patrons; use Koha::Patron::Categories; use Test::DBIx::Class { schema_class => 'Koha::Schema', connect_info => [ 'dbi:SQLite:dbname=:memory:', '', '' ] }; my $database = Test::MockModule->new('Koha::Database'); $database->mock( _new_schema => sub { return Schema(); } ); Koha::Patron::Category->new({categorycode => 'S'})->store; my $borrower = { categorycode => 'S', userid => 'test4321', }; my $patron = Koha::Patron->new( $borrower )->store; -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21618 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |DUPLICATE Status|NEW |RESOLVED --- Comment #2 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Fixed by Marcel's patch on bug 21610 comment 10 *** This bug has been marked as a duplicate of bug 21610 *** -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21618 Bug 21618 depends on bug 21596, which changed state. Bug 21596 Summary: Handle default values when storing Koha::Patron https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21596 What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to Master |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org