From 607ec8ae770cd8dc5c3c34aafd8a6493cfb4e249 Mon Sep 17 00:00:00 2001 From: David Grudl Date: Wed, 4 Nov 2015 15:00:29 +0100 Subject: [PATCH] tests: not supported drivers are not skipped (except for 'mysql' on PHP 7) --- tests/dibi/bootstrap.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/tests/dibi/bootstrap.php b/tests/dibi/bootstrap.php index 4cd87888..7c7840d3 100644 --- a/tests/dibi/bootstrap.php +++ b/tests/dibi/bootstrap.php @@ -35,14 +35,14 @@ if ($config['system'] === 'odbc') { $config['dsn'] = str_replace('data/odbc.mdb', TEMP_DIR . '/odbc.mdb', $config['dsn']); } - -try { - new Dibi\Connection($config); -} catch (Dibi\NotSupportedException $e) { - Tester\Environment::skip($e->getMessage()); +if ($config['driver'] === 'mysql' && PHP_VERSION_ID >= 70000) { + Tester\Environment::skip('mysql driver is not supported on PHP 7'); } +$conn = new Dibi\Connection($config); + + function test(Closure $function) { $function();