‪TYPO3CMS  11.5
UriTest.php
Go to the documentation of this file.
1 <?php
2 
3 declare(strict_types=1);
4 
5 /*
6  * This file is part of the TYPO3 CMS project.
7  *
8  * It is free software; you can redistribute it and/or modify it under
9  * the terms of the GNU General Public License, either version 2
10  * of the License, or any later version.
11  *
12  * For the full copyright and license information, please read the
13  * LICENSE.txt file that was distributed with this source code.
14  *
15  * The TYPO3 project - inspiring people to share!
16  */
17 
19 
21 use TYPO3\TestingFramework\Core\Unit\UnitTestCase;
22 
28 class ‪UriTest extends UnitTestCase
29 {
33  public function ‪constructorSetsAllProperties(): void
34  {
35  $uri = new ‪Uri('https://user:pass@local.example.com:3001/foo?bar=baz#quz');
36  self::assertEquals('https', $uri->getScheme());
37  self::assertEquals('user:pass', $uri->getUserInfo());
38  self::assertEquals('local.example.com', $uri->getHost());
39  self::assertEquals(3001, $uri->getPort());
40  self::assertEquals('user:pass@local.example.com:3001', $uri->getAuthority());
41  self::assertEquals('/foo', $uri->getPath());
42  self::assertEquals('bar=baz', $uri->getQuery());
43  self::assertEquals('quz', $uri->getFragment());
44  }
45 
46  public function ‪canSerializeToStringDataProvider(): array
47  {
48  return [
49  'full uri' => [ 'https://user:pass@local.example.com:3001/foo?bar=baz#quz' ],
50  'double slash' => [ 'https://user:pass@local.example.com:3001//' ],
51  ];
52  }
53 
58  public function ‪canSerializeToString(string $uri): void
59  {
60  self::assertEquals($uri, (string)(new ‪Uri($uri)));
61  }
62 
67  {
68  $uri = new ‪Uri('https://user:pass@local.example.com:3001/foo?bar=baz#quz');
69  $new = $uri->withScheme('http');
70  self::assertNotSame($uri, $new);
71  self::assertEquals('http', $new->getScheme());
72  self::assertEquals('http://user:pass@local.example.com:3001/foo?bar=baz#quz', (string)$new);
73  }
74 
79  {
80  $uri = new ‪Uri('https://user:pass@local.example.com:3001/foo?bar=baz#quz');
81  $new = $uri->withUserInfo('matthew');
82  self::assertNotSame($uri, $new);
83  self::assertEquals('matthew', $new->getUserInfo());
84  self::assertEquals('https://matthew@local.example.com:3001/foo?bar=baz#quz', (string)$new);
85  }
86 
91  {
92  $uri = new ‪Uri('https://user:pass@local.example.com:3001/foo?bar=baz#quz');
93  $new = $uri->withUserInfo('matthew', 'zf2');
94  self::assertNotSame($uri, $new);
95  self::assertEquals('matthew:zf2', $new->getUserInfo());
96  self::assertEquals('https://matthew:zf2@local.example.com:3001/foo?bar=baz#quz', (string)$new);
97  }
98 
103  {
104  $uri = new ‪Uri('https://user:pass@local.example.com:3001/foo?bar=baz#quz');
105  $new = $uri->withHost('framework.zend.com');
106  self::assertNotSame($uri, $new);
107  self::assertEquals('framework.zend.com', $new->getHost());
108  self::assertEquals('https://user:pass@framework.zend.com:3001/foo?bar=baz#quz', (string)$new);
109  }
110 
115  {
116  $uri = new ‪Uri('https://user:pass@local.example.com:3001/foo?bar=baz#quz');
117  $new = $uri->withPort(null);
118  self::assertEquals(
119  'https://user:pass@local.example.com/foo?bar=baz#quz',
120  (string)$new
121  );
122  }
126  public function ‪validPortsDataProvider(): array
127  {
128  return [
129  'int' => [3000],
130  'string' => ['3000'],
131  ];
132  }
133 
139  {
140  $uri = new ‪Uri('https://user:pass@local.example.com:3001/foo?bar=baz#quz');
141  $new = $uri->withPort($port);
142  self::assertNotSame($uri, $new);
143  self::assertEquals($port, $new->getPort());
144  self::assertEquals(
145  sprintf('https://user:pass@local.example.com:%d/foo?bar=baz#quz', $port),
146  (string)$new
147  );
148  }
149 
153  public function ‪invalidPortsDataProviderType(): array
154  {
155  return [
156  'false' => [false],
157  'string' => ['string'],
158  'array' => [[3000]],
159  'object' => [(object)[3000]],
160  ];
161  }
162 
168  {
169  $uri = new ‪Uri('https://user:pass@local.example.com:3001/foo?bar=baz#quz');
170  $this->expectException(\InvalidArgumentException::class);
171  $this->expectExceptionCode(1436717324);
172  $uri->withPort($port);
173  }
174 
178  public function ‪invalidPortsDataProviderRange(): array
179  {
180  return [
181  'zero' => [0],
182  'too-small' => [-1],
183  'too-big' => [65536],
184  ];
185  }
186 
195  {
196  $uri = new ‪Uri('https://user:pass@local.example.com:3001/foo?bar=baz#quz');
197  $new = $uri->withPort(true);
198  self::assertNotSame($uri, $new);
199  self::assertEquals(1, $new->getPort());
200  }
201 
207  {
208  $uri = new ‪Uri('https://user:pass@local.example.com:3001/foo?bar=baz#quz');
209  $this->expectException(\InvalidArgumentException::class);
210  $this->expectExceptionCode(1436717326);
211  $uri->withPort($port);
212  }
213 
218  {
219  $subject = new ‪Uri('http://www.example.com:80');
220  self::assertEquals('http://www.example.com', (string)$subject);
221  }
222 
227  {
228  $subject = new ‪Uri('www.example.com:80');
229  self::assertEquals('//www.example.com:80', (string)$subject);
230  }
231 
236  {
237  $subject = new ‪Uri('www.example.com');
238  self::assertEquals('/www.example.com', (string)$subject);
239  }
240 
245  {
246  $uri = new ‪Uri('https://user:pass@local.example.com:3001/foo?bar=baz#quz');
247  $new = $uri->withPath('/bar/baz');
248  self::assertNotSame($uri, $new);
249  self::assertEquals('/bar/baz', $new->getPath());
250  self::assertEquals('https://user:pass@local.example.com:3001/bar/baz?bar=baz#quz', (string)$new);
251  }
252 
256  public function ‪invalidPathsDataProvider(): array
257  {
258  return [
259  'null' => [null],
260  'true' => [true],
261  'false' => [false],
262  'array' => [['/bar/baz']],
263  'object' => [(object)['/bar/baz']],
264  ];
265  }
266 
271  public function ‪withPathRaisesExceptionForInvalidPaths($path): void
272  {
273  $uri = new ‪Uri('https://user:pass@local.example.com:3001/foo?bar=baz#quz');
274  $this->expectException(\InvalidArgumentException::class);
275  $this->expectExceptionCode(1436717328);
276  $uri->withPath($path);
277  }
278 
283  {
284  $uri = new ‪Uri('https://user:pass@local.example.com:3001/foo?bar=baz#quz');
285  $this->expectException(\InvalidArgumentException::class);
286  $this->expectExceptionCode(1436717330);
287  $uri->withPath('/bar/baz?bat=quz');
288  }
289 
294  {
295  $uri = new ‪Uri('https://user:pass@local.example.com:3001/foo?bar=baz#quz');
296  $this->expectException(\InvalidArgumentException::class);
297  $this->expectExceptionCode(1436717332);
298  $uri->withPath('/bar/baz#bat');
299  }
300 
305  {
306  $uri = new ‪Uri('https://user:pass@local.example.com:3001/foo?bar=baz#quz');
307  $new = $uri->withQuery('baz=bat');
308  self::assertNotSame($uri, $new);
309  self::assertEquals('baz=bat', $new->getQuery());
310  self::assertEquals('https://user:pass@local.example.com:3001/foo?baz=bat#quz', (string)$new);
311  }
312 
316  public function ‪invalidQueryStringsDataProvider(): array
317  {
318  return [
319  'null' => [null],
320  'true' => [true],
321  'false' => [false],
322  'array' => [['baz=bat']],
323  'object' => [(object)['baz=bat']],
324  ];
325  }
326 
332  {
333  $uri = new ‪Uri('https://user:pass@local.example.com:3001/foo?bar=baz#quz');
334  $this->expectException(\InvalidArgumentException::class);
335  $this->expectExceptionCode(1436717334);
336  $uri->withQuery($query);
337  }
338 
343  {
344  $uri = new ‪Uri('https://user:pass@local.example.com:3001/foo?bar=baz#quz');
345  $this->expectException(\InvalidArgumentException::class);
346  $this->expectExceptionCode(1436717336);
347  $uri->withQuery('baz=bat#quz');
348  }
349 
354  {
355  $uri = new ‪Uri('https://user:pass@local.example.com:3001/foo?bar=baz#quz');
356  $new = $uri->withFragment('qat');
357  self::assertNotSame($uri, $new);
358  self::assertEquals('qat', $new->getFragment());
359  self::assertEquals('https://user:pass@local.example.com:3001/foo?bar=baz#qat', (string)$new);
360  }
361 
365  public function ‪authorityInfoDataProvider(): array
366  {
367  return [
368  'host-only' => ['http://foo.com/bar', 'foo.com'],
369  'host-port' => ['http://foo.com:3000/bar', 'foo.com:3000'],
370  'user-host' => ['http://me@foo.com/bar', 'me@foo.com'],
371  'user-host-port' => ['http://me@foo.com:3000/bar', 'me@foo.com:3000'],
372  ];
373  }
374 
379  public function ‪getAuthorityReturnsExpectedValues($url, $expected): void
380  {
381  $uri = new ‪Uri($url);
382  self::assertEquals($expected, $uri->getAuthority());
383  }
384 
388  public function ‪canEmitOriginFormUrl(): void
389  {
390  $url = '/foo/bar?baz=bat';
391  $uri = new ‪Uri($url);
392  self::assertEquals($url, (string)$uri);
393  }
394 
399  {
400  $uri = new ‪Uri('http://example.com/foo');
401  $new = $uri->withPath('');
402  self::assertEquals('', $new->getPath());
403  }
404 
409  {
410  $uri = new ‪Uri('http://example.com');
411  self::assertEquals('http://example.com', (string)$uri);
412  }
413 
418  {
419  $uri = new ‪Uri('?foo=bar');
420  self::assertEquals('', $uri->getPath());
421  }
422 
427  {
428  $uri = new ‪Uri('?foo=bar');
429  self::assertEquals('?foo=bar', (string)$uri);
430  }
431 
435  public function ‪invalidConstructorUrisDataProvider(): array
436  {
437  return [
438  'null' => [null],
439  'true' => [true],
440  'false' => [false],
441  'int' => [1],
442  'float' => [1.1],
443  'array' => [['http://example.com/']],
444  'object' => [(object)['uri' => 'http://example.com/']],
445  ];
446  }
447 
452  {
453  $this->expectException(\InvalidArgumentException::class);
454  new ‪Uri($uri);
455  }
456 
461  {
462  $this->expectException(\InvalidArgumentException::class);
463  new ‪Uri('http:///www.php-fig.org/');
464  }
465 
469  public function ‪withSchemeStripsOffDelimiter(): void
470  {
471  $uri = new ‪Uri('http://example.com');
472  $new = $uri->withScheme('https://');
473  self::assertEquals('https', $new->getScheme());
474  }
475 
479  public function ‪invalidSchemesDataProvider(): array
480  {
481  return [
482  'mailto' => ['mailto'],
483  'ftp' => ['ftp'],
484  'telnet' => ['telnet'],
485  'ssh' => ['ssh'],
486  'git' => ['git'],
487  ];
488  }
489 
495  {
496  $this->expectException(\InvalidArgumentException::class);
497  $this->expectExceptionCode(1436717338);
498  new ‪Uri($scheme . '://example.com');
499  }
500 
506  {
507  $uri = new ‪Uri('http://example.com');
508  $this->expectException(\InvalidArgumentException::class);
509  $this->expectExceptionCode(1436717338);
510  $uri->withScheme($scheme);
511  }
512 
517  {
518  $uri = new ‪Uri('http://example.com');
519  $new = $uri->withPath('foo/bar');
520  self::assertEquals('foo/bar', $new->getPath());
521  }
522 
527  {
528  $uri = new ‪Uri('https://user:pass@local.example.com:3001/foo?bar=baz#quz');
529  $new = $uri->withScheme('');
530  self::assertNotSame($uri, $new);
531  self::assertNotSame((string)$uri, (string)$new);
532  self::assertEquals('', $new->getScheme());
533  self::assertEquals('//user:pass@local.example.com:3001/foo?bar=baz#quz', (string)$new);
534  }
535 
540  {
541  $uri = new ‪Uri('http://example.com');
542  $new = $uri->withPath('foo/bar');
543  self::assertEquals('http://example.com/foo/bar', $new->__toString());
544  }
545 
550  {
551  $uri = new ‪Uri('http://example.com');
552  $new = $uri->withQuery('?foo=bar');
553  self::assertEquals('foo=bar', $new->getQuery());
554  }
555 
560  {
561  $uri = new ‪Uri('http://example.com');
562  $new = $uri->withFragment('#/foo/bar');
563  self::assertEquals('/foo/bar', $new->getFragment());
564  }
565 
570  {
571  return [
572  'http' => ['http', 80],
573  'https' => ['https', 443],
574  ];
575  }
576 
581  public function ‪getAuthorityOmitsPortForStandardSchemePortCombinations($scheme, $port): void
582  {
583  $uri = (new ‪Uri())
584  ->withHost('example.com')
585  ->withScheme($scheme)
586  ->withPort($port);
587  self::assertEquals('example.com', $uri->getAuthority());
588  }
589 
593  public function ‪getPathIsProperlyEncoded(): void
594  {
595  $uri = (new ‪Uri())->withPath('/foo^bar');
596  $expected = '/foo%5Ebar';
597  self::assertEquals($expected, $uri->getPath());
598  }
599 
603  public function ‪getPathDoesNotBecomeDoubleEncoded(): void
604  {
605  $uri = (new ‪Uri())->withPath('/foo%5Ebar');
606  $expected = '/foo%5Ebar';
607  self::assertEquals($expected, $uri->getPath());
608  }
609 
613  public function ‪queryStringsForEncodingDataProvider(): array
614  {
615  return [
616  'key-only' => ['k^ey', 'k%5Eey'],
617  'key-value' => ['k^ey=valu`', 'k%5Eey=valu%60'],
618  'array-key-only' => ['key[]', 'key%5B%5D'],
619  'array-key-value' => ['key[]=valu`', 'key%5B%5D=valu%60'],
620  'complex' => ['k^ey&key[]=valu`&f<>=`bar', 'k%5Eey&key%5B%5D=valu%60&f%3C%3E=%60bar'],
621  ];
622  }
623 
628  public function ‪getQueryIsProperlyEncoded($query, $expected): void
629  {
630  $uri = (new ‪Uri())->withQuery($query);
631  self::assertEquals($expected, $uri->getQuery());
632  }
633 
638  public function ‪getQueryIsNotDoubleEncoded($query, $expected): void
639  {
640  $uri = (new ‪Uri())->withQuery($expected);
641  self::assertEquals($expected, $uri->getQuery());
642  }
643 
647  public function ‪getFragmentIsProperlyEncoded(): void
648  {
649  $uri = (new ‪Uri())->withFragment('/p^th?key^=`bar#b@z');
650  $expected = '/p%5Eth?key%5E=%60bar%23b@z';
651  self::assertEquals($expected, $uri->getFragment());
652  }
653 
657  public function ‪getFragmentIsNotDoubleEncoded(): void
658  {
659  $expected = '/p%5Eth?key%5E=%60bar%23b@z';
660  $uri = (new ‪Uri())->withFragment($expected);
661  self::assertEquals($expected, $uri->getFragment());
662  }
663 }
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\standardSchemePortCombinationsDataProvider
‪array standardSchemePortCombinationsDataProvider()
Definition: UriTest.php:569
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\settingEmptyPathOnAbsoluteUriReturnsAnEmptyPath
‪settingEmptyPathOnAbsoluteUriReturnsAnEmptyPath()
Definition: UriTest.php:398
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\invalidSchemesDataProvider
‪array invalidSchemesDataProvider()
Definition: UriTest.php:479
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withHostReturnsNewInstanceWithProvidedHost
‪withHostReturnsNewInstanceWithProvidedHost()
Definition: UriTest.php:102
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withPathRaisesExceptionForInvalidPathsWithQuery
‪withPathRaisesExceptionForInvalidPathsWithQuery()
Definition: UriTest.php:282
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withPortAcceptsBooleanTrueAsPortOne
‪withPortAcceptsBooleanTrueAsPortOne()
Definition: UriTest.php:194
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withQueryRaisesExceptionForInvalidQueryStringsByType
‪withQueryRaisesExceptionForInvalidQueryStringsByType($query)
Definition: UriTest.php:331
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withFragmentStripsFragmentPrefixIfPresent
‪withFragmentStripsFragmentPrefixIfPresent()
Definition: UriTest.php:559
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withPathIsNotPrefixedWithSlashIfSetWithoutOne
‪withPathIsNotPrefixedWithSlashIfSetWithoutOne()
Definition: UriTest.php:516
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\getFragmentIsProperlyEncoded
‪getFragmentIsProperlyEncoded()
Definition: UriTest.php:647
‪TYPO3\CMS\Core\Tests\Unit\Http
Definition: ApplicationTypeTest.php:18
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\noPortAndNoSchemeDoesNotRenderPort
‪noPortAndNoSchemeDoesNotRenderPort()
Definition: UriTest.php:235
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withSchemeUsingUnsupportedSchemeRaisesAnException
‪withSchemeUsingUnsupportedSchemeRaisesAnException($scheme)
Definition: UriTest.php:505
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\canEmitOriginFormUrl
‪canEmitOriginFormUrl()
Definition: UriTest.php:388
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withPortRaisesExceptionForInvalidPortsByType
‪withPortRaisesExceptionForInvalidPortsByType($port)
Definition: UriTest.php:167
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withPathReturnsNewInstanceWithProvidedPath
‪withPathReturnsNewInstanceWithProvidedPath()
Definition: UriTest.php:244
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\invalidPortsDataProviderType
‪array invalidPortsDataProviderType()
Definition: UriTest.php:153
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\getQueryIsProperlyEncoded
‪getQueryIsProperlyEncoded($query, $expected)
Definition: UriTest.php:628
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\authorityInfoDataProvider
‪array authorityInfoDataProvider()
Definition: UriTest.php:365
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\standardPortAndSchemeDoesNotRenderPort
‪standardPortAndSchemeDoesNotRenderPort()
Definition: UriTest.php:217
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\constructorRaisesExceptionForSeriouslyMalformedURI
‪constructorRaisesExceptionForSeriouslyMalformedURI()
Definition: UriTest.php:460
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\constructorRaisesExceptionForNonStringURI
‪constructorRaisesExceptionForNonStringURI($uri)
Definition: UriTest.php:451
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\getPathIsProperlyEncoded
‪getPathIsProperlyEncoded()
Definition: UriTest.php:593
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\stringRepresentationOfOriginFormWithNoPathRetainsEmptyPath
‪stringRepresentationOfOriginFormWithNoPathRetainsEmptyPath()
Definition: UriTest.php:426
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withSchemeReturnsNewInstanceWithNewScheme
‪withSchemeReturnsNewInstanceWithNewScheme()
Definition: UriTest.php:66
‪TYPO3\CMS\Core\Http\Uri
Definition: Uri.php:29
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\queryStringsForEncodingDataProvider
‪array queryStringsForEncodingDataProvider()
Definition: UriTest.php:613
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withSchemeStripsOffDelimiter
‪withSchemeStripsOffDelimiter()
Definition: UriTest.php:469
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\getAuthorityReturnsExpectedValues
‪getAuthorityReturnsExpectedValues($url, $expected)
Definition: UriTest.php:379
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withPathRaisesExceptionForInvalidPaths
‪withPathRaisesExceptionForInvalidPaths($path)
Definition: UriTest.php:271
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\getQueryIsNotDoubleEncoded
‪getQueryIsNotDoubleEncoded($query, $expected)
Definition: UriTest.php:638
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\invalidPortsDataProviderRange
‪array invalidPortsDataProviderRange()
Definition: UriTest.php:178
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withPathNotSlashPrefixedIsEmittedWithSlashDelimiterWhenUriIsCastToString
‪withPathNotSlashPrefixedIsEmittedWithSlashDelimiterWhenUriIsCastToString()
Definition: UriTest.php:539
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\canSerializeToString
‪canSerializeToString(string $uri)
Definition: UriTest.php:58
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withPathRaisesExceptionForInvalidPathsWithFragment
‪withPathRaisesExceptionForInvalidPathsWithFragment()
Definition: UriTest.php:293
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\getPathOnOriginFormRemainsAnEmptyPath
‪getPathOnOriginFormRemainsAnEmptyPath()
Definition: UriTest.php:417
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\invalidPathsDataProvider
‪array invalidPathsDataProvider()
Definition: UriTest.php:256
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\standardPortAndNoSchemeDoesRenderPort
‪standardPortAndNoSchemeDoesRenderPort()
Definition: UriTest.php:226
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\getAuthorityOmitsPortForStandardSchemePortCombinations
‪getAuthorityOmitsPortForStandardSchemePortCombinations($scheme, $port)
Definition: UriTest.php:581
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\validPortsDataProvider
‪array validPortsDataProvider()
Definition: UriTest.php:126
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\constructorSetsAllProperties
‪constructorSetsAllProperties()
Definition: UriTest.php:33
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withQueryRaisesExceptionForInvalidQueryStringsByFragment
‪withQueryRaisesExceptionForInvalidQueryStringsByFragment()
Definition: UriTest.php:342
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\getPathDoesNotBecomeDoubleEncoded
‪getPathDoesNotBecomeDoubleEncoded()
Definition: UriTest.php:603
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withEmptySchemeReturnsNewInstanceWithAbsoluteUri
‪withEmptySchemeReturnsNewInstanceWithAbsoluteUri()
Definition: UriTest.php:526
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\getFragmentIsNotDoubleEncoded
‪getFragmentIsNotDoubleEncoded()
Definition: UriTest.php:657
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withUserInfoReturnsNewInstanceWithProvidedUserAndPassword
‪withUserInfoReturnsNewInstanceWithProvidedUserAndPassword()
Definition: UriTest.php:90
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\stringRepresentationOfAbsoluteUriWithNoPathSetsAnEmptyPath
‪stringRepresentationOfAbsoluteUriWithNoPathSetsAnEmptyPath()
Definition: UriTest.php:408
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withPortRaisesExceptionForInvalidPortsByRange
‪withPortRaisesExceptionForInvalidPortsByRange($port)
Definition: UriTest.php:206
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\invalidQueryStringsDataProvider
‪array invalidQueryStringsDataProvider()
Definition: UriTest.php:316
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\canSerializeToStringDataProvider
‪canSerializeToStringDataProvider()
Definition: UriTest.php:46
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withQueryReturnsNewInstanceWithProvidedQuery
‪withQueryReturnsNewInstanceWithProvidedQuery()
Definition: UriTest.php:304
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withPortAndNullValueReturnsInstanceWithProvidedPort
‪withPortAndNullValueReturnsInstanceWithProvidedPort()
Definition: UriTest.php:114
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\invalidConstructorUrisDataProvider
‪array invalidConstructorUrisDataProvider()
Definition: UriTest.php:435
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withQueryStripsQueryPrefixIfPresent
‪withQueryStripsQueryPrefixIfPresent()
Definition: UriTest.php:549
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withUserInfoReturnsNewInstanceWithProvidedUser
‪withUserInfoReturnsNewInstanceWithProvidedUser()
Definition: UriTest.php:78
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withPortReturnsNewInstanceWithProvidedPort
‪withPortReturnsNewInstanceWithProvidedPort($port)
Definition: UriTest.php:138
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\withFragmentReturnsNewInstanceWithProvidedFragment
‪withFragmentReturnsNewInstanceWithProvidedFragment()
Definition: UriTest.php:353
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest
Definition: UriTest.php:29
‪TYPO3\CMS\Core\Tests\Unit\Http\UriTest\constructWithUnsupportedSchemeRaisesAnException
‪constructWithUnsupportedSchemeRaisesAnException($scheme)
Definition: UriTest.php:494