Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'tests/PHPUnit/proxy/index.php')
-rw-r--r--tests/PHPUnit/proxy/index.php35
1 files changed, 18 insertions, 17 deletions
diff --git a/tests/PHPUnit/proxy/index.php b/tests/PHPUnit/proxy/index.php
index e3034ccb1c..fd59a24554 100644
--- a/tests/PHPUnit/proxy/index.php
+++ b/tests/PHPUnit/proxy/index.php
@@ -2,8 +2,8 @@
/**
* Proxy to index.php, but will use the Test DB
* Currently only used only for the test: tests/PHPUnit/Integration/ImportLogsTest.php
- * since other integration tests do not call index.php via http but use the Piwik_API_Request object
- *
+ * since other integration tests do not call index.php via http but use the Piwik_API_Request object
+ *
*/
// Wrapping the request inside ob_start() calls to ensure that the Test
@@ -13,25 +13,26 @@ ob_start();
define('PIWIK_INCLUDE_PATH', '../../..');
define('PIWIK_USER_PATH', PIWIK_INCLUDE_PATH);
-require_once PIWIK_INCLUDE_PATH .'/libs/upgradephp/upgrade.php';
-require_once PIWIK_INCLUDE_PATH .'/core/Loader.php';
+require_once PIWIK_INCLUDE_PATH . '/libs/upgradephp/upgrade.php';
+require_once PIWIK_INCLUDE_PATH . '/core/Loader.php';
Piwik_Tracker::setTestEnvironment();
Piwik_Tracker_Cache::deleteTrackerCache();
-class Piwik_FrontController_Test extends Piwik_FrontController
+class Piwik_FrontController_Test extends Piwik_FrontController
{
- protected function createConfigObject()
- {
- // Config files forced to use the test database
- Piwik::createConfigObject();
- Piwik_Config::getInstance()->setTestEnvironment();
- }
- protected function createAccessObject()
- {
- parent::createAccessObject();
- Piwik::setUserIsSuperUser(true);
- }
+ protected function createConfigObject()
+ {
+ // Config files forced to use the test database
+ Piwik::createConfigObject();
+ Piwik_Config::getInstance()->setTestEnvironment();
+ }
+
+ protected function createAccessObject()
+ {
+ parent::createAccessObject();
+ Piwik::setUserIsSuperUser(true);
+ }
}
// Disable index.php dispatch since we do it manually below
@@ -41,5 +42,5 @@ include PIWIK_INCLUDE_PATH . '/index.php';
$controller = new Piwik_FrontController_Test;
$controller->init();
$controller->dispatch();
-
+
ob_flush();