Bug 22368: Make sure the tests will always pass
[koha.git] / t / Koha.t
index e617146..b8d4346 100755 (executable)
--- a/t/Koha.t
+++ b/t/Koha.t
@@ -33,12 +33,7 @@ BEGIN {
 
 use_ok('C4::Koha');
 
-use Test::DBIx::Class {
-    schema_class => 'Koha::Schema',
-    connect_info => ['dbi:SQLite:dbname=:memory:','',''],
-    connect_opts => { name_sep => '.', quote_char => '`', },
-    fixture_class => '::Populate',
-}, 'Branch' ;
+use Test::DBIx::Class;
 
 sub fixtures {
     my ( $libraries ) = @_;
@@ -52,6 +47,7 @@ sub fixtures {
 
 my $db = Test::MockModule->new('Koha::Database');
 $db->mock( _new_schema => sub { return Schema(); } );
+Koha::Database::flush_schema_cache();
 
 my $libraries = [
     ['XXX_test', 'my branchname XXX'],
@@ -155,4 +151,3 @@ ok($@ eq '', 'NormalizeISSN does not throw exception when parsing invalid ISSN')
 is($issns[0], 'abc', 'Original ISSN passed through even if invalid');
 is(scalar(@issns), 1, 'zero additional variations returned of invalid ISSN');
 
-1;