You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

_bootstrap.php 615B

8 年之前
12345678910111213141516
  1. <?php
  2. defined('YII_DEBUG') or define('YII_DEBUG', true);
  3. defined('YII_ENV') or define('YII_ENV', 'test');
  4. defined('YII_APP_BASE_PATH') or define('YII_APP_BASE_PATH', dirname(dirname(dirname(__DIR__))));
  5. require_once(YII_APP_BASE_PATH . '/vendor/autoload.php');
  6. require_once(YII_APP_BASE_PATH . '/vendor/yiisoft/yii2/Yii.php');
  7. require_once(YII_APP_BASE_PATH . '/common/config/bootstrap.php');
  8. require_once(YII_APP_BASE_PATH . '/console/config/bootstrap.php');
  9. // set correct script paths
  10. $_SERVER['SERVER_NAME'] = 'localhost';
  11. $_SERVER['SERVER_PORT'] = '80';
  12. Yii::setAlias('@tests', dirname(dirname(__DIR__)));