diff options
author | Patrick Webster <noxwizard@phpbb.com> | 2013-11-03 21:58:05 -0600 |
---|---|---|
committer | Joas Schilling <nickvergessen@gmx.de> | 2014-05-02 15:45:20 +0200 |
commit | b39b0369aa0ac6853bde0504259166f570beb983 (patch) | |
tree | 5bc685f9ba2fc59a54cc2fb3d61440052f44dbb8 /tests/test_framework/phpbb_test_case_helpers.php | |
parent | d52c2d1b5caf1382d178e55eff311ceddf4b392f (diff) | |
download | forums-b39b0369aa0ac6853bde0504259166f570beb983.tar forums-b39b0369aa0ac6853bde0504259166f570beb983.tar.gz forums-b39b0369aa0ac6853bde0504259166f570beb983.tar.bz2 forums-b39b0369aa0ac6853bde0504259166f570beb983.tar.xz forums-b39b0369aa0ac6853bde0504259166f570beb983.zip |
[feature/sqlite3] Add support for SQLite 3
Minimum version requirement is 3.6.15 as that's what ships with PHP 5.3.0
when support for SQLite 3 was added.
PHPBB3-9728
Diffstat (limited to 'tests/test_framework/phpbb_test_case_helpers.php')
-rw-r--r-- | tests/test_framework/phpbb_test_case_helpers.php | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/test_framework/phpbb_test_case_helpers.php b/tests/test_framework/phpbb_test_case_helpers.php index 2f225fe7af..0a1037c884 100644 --- a/tests/test_framework/phpbb_test_case_helpers.php +++ b/tests/test_framework/phpbb_test_case_helpers.php @@ -116,6 +116,18 @@ class phpbb_test_case_helpers )); } + if (extension_loaded('sqlite3') && version_compare(PHP_VERSION, '5.4.0', '>=') && version_compare(PHPUnit_Runner_Version::id(), '3.4.15', '>=')) + { + $config = array_merge($config, array( + 'dbms' => 'phpbb\db\driver\sqlite3', + 'dbhost' => dirname(__FILE__) . '/../phpbb_unit_tests.sqlite3', // filename + 'dbport' => '', + 'dbname' => '', + 'dbuser' => '', + 'dbpasswd' => '', + )); + } + if (isset($_SERVER['PHPBB_TEST_CONFIG'])) { // Could be an absolute path |