Files
xamxam/tests/bootstrap.php

21 lines
538 B
PHP

<?php
/**
* PHPUnit bootstrap for XAMXAM.
*
* Sets up autoloading, constants, and any environment needed before tests run.
* Uses the production app/.env for APP_KEY (Crypto tests need a real key).
*/
// Composer autoloader
require_once __DIR__ . '/../vendor/autoload.php';
// Define application root (points to app/)
define('APP_ROOT', realpath(__DIR__ . '/../app'));
// Storage directory for tests — use app/storage/
define('STORAGE_ROOT', APP_ROOT . '/storage');
// Test helpers
require_once __DIR__ . '/TestDatabase.php';