From 03c62558385c0c7772680ea61b44b53e50a984c8 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Thu, 7 Mar 2019 09:14:06 -0300 Subject: [PATCH] Bug 22472: Add tests Signed-off-by: Katrin Fischer --- t/db_dependent/Installer.t | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/t/db_dependent/Installer.t b/t/db_dependent/Installer.t index 0b4cfa2d5b..636af43618 100644 --- a/t/db_dependent/Installer.t +++ b/t/db_dependent/Installer.t @@ -22,7 +22,7 @@ # Add more tests here!!! use Modern::Perl; -use Test::More tests => 15; +use Test::More tests => 16; use Koha::Database; BEGIN { @@ -56,7 +56,11 @@ my @column_names = $source->columns(); my $column_name = $column_names[0]; ok( column_exists( 'borrowers', $column_name ), 'Known column does exist' ); ok( ! column_exists( 'borrowers', 'xxx'), 'Column xxx does not exist' ); - +{ + my $dbh = C4::Context->dbh; + $dbh->{RaiseError} = 1; + ok( ! column_exists( 'this_table_will_never_exist', 'xxx'), 'Column xxx does not exist, the table does not exist' ); +} my @constraint_names = $source->unique_constraint_names(); my $constraint_name = $constraint_names[0]; ok( index_exists( 'borrowers', $constraint_name), 'Known contraint does exist' ); -- 2.11.0