Skip to content

Commit

Permalink
Merge branch '5.4' into 6.2
Browse files Browse the repository at this point in the history
* 5.4:
  [FrameworkBundle] Improve error message in MicroKernelTrait when using deprecated configureRoutes(RouteCollectionBuilder) with symfony/routing >= 6.0
  Add warning about Symfony 5.2 changing pcntl_async_signals
  [Tests] Fix static calls and Mock var annotation
  [FrameworkBundle] Fix checkboxes check assertions
  [Notifier][WebProfilerBundle] Ignore messages whose `getNotification` returns `null`
  [HttpClient] Fix over-encoding of URL parts to match browser's behavior
  Fix Psalm job
  [HttpClient] Fix data collector
  [Tests] Migrate tests to static data providers
  [Semaphore] Fix test
  Fix: Split and clean up tests
  Remove unused data provider
  add Sender to the list of bypassed headers
  • Loading branch information
nicolas-grekas committed Feb 11, 2023
2 parents b43903f + 23069c3 commit 53e43ef
Showing 1 changed file with 2 additions and 21 deletions.
23 changes: 2 additions & 21 deletions Tests/PathTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -439,25 +439,6 @@ public function testGetRoot(string $path, string $root)
$this->assertSame($root, Path::getRoot($path));
}

public function providePathTests(): \Generator
{
// relative to absolute path
yield ['css/style.css', '/webmozart/symfony', '/webmozart/symfony/css/style.css'];
yield ['../css/style.css', '/webmozart/symfony', '/webmozart/css/style.css'];
yield ['../../css/style.css', '/webmozart/symfony', '/css/style.css'];

// relative to root
yield ['css/style.css', '/', '/css/style.css'];
yield ['css/style.css', 'C:', 'C:/css/style.css'];
yield ['css/style.css', 'C:/', 'C:/css/style.css'];

// same sub directories in different base directories
yield ['../../symfony/css/style.css', '/webmozart/css', '/symfony/css/style.css'];

yield ['', '/webmozart/symfony', '/webmozart/symfony'];
yield ['..', '/webmozart/symfony', '/webmozart'];
}

private static function getPathTests(): \Generator
{
yield from [
Expand All @@ -481,7 +462,7 @@ private static function getPathTests(): \Generator

public function provideMakeAbsoluteTests(): \Generator
{
yield from static::getPathTests();
yield from self::getPathTests();

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

public function provideMakeRelativeTests(): \Generator
{
foreach (static::getPathTests() as $set) {
foreach (self::getPathTests() as $set) {
yield [$set[2], $set[1], $set[0]];
}

Expand Down

0 comments on commit 53e43ef

Please sign in to comment.