Thanks to visit codestin.com
Credit goes to github.com

Skip to content
Merged
Changes from 1 commit
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
Prev Previous commit
[Routing] fixed CS
  • Loading branch information
fabpot committed Feb 3, 2014
commit 12407586b2ddc034aea704c018722fde11ddaaa9
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ public function testDumpWithRoutes()
$this->routeCollection->add('Test2', new Route('/testing2'));

file_put_contents($this->testTmpFilepath, $this->generatorDumper->dump());
include ($this->testTmpFilepath);
include $this->testTmpFilepath;

$projectUrlGenerator = new \ProjectUrlGenerator(new RequestContext('/app.php'));

Expand All @@ -81,7 +81,7 @@ public function testDumpWithRoutes()
public function testDumpWithoutRoutes()
{
file_put_contents($this->testTmpFilepath, $this->generatorDumper->dump(array('class' => 'WithoutRoutesUrlGenerator')));
include ($this->testTmpFilepath);
include $this->testTmpFilepath;

$projectUrlGenerator = new \WithoutRoutesUrlGenerator(new RequestContext('/app.php'));

Expand All @@ -96,7 +96,7 @@ public function testGenerateNonExistingRoute()
$this->routeCollection->add('Test', new Route('/test'));

file_put_contents($this->testTmpFilepath, $this->generatorDumper->dump(array('class' => 'NonExistingRoutesUrlGenerator')));
include ($this->testTmpFilepath);
include $this->testTmpFilepath;

$projectUrlGenerator = new \NonExistingRoutesUrlGenerator(new RequestContext());
$url = $projectUrlGenerator->generate('NonExisting', array());
Expand All @@ -107,7 +107,7 @@ public function testDumpForRouteWithDefaults()
$this->routeCollection->add('Test', new Route('/testing/{foo}', array('foo' => 'bar')));

file_put_contents($this->testTmpFilepath, $this->generatorDumper->dump(array('class' => 'DefaultRoutesUrlGenerator')));
include ($this->testTmpFilepath);
include $this->testTmpFilepath;

$projectUrlGenerator = new \DefaultRoutesUrlGenerator(new RequestContext());
$url = $projectUrlGenerator->generate('Test', array());
Expand All @@ -121,7 +121,7 @@ public function testDumpWithSchemeRequirement()
$this->routeCollection->add('Test2', new Route('/testing_bc', array(), array('_scheme' => 'https'))); // BC

file_put_contents($this->testTmpFilepath, $this->generatorDumper->dump(array('class' => 'SchemeUrlGenerator')));
include ($this->testTmpFilepath);
include $this->testTmpFilepath;

$projectUrlGenerator = new \SchemeUrlGenerator(new RequestContext('/app.php'));

Expand Down