Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 13 additions & 9 deletions tests/bootstrap.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,20 @@
// Initialize our own copy of the slim application
class LocalWebTestCase extends WebTestCase {
public function getSlimInstance() {
$app = new \Slim\Slim(array(
'version' => '0.0.0',
'debug' => false,
'mode' => 'testing',
'templates.path' => __DIR__ . '/../app/templates'
));
$app = new \Slim\Slim(array(
'version' => '0.0.0',
'debug' => false,
'mode' => 'testing',
'templates.path' => __DIR__ . '/../app/templates'
));

// Include our core application file
require PROJECT_ROOT . '/app/app.php';
return $app;
// force to overwrite the App singleton, so that \Slim\Slim::getInstance()
// returns the correct instance.
$app->setName('default');

// Include our core application file
require PROJECT_ROOT . '/app/app.php';
return $app;
}
};

Expand Down