test: add base TestCase and bootstrap for in-memory SQLite
This commit is contained in:
16
tests/bootstrap.php
Normal file
16
tests/bootstrap.php
Normal file
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
|
||||
// Test bootstrap for the DuckBrain development harness.
|
||||
// Run PHPUnit from the project root (autoload.php resolves config.php via cwd).
|
||||
|
||||
require_once __DIR__ . '/../vendor/autoload.php';
|
||||
|
||||
// Define DB constants BEFORE config.php so the test database wins over the
|
||||
// real configuration (config.php's define() warnings are suppressed by @).
|
||||
define('DB_TYPE', 'sqlite');
|
||||
define('DB_HOST', 'localhost');
|
||||
define('DB_NAME', ':memory:');
|
||||
define('DB_USER', '');
|
||||
define('DB_PASS', '');
|
||||
|
||||
@require_once __DIR__ . '/../autoload.php';
|
||||
Reference in New Issue
Block a user