functional.php 742 B

12345678910111213141516171819202122232425
  1. <?php
  2. $_SERVER['SCRIPT_FILENAME'] = YII_TEST_ENTRY_FILE;
  3. $_SERVER['SCRIPT_NAME'] = YII_TEST_ENTRY_URL;
  4. /**
  5. * Application configuration for functional tests
  6. */
  7. return yii\helpers\ArrayHelper::merge(
  8. require(__DIR__ . '/../../../config/web.php'),
  9. require(__DIR__ . '/config.php'),
  10. [
  11. 'components' => [
  12. 'request' => [
  13. // it's not recommended to run functional tests with CSRF validation enabled
  14. 'enableCsrfValidation' => false,
  15. // but if you absolutely need it set cookie domain to localhost
  16. /*
  17. 'csrfCookie' => [
  18. 'domain' => 'localhost',
  19. ],
  20. */
  21. ],
  22. ],
  23. ]
  24. );