Browse Source

Avoid side effects in Router.php

ADmad 11 years ago
parent
commit
d5e7584339
2 changed files with 3 additions and 3 deletions
  1. 0 3
      src/Routing/Router.php
  2. 3 0
      tests/bootstrap.php

+ 0 - 3
src/Routing/Router.php

@@ -956,6 +956,3 @@ class Router
         include CONFIG . 'routes.php';
     }
 }
-
-//Save the initial state
-Router::reload();

+ 3 - 0
tests/bootstrap.php

@@ -16,6 +16,7 @@ use Cake\Core\Configure;
 use Cake\Datasource\ConnectionManager;
 use Cake\I18n\I18n;
 use Cake\Log\Log;
+use Cake\Routing\Router;
 
 require_once 'vendor/autoload.php';
 
@@ -116,3 +117,5 @@ Log::config([
 Carbon\Carbon::setTestNow(Carbon\Carbon::now());
 
 ini_set('intl.default_locale', 'en_US');
+
+Router::reload();