[Koha-bugs] [Bug 15323] ./t/Prices.t fails without a valid database

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Tue Mar 29 16:47:35 CEST 2016


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15323

Colin Campbell <colin.campbell at ptfs-europe.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |colin.campbell at ptfs-europe.
                   |                            |com

--- Comment #6 from Colin Campbell <colin.campbell at ptfs-europe.com> ---
On current master running prove t/Prices.t with the database up or down I get:

~/kohaclone$ prove t/Prices.t
t/Prices.t .. 1/16 DBIx::Class::Storage::DBI::_warn_undetermined_driver(): This
version of DBIC does not yet seem to supply a driver for your particular RDBMS
and/or connection method ('Mock'). While we will attempt to continue anyway,
the results are likely to be underwhelming. Please upgrade DBIC, and if this
message does not go away, file a bugreport including the following info:
{
  DBD => "DBD::Mock",
  DBD_VER => "1.45",
  DBIC_DRIVER => "DBIx::Class::Storage::DBI",
  DBIC_DSN => "DBI:Mock:",
  DBIC_VER => "0.082820",
  DBI_VER => "1.633"
}
DBIx::Class::Storage::DBI::sql_maker(): Your storage class
(DBIx::Class::Storage::DBI) does not set sql_limit_dialect and you have not
supplied an explicit limit_dialect in your connection_info. DBIC will attempt
to use the GenericSubQ dialect, which works on most databases but can be (and
often is) painfully slow. Please file an RT ticket against
'DBIx::Class::Storage::DBI' at /home/cc/kohaclone/Koha/Objects.pm line 150
DBI bind_columns: invalid number of arguments: got handle + 0, expected handle
+ between 1 and -1
Usage: $h->bind_columns(\$var1 [, \$var2, ...]) at
/usr/share/perl5/vendor_perl/DBIx/Class/Storage/DBI/Cursor.pm line 129.
    # Child (Configuration 1: 0 0) exited without calling finalize()

#   Failed test 'Configuration 1: 0 0'
#   at /usr/share/perl5/vendor_perl/Test/Builder.pm line 279.
# Looks like you planned 16 tests but ran 5.
# Looks like you failed 1 test of 5 run.
# Looks like your test exited with 255 just after 5.
t/Prices.t .. Dubious, test returned 255 (wstat 65280, 0xff00)
Failed 12/16 subtests 

Test Summary Report
-------------------
t/Prices.t (Wstat: 65280 Tests: 5 Failed: 1)
  Failed test:  5
  Non-zero exit status: 255
  Parse errors: Bad plan.  You planned 16 tests but ran 5.
Files=1, Tests=5,  1 wallclock secs ( 0.02 usr  0.00 sys +  1.15 cusr  0.06
csys =  1.23 CPU)

(Perl version 5.22.1)

However if I remove the line:

    my $context_module = t::lib::Mocks::mock_dbh;

all tests pass (if DB up)

looks like the mocking is broken in some versions of the libs

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list