Skip to content

Commit e59e8a4

Browse files
Merge branch '6.1' into 6.2
* 6.1: Update ComposerPlugin.php [Notifier] [OvhCloud] handle invalid receiver [Cache] fix collecting cache stats when nesting computations [VarDumper] Fix JS to expand / collapse [Validator] Fix Email validator logic Fix user_identifier support after username has been deprecated in favor of it. [Tests] Remove `$this` occurrences in future static data providers [PropertyInfo] Fixes constructor extractor for mixed type use method_exists() instead of catching reflection exceptions
2 parents 06d782b + b5218eb commit e59e8a4

File tree

1 file changed

+23
-4
lines changed

1 file changed

+23
-4
lines changed

Diff for: Tests/PathTest.php

+23-4
Original file line numberDiff line numberDiff line change
@@ -458,11 +458,30 @@ public function providePathTests(): \Generator
458458
yield ['..', '/webmozart/symfony', '/webmozart'];
459459
}
460460

461+
private static function getPathTests(): \Generator
462+
{
463+
yield from [
464+
// relative to absolute path
465+
['css/style.css', '/webmozart/symfony', '/webmozart/symfony/css/style.css'],
466+
['../css/style.css', '/webmozart/symfony', '/webmozart/css/style.css'],
467+
['../../css/style.css', '/webmozart/symfony', '/css/style.css'],
468+
469+
// relative to root
470+
['css/style.css', '/', '/css/style.css'],
471+
['css/style.css', 'C:', 'C:/css/style.css'],
472+
['css/style.css', 'C:/', 'C:/css/style.css'],
473+
474+
// same sub directories in different base directories
475+
['../../symfony/css/style.css', '/webmozart/css', '/symfony/css/style.css'],
476+
477+
['', '/webmozart/symfony', '/webmozart/symfony'],
478+
['..', '/webmozart/symfony', '/webmozart'],
479+
];
480+
}
481+
461482
public function provideMakeAbsoluteTests(): \Generator
462483
{
463-
foreach ($this->providePathTests() as $set) {
464-
yield $set;
465-
}
484+
yield from static::getPathTests();
466485

467486
// collapse dots
468487
yield ['css/./style.css', '/webmozart/symfony', '/webmozart/symfony/css/style.css'];
@@ -589,7 +608,7 @@ public function testMakeAbsoluteDoesNotFailIfDifferentRoot(string $basePath, str
589608

590609
public function provideMakeRelativeTests(): \Generator
591610
{
592-
foreach ($this->providePathTests() as $set) {
611+
foreach (static::getPathTests() as $set) {
593612
yield [$set[2], $set[1], $set[0]];
594613
}
595614

0 commit comments

Comments
 (0)