Skip to content

Commit

Permalink
Merge pull request #561 from cakephp/plugin-test-boostrap
Browse files Browse the repository at this point in the history
Fix plugin bootstrap setup
  • Loading branch information
markstory committed Jun 20, 2019
2 parents 2d38ca4 + 711c7fc commit 437f416
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 6 deletions.
9 changes: 7 additions & 2 deletions src/Template/Bake/Plugin/tests/bootstrap.php.twig
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,16 @@ unset($findRoot);
chdir($root);
require_once $root . '/vendor/autoload.php';
require_once $root . '/vendor/cakephp/cakephp/src/basics.php';
/**
* Define fallback values for required constants and configuration.
* To customize constants and configuration remove this require
* and define the data required by your plugin here.
*/
require_once $root . '/vendor/cakephp/cakephp/tests/bootstrap.php';
if (file_exists($root . '/config/bootstrap.php')) {
require $root . '/config/bootstrap.php';
return;
}
require $root . '/vendor/cakephp/cakephp/tests/bootstrap.php';
9 changes: 7 additions & 2 deletions tests/comparisons/Plugin/Company/Example/tests/bootstrap.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,16 @@
chdir($root);

require_once $root . '/vendor/autoload.php';
require_once $root . '/vendor/cakephp/cakephp/src/basics.php';

/**
* Define fallback values for required constants and configuration.
* To customize constants and configuration remove this require
* and define the data required by your plugin here.
*/
require_once $root . '/vendor/cakephp/cakephp/tests/bootstrap.php';

if (file_exists($root . '/config/bootstrap.php')) {
require $root . '/config/bootstrap.php';

return;
}
require $root . '/vendor/cakephp/cakephp/tests/bootstrap.php';
9 changes: 7 additions & 2 deletions tests/comparisons/Plugin/SimpleExample/tests/bootstrap.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,16 @@
chdir($root);

require_once $root . '/vendor/autoload.php';
require_once $root . '/vendor/cakephp/cakephp/src/basics.php';

/**
* Define fallback values for required constants and configuration.
* To customize constants and configuration remove this require
* and define the data required by your plugin here.
*/
require_once $root . '/vendor/cakephp/cakephp/tests/bootstrap.php';

if (file_exists($root . '/config/bootstrap.php')) {
require $root . '/config/bootstrap.php';

return;
}
require $root . '/vendor/cakephp/cakephp/tests/bootstrap.php';

0 comments on commit 437f416

Please sign in to comment.