eZ/Publish/Core/MVC/Symfony/SiteAccess/Tests/Compound/CompoundAndTest.php 1 location
|
@@ 321-332 (lines=12) @@
|
| 318 |
|
} |
| 319 |
|
} |
| 320 |
|
|
| 321 |
|
public function testSerialize() |
| 322 |
|
{ |
| 323 |
|
$matcher = new LogicalAnd([]); |
| 324 |
|
$matcher->setRequest(new SimplifiedRequest(['pathinfo' => '/foo/bar'])); |
| 325 |
|
$sa = new SiteAccess('test', 'test', $matcher); |
| 326 |
|
$serializedSA1 = serialize($sa); |
| 327 |
|
|
| 328 |
|
$matcher->setRequest(new SimplifiedRequest(['pathinfo' => '/foo/bar/baz'])); |
| 329 |
|
$serializedSA2 = serialize($sa); |
| 330 |
|
|
| 331 |
|
$this->assertSame($serializedSA1, $serializedSA2); |
| 332 |
|
} |
| 333 |
|
} |
| 334 |
|
|
eZ/Publish/Core/MVC/Symfony/SiteAccess/Tests/Compound/CompoundOrTest.php 1 location
|
@@ 329-340 (lines=12) @@
|
| 326 |
|
} |
| 327 |
|
} |
| 328 |
|
|
| 329 |
|
public function testSerialize() |
| 330 |
|
{ |
| 331 |
|
$matcher = new LogicalOr([]); |
| 332 |
|
$matcher->setRequest(new SimplifiedRequest(['pathinfo' => '/foo/bar'])); |
| 333 |
|
$sa = new SiteAccess('test', 'test', $matcher); |
| 334 |
|
$serializedSA1 = serialize($sa); |
| 335 |
|
|
| 336 |
|
$matcher->setRequest(new SimplifiedRequest(['pathinfo' => '/foo/bar/baz'])); |
| 337 |
|
$serializedSA2 = serialize($sa); |
| 338 |
|
|
| 339 |
|
$this->assertSame($serializedSA1, $serializedSA2); |
| 340 |
|
} |
| 341 |
|
} |
| 342 |
|
|
eZ/Publish/Core/MVC/Symfony/SiteAccess/Tests/RouterURIElement2Test.php 1 location
|
@@ 166-177 (lines=12) @@
|
| 163 |
|
$this->assertNull($matcher->reverseMatch('another_siteaccess_again_dont_tell_me')); |
| 164 |
|
} |
| 165 |
|
|
| 166 |
|
public function testSerialize() |
| 167 |
|
{ |
| 168 |
|
$matcher = new URIElementMatcher([2]); |
| 169 |
|
$matcher->setRequest(new SimplifiedRequest(['pathinfo' => '/foo/bar'])); |
| 170 |
|
$sa = new SiteAccess('test', 'test', $matcher); |
| 171 |
|
$serializedSA1 = serialize($sa); |
| 172 |
|
|
| 173 |
|
$matcher->setRequest(new SimplifiedRequest(['pathinfo' => '/foo/bar/baz'])); |
| 174 |
|
$serializedSA2 = serialize($sa); |
| 175 |
|
|
| 176 |
|
$this->assertSame($serializedSA1, $serializedSA2); |
| 177 |
|
} |
| 178 |
|
|
| 179 |
|
protected function createRouter(): Router |
| 180 |
|
{ |
eZ/Publish/Core/MVC/Symfony/SiteAccess/Tests/RouterURIElementTest.php 1 location
|
@@ 138-149 (lines=12) @@
|
| 135 |
|
]; |
| 136 |
|
} |
| 137 |
|
|
| 138 |
|
public function testSerialize() |
| 139 |
|
{ |
| 140 |
|
$matcher = new URIElementMatcher([1]); |
| 141 |
|
$matcher->setRequest(new SimplifiedRequest(['pathinfo' => '/foo/bar'])); |
| 142 |
|
$sa = new SiteAccess('test', 'test', $matcher); |
| 143 |
|
$serializedSA1 = serialize($sa); |
| 144 |
|
|
| 145 |
|
$matcher->setRequest(new SimplifiedRequest(['pathinfo' => '/foo/bar/baz'])); |
| 146 |
|
$serializedSA2 = serialize($sa); |
| 147 |
|
|
| 148 |
|
$this->assertSame($serializedSA1, $serializedSA2); |
| 149 |
|
} |
| 150 |
|
|
| 151 |
|
protected function createRouter(): Router |
| 152 |
|
{ |