From c27da00dcd76423e8e3af7de600d74e04c9a38df Mon Sep 17 00:00:00 2001 From: Jordi Boggiano Date: Fri, 31 May 2024 15:04:44 +0200 Subject: [PATCH] Fix test --- tests/ClassMapGeneratorTest.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tests/ClassMapGeneratorTest.php b/tests/ClassMapGeneratorTest.php index 98d3094..2968921 100644 --- a/tests/ClassMapGeneratorTest.php +++ b/tests/ClassMapGeneratorTest.php @@ -244,13 +244,15 @@ public function testGetPSR4Violations(): void { $this->generator->scanPaths(__DIR__ . '/Fixtures/psrViolations', null, 'psr-4', 'ExpectedNamespace\\'); $classMap = $this->generator->getClassMap(); + $violations = $classMap->getPsrViolations(); + sort($violations); self::assertSame( [ 'Class ClassWithoutNameSpace located in ./tests/Fixtures/psrViolations/ClassWithoutNameSpace.php does not comply with psr-4 autoloading standard. Skipping.', - 'Class UnexpectedNamespace\ClassWithNameSpaceOutsideConfiguredScope located in ./tests/Fixtures/psrViolations/ClassWithNameSpaceOutsideConfiguredScope.php does not comply with psr-4 autoloading standard. Skipping.', 'Class ExpectedNamespace\UnexpectedSubNamespace\ClassWithIncorrectSubNamespace located in ./tests/Fixtures/psrViolations/ClassWithIncorrectSubNamespace.php does not comply with psr-4 autoloading standard. Skipping.', + 'Class UnexpectedNamespace\ClassWithNameSpaceOutsideConfiguredScope located in ./tests/Fixtures/psrViolations/ClassWithNameSpaceOutsideConfiguredScope.php does not comply with psr-4 autoloading standard. Skipping.', ], - $classMap->getPsrViolations() + $violations ); }