From ec09b40875ad66cd8db84faaef4d00fe49ff0efe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Simon=20Andr=C3=A9?= Date: Thu, 19 Oct 2023 15:22:12 +0200 Subject: [PATCH] Rename fixtures paths to be consistent --- .php-cs-fixer.dist.php | 2 +- .../manifest-invalid.json | 0 .../manifest-valid.json | 0 .../JsonManifestVersionStrategyTest.php | 6 +- src/Symfony/Component/AssetMapper/.gitignore | 2 +- ...apperDevServerSubscriberFunctionalTest.php | 2 +- .../Tests/AssetMapperRepositoryTest.php | 80 +++++++++--------- .../AssetMapper/Tests/AssetMapperTest.php | 10 +-- .../Command/AssetMapperCompileCommandTest.php | 4 +- .../Command/DebugAssetsMapperCommandTest.php | 2 +- .../Factory/CachedMappedAssetFactoryTest.php | 20 ++--- .../Tests/Factory/MappedAssetFactoryTest.php | 26 +++--- .../AssetMapperTestAppKernel.php | 2 +- .../@hotwired/stimulus/stimulus.index.js | 0 .../assets/vendor/installed.php | 0 .../assets/vendor/lodash/lodash.index.js | 0 .../circular_dir/circular1.css | 0 .../circular_dir/circular2.css | 0 .../Tests/{fixtures => Fixtures}/dir/file9.js | 0 .../{fixtures => Fixtures}/dir1/file1.css | 0 .../{fixtures => Fixtures}/dir1/file2.js | 0 ...already-abcdefVWXYZ0123456789.digested.css | 0 .../{fixtures => Fixtures}/dir2/file3.css | 0 .../{fixtures => Fixtures}/dir2/file4.js | 0 .../dir2/subdir/file5.js | 0 .../dir2/subdir/file6.js | 0 .../{fixtures => Fixtures}/dir3/test.gif.foo | Bin .../{fixtures => Fixtures}/importmap.php | 0 .../importmaps/assets/app.js | 0 .../importmaps/assets/imported_async.js | 0 .../importmaps/assets/pizza/index.js | 0 .../importmaps/assets/popcorn.js | 0 .../importmaps/assets/vendor/lodash.js | 0 .../importmaps/assets2/app2.js | 0 .../importmaps/assets2/imported.js | 0 .../importmaps/assets2/styles/app.css | 0 .../importmaps/assets2/styles/app2.css | 0 .../importmaps/assets2/styles/other.css | 0 .../importmaps/assets2/styles/other2.css | 0 .../importmaps/assets2/styles/sunshine.css | 0 .../importmaps/importmap.php | 0 .../test_public/final-assets/importmap.json | 0 .../final-assets/importmap.preload.json | 0 .../test_public/final-assets/manifest.json | 0 .../ImportMap/ImportMapConfigReaderTest.php | 24 +++--- .../Tests/ImportMap/ImportMapManagerTest.php | 6 +- .../ImportMap/RemotePackageDownloaderTest.php | 2 +- .../ImportMap/RemotePackageStorageTest.php | 2 +- ...MapperAwareAssetPackageIntegrationTest.php | 2 +- .../Tests/Dumper/CsvFileDumperTest.php | 2 +- .../Tests/Dumper/IcuResFileDumperTest.php | 2 +- .../Tests/Dumper/IniFileDumperTest.php | 2 +- .../Tests/Dumper/JsonFileDumperTest.php | 4 +- .../Tests/Dumper/MoFileDumperTest.php | 2 +- .../Tests/Dumper/PhpFileDumperTest.php | 2 +- .../Tests/Dumper/PoFileDumperTest.php | 4 +- .../Tests/Dumper/QtFileDumperTest.php | 2 +- .../Tests/Dumper/XliffFileDumperTest.php | 14 +-- .../Tests/Dumper/YamlFileDumperTest.php | 4 +- .../Tests/Extractor/PhpAstExtractorTest.php | 12 +-- .../Tests/Extractor/PhpExtractorTest.php | 12 +-- .../empty-translation.mo | Bin .../empty-translation.po | 0 .../Tests/{fixtures => Fixtures}/empty.csv | 0 .../Tests/{fixtures => Fixtures}/empty.ini | 0 .../Tests/{fixtures => Fixtures}/empty.json | 0 .../Tests/{fixtures => Fixtures}/empty.mo | 0 .../Tests/{fixtures => Fixtures}/empty.po | 0 .../Tests/{fixtures => Fixtures}/empty.xlf | 0 .../Tests/{fixtures => Fixtures}/empty.yml | 0 .../Tests/{fixtures => Fixtures}/encoding.xlf | 0 .../escaped-id-plurals.po | 0 .../{fixtures => Fixtures}/escaped-id.po | 0 .../extractor-7.3/translation.html.php | 0 .../extractor-ast/resource.format.engine | 0 .../this.is.a.template.format.engine | 0 .../extractor-ast/translatable-fqn.html.php | 0 .../extractor-ast/translatable-short.html.php | 0 .../extractor-ast/translatable.html.php | 0 .../extractor-ast/translation.html.php | 0 .../extractor-ast/validator-constraints.php | 0 .../extractor/resource.format.engine | 0 .../this.is.a.template.format.engine | 0 .../extractor/translatable-fqn.html.php | 0 .../extractor/translatable-short.html.php | 0 .../extractor/translatable.html.php | 0 .../extractor/translation.html.php | 0 .../fuzzy-translations.po | 0 .../invalid-xml-resources.xlf | 0 .../{fixtures => Fixtures}/malformed.json | 0 .../Tests/{fixtures => Fixtures}/messages.yml | 0 .../messages_linear.yml | 0 .../{fixtures => Fixtures}/missing-plurals.po | 0 .../{fixtures => Fixtures}/non-string.yml | 0 .../{fixtures => Fixtures}/non-valid.xlf | 0 .../{fixtures => Fixtures}/non-valid.yml | 0 .../Tests/{fixtures => Fixtures}/plurals.mo | Bin .../Tests/{fixtures => Fixtures}/plurals.po | 0 .../Tests/{fixtures => Fixtures}/resname.xlf | 0 .../resourcebundle/corrupted/resources.dat | 0 .../resourcebundle/dat/en.res | Bin .../resourcebundle/dat/en.txt | 0 .../resourcebundle/dat/fr.res | Bin .../resourcebundle/dat/fr.txt | 0 .../resourcebundle/dat/packagelist.txt | 0 .../resourcebundle/dat/resources.dat | Bin .../resourcebundle/res/en.res | Bin .../resources-2.0+intl-icu.xlf | 0 .../resources-2.0-clean.xlf | 0 .../resources-2.0-multi-segment-unit.xlf | 0 .../resources-2.0-name.xlf | 0 .../{fixtures => Fixtures}/resources-2.0.xlf | 0 .../resources-clean.xlf | 0 .../resources-clean.xliff | 0 .../resources-multi-files.xlf | 0 .../resources-notes-meta.xlf | 0 .../resources-target-attributes.xlf | 0 .../resources-tool-info.xlf | 0 .../{fixtures => Fixtures}/resources.csv | 0 .../resources.dump.json | 0 .../{fixtures => Fixtures}/resources.ini | 0 .../{fixtures => Fixtures}/resources.json | 0 .../Tests/{fixtures => Fixtures}/resources.mo | Bin .../{fixtures => Fixtures}/resources.php | 0 .../Tests/{fixtures => Fixtures}/resources.po | 0 .../Tests/{fixtures => Fixtures}/resources.ts | 0 .../{fixtures => Fixtures}/resources.xlf | 0 .../{fixtures => Fixtures}/resources.yml | 0 .../Tests/{fixtures => Fixtures}/valid.csv | 0 .../with-attributes.xlf | 0 .../{fixtures => Fixtures}/withdoctype.xlf | 0 .../Tests/{fixtures => Fixtures}/withnote.xlf | 0 .../Tests/Loader/CsvFileLoaderTest.php | 6 +- .../Tests/Loader/IcuDatFileLoaderTest.php | 8 +- .../Tests/Loader/IcuResFileLoaderTest.php | 6 +- .../Tests/Loader/IniFileLoaderTest.php | 6 +- .../Tests/Loader/JsonFileLoaderTest.php | 8 +- .../Tests/Loader/MoFileLoaderTest.php | 10 +-- .../Tests/Loader/PhpFileLoaderTest.php | 4 +- .../Tests/Loader/PoFileLoaderTest.php | 18 ++-- .../Tests/Loader/QtFileLoaderTest.php | 8 +- .../Tests/Loader/XliffFileLoaderTest.php | 36 ++++---- .../Tests/Loader/YamlFileLoaderTest.php | 10 +-- .../Translation/Tests/TranslatorTest.php | 18 ++-- .../Tests/Dumper/PlantUmlDumperTest.php | 2 +- .../arrow/complex-state-machine-marking.puml | 0 .../complex-state-machine-nomarking.puml | 0 .../puml/square/complex-workflow-marking.puml | 0 .../square/complex-workflow-nomarking.puml | 0 .../puml/square/simple-workflow-marking.puml | 0 .../square/simple-workflow-nomarking.puml | 0 .../square/simple-workflow-with-spaces.puml | 0 152 files changed, 197 insertions(+), 197 deletions(-) rename src/Symfony/Component/Asset/Tests/{fixtures => Fixtures}/manifest-invalid.json (100%) rename src/Symfony/Component/Asset/Tests/{fixtures => Fixtures}/manifest-valid.json (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/AssetMapperTestAppKernel.php (96%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/assets/vendor/@hotwired/stimulus/stimulus.index.js (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/assets/vendor/installed.php (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/assets/vendor/lodash/lodash.index.js (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/circular_dir/circular1.css (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/circular_dir/circular2.css (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/dir/file9.js (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/dir1/file1.css (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/dir1/file2.js (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/dir2/already-abcdefVWXYZ0123456789.digested.css (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/dir2/file3.css (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/dir2/file4.js (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/dir2/subdir/file5.js (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/dir2/subdir/file6.js (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/dir3/test.gif.foo (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/importmap.php (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/importmaps/assets/app.js (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/importmaps/assets/imported_async.js (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/importmaps/assets/pizza/index.js (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/importmaps/assets/popcorn.js (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/importmaps/assets/vendor/lodash.js (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/importmaps/assets2/app2.js (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/importmaps/assets2/imported.js (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/importmaps/assets2/styles/app.css (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/importmaps/assets2/styles/app2.css (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/importmaps/assets2/styles/other.css (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/importmaps/assets2/styles/other2.css (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/importmaps/assets2/styles/sunshine.css (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/importmaps/importmap.php (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/test_public/final-assets/importmap.json (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/test_public/final-assets/importmap.preload.json (100%) rename src/Symfony/Component/AssetMapper/Tests/{fixtures => Fixtures}/test_public/final-assets/manifest.json (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/empty-translation.mo (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/empty-translation.po (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/empty.csv (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/empty.ini (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/empty.json (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/empty.mo (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/empty.po (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/empty.xlf (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/empty.yml (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/encoding.xlf (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/escaped-id-plurals.po (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/escaped-id.po (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/extractor-7.3/translation.html.php (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/extractor-ast/resource.format.engine (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/extractor-ast/this.is.a.template.format.engine (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/extractor-ast/translatable-fqn.html.php (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/extractor-ast/translatable-short.html.php (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/extractor-ast/translatable.html.php (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/extractor-ast/translation.html.php (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/extractor-ast/validator-constraints.php (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/extractor/resource.format.engine (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/extractor/this.is.a.template.format.engine (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/extractor/translatable-fqn.html.php (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/extractor/translatable-short.html.php (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/extractor/translatable.html.php (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/extractor/translation.html.php (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/fuzzy-translations.po (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/invalid-xml-resources.xlf (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/malformed.json (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/messages.yml (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/messages_linear.yml (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/missing-plurals.po (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/non-string.yml (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/non-valid.xlf (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/non-valid.yml (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/plurals.mo (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/plurals.po (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resname.xlf (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resourcebundle/corrupted/resources.dat (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resourcebundle/dat/en.res (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resourcebundle/dat/en.txt (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resourcebundle/dat/fr.res (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resourcebundle/dat/fr.txt (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resourcebundle/dat/packagelist.txt (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resourcebundle/dat/resources.dat (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resourcebundle/res/en.res (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resources-2.0+intl-icu.xlf (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resources-2.0-clean.xlf (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resources-2.0-multi-segment-unit.xlf (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resources-2.0-name.xlf (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resources-2.0.xlf (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resources-clean.xlf (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resources-clean.xliff (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resources-multi-files.xlf (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resources-notes-meta.xlf (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resources-target-attributes.xlf (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resources-tool-info.xlf (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resources.csv (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resources.dump.json (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resources.ini (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resources.json (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resources.mo (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resources.php (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resources.po (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resources.ts (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resources.xlf (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/resources.yml (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/valid.csv (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/with-attributes.xlf (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/withdoctype.xlf (100%) rename src/Symfony/Component/Translation/Tests/{fixtures => Fixtures}/withnote.xlf (100%) rename src/Symfony/Component/Workflow/Tests/{fixtures => Fixtures}/puml/arrow/complex-state-machine-marking.puml (100%) rename src/Symfony/Component/Workflow/Tests/{fixtures => Fixtures}/puml/arrow/complex-state-machine-nomarking.puml (100%) rename src/Symfony/Component/Workflow/Tests/{fixtures => Fixtures}/puml/square/complex-workflow-marking.puml (100%) rename src/Symfony/Component/Workflow/Tests/{fixtures => Fixtures}/puml/square/complex-workflow-nomarking.puml (100%) rename src/Symfony/Component/Workflow/Tests/{fixtures => Fixtures}/puml/square/simple-workflow-marking.puml (100%) rename src/Symfony/Component/Workflow/Tests/{fixtures => Fixtures}/puml/square/simple-workflow-nomarking.puml (100%) rename src/Symfony/Component/Workflow/Tests/{fixtures => Fixtures}/puml/square/simple-workflow-with-spaces.puml (100%) diff --git a/.php-cs-fixer.dist.php b/.php-cs-fixer.dist.php index 8835d56fb86dd..9d80e236552cd 100644 --- a/.php-cs-fixer.dist.php +++ b/.php-cs-fixer.dist.php @@ -60,7 +60,7 @@ ->notPath('#Symfony/Bridge/PhpUnit/.*Mock\.php#') ->notPath('#Symfony/Bridge/PhpUnit/.*Legacy#') // file content autogenerated by `var_export` - ->notPath('Symfony/Component/Translation/Tests/fixtures/resources.php') + ->notPath('Symfony/Component/Translation/Tests/Fixtures/resources.php') // file content autogenerated by `VarExporter::export` ->notPath('Symfony/Component/Serializer/Tests/Fixtures/serializer.class.metadata.php') // test template diff --git a/src/Symfony/Component/Asset/Tests/fixtures/manifest-invalid.json b/src/Symfony/Component/Asset/Tests/Fixtures/manifest-invalid.json similarity index 100% rename from src/Symfony/Component/Asset/Tests/fixtures/manifest-invalid.json rename to src/Symfony/Component/Asset/Tests/Fixtures/manifest-invalid.json diff --git a/src/Symfony/Component/Asset/Tests/fixtures/manifest-valid.json b/src/Symfony/Component/Asset/Tests/Fixtures/manifest-valid.json similarity index 100% rename from src/Symfony/Component/Asset/Tests/fixtures/manifest-valid.json rename to src/Symfony/Component/Asset/Tests/Fixtures/manifest-valid.json diff --git a/src/Symfony/Component/Asset/Tests/VersionStrategy/JsonManifestVersionStrategyTest.php b/src/Symfony/Component/Asset/Tests/VersionStrategy/JsonManifestVersionStrategyTest.php index 46c7d05daafad..24587ce25a4d9 100644 --- a/src/Symfony/Component/Asset/Tests/VersionStrategy/JsonManifestVersionStrategyTest.php +++ b/src/Symfony/Component/Asset/Tests/VersionStrategy/JsonManifestVersionStrategyTest.php @@ -100,7 +100,7 @@ public static function provideMissingStrategies(): \Generator public static function provideStrategies(string $manifestPath): \Generator { $httpClient = new MockHttpClient(function ($method, $url, $options) { - $filename = __DIR__.'/../fixtures/'.basename($url); + $filename = __DIR__.'/../Fixtures/'.basename($url); if (file_exists($filename)) { return new MockResponse(file_get_contents($filename), ['http_headers' => ['content-type' => 'application/json']]); @@ -111,12 +111,12 @@ public static function provideStrategies(string $manifestPath): \Generator yield [new JsonManifestVersionStrategy('https://cdn.example.com/'.$manifestPath, $httpClient)]; - yield [new JsonManifestVersionStrategy(__DIR__.'/../fixtures/'.$manifestPath)]; + yield [new JsonManifestVersionStrategy(__DIR__.'/../Fixtures/'.$manifestPath)]; } public static function provideStrictStrategies(): \Generator { - $strategy = new JsonManifestVersionStrategy(__DIR__.'/../fixtures/manifest-valid.json', null, true); + $strategy = new JsonManifestVersionStrategy(__DIR__.'/../Fixtures/manifest-valid.json', null, true); yield [ $strategy, diff --git a/src/Symfony/Component/AssetMapper/.gitignore b/src/Symfony/Component/AssetMapper/.gitignore index 8e2a76cfcb804..c7f1fdae683c2 100644 --- a/src/Symfony/Component/AssetMapper/.gitignore +++ b/src/Symfony/Component/AssetMapper/.gitignore @@ -1,4 +1,4 @@ vendor/ composer.lock phpunit.xml -Tests/fixtures/var/ +Tests/Fixtures/var/ diff --git a/src/Symfony/Component/AssetMapper/Tests/AssetMapperDevServerSubscriberFunctionalTest.php b/src/Symfony/Component/AssetMapper/Tests/AssetMapperDevServerSubscriberFunctionalTest.php index b4183b063c720..5a64ab6f9b299 100644 --- a/src/Symfony/Component/AssetMapper/Tests/AssetMapperDevServerSubscriberFunctionalTest.php +++ b/src/Symfony/Component/AssetMapper/Tests/AssetMapperDevServerSubscriberFunctionalTest.php @@ -12,7 +12,7 @@ namespace Symfony\Component\AssetMapper\Tests; use Symfony\Bundle\FrameworkBundle\Test\WebTestCase; -use Symfony\Component\AssetMapper\Tests\fixtures\AssetMapperTestAppKernel; +use Symfony\Component\AssetMapper\Tests\Fixtures\AssetMapperTestAppKernel; class AssetMapperDevServerSubscriberFunctionalTest extends WebTestCase { diff --git a/src/Symfony/Component/AssetMapper/Tests/AssetMapperRepositoryTest.php b/src/Symfony/Component/AssetMapper/Tests/AssetMapperRepositoryTest.php index 721335b32caba..3fe2e9aadeec4 100644 --- a/src/Symfony/Component/AssetMapper/Tests/AssetMapperRepositoryTest.php +++ b/src/Symfony/Component/AssetMapper/Tests/AssetMapperRepositoryTest.php @@ -20,13 +20,13 @@ class AssetMapperRepositoryTest extends TestCase public function testFindWithAbsolutePaths() { $repository = new AssetMapperRepository([ - __DIR__.'/fixtures/dir1' => '', - __DIR__.'/fixtures/dir2' => '', + __DIR__.'/Fixtures/dir1' => '', + __DIR__.'/Fixtures/dir2' => '', ], __DIR__); - $this->assertSame(realpath(__DIR__.'/fixtures/dir1/file1.css'), $repository->find('file1.css')); - $this->assertSame(realpath(__DIR__.'/fixtures/dir2/file4.js'), $repository->find('file4.js')); - $this->assertSame(realpath(__DIR__.'/fixtures/dir2/subdir/file5.js'), $repository->find('subdir/file5.js')); + $this->assertSame(realpath(__DIR__.'/Fixtures/dir1/file1.css'), $repository->find('file1.css')); + $this->assertSame(realpath(__DIR__.'/Fixtures/dir2/file4.js'), $repository->find('file4.js')); + $this->assertSame(realpath(__DIR__.'/Fixtures/dir2/subdir/file5.js'), $repository->find('subdir/file5.js')); $this->assertNull($repository->find('file5.css')); } @@ -35,22 +35,22 @@ public function testFindWithRelativePaths() $repository = new AssetMapperRepository([ 'dir1' => '', 'dir2' => '', - ], __DIR__.'/fixtures'); + ], __DIR__.'/Fixtures'); - $this->assertSame(realpath(__DIR__.'/fixtures/dir1/file1.css'), $repository->find('file1.css')); - $this->assertSame(realpath(__DIR__.'/fixtures/dir2/file4.js'), $repository->find('file4.js')); - $this->assertSame(realpath(__DIR__.'/fixtures/dir2/subdir/file5.js'), $repository->find('subdir/file5.js')); + $this->assertSame(realpath(__DIR__.'/Fixtures/dir1/file1.css'), $repository->find('file1.css')); + $this->assertSame(realpath(__DIR__.'/Fixtures/dir2/file4.js'), $repository->find('file4.js')); + $this->assertSame(realpath(__DIR__.'/Fixtures/dir2/subdir/file5.js'), $repository->find('subdir/file5.js')); $this->assertNull($repository->find('file5.css')); } public function testFindWithMovingPaths() { $repository = new AssetMapperRepository([ - __DIR__.'/../Tests/fixtures/dir2' => '', + __DIR__.'/../Tests/Fixtures/dir2' => '', ], __DIR__); - $this->assertSame(realpath(__DIR__.'/fixtures/dir2/file4.js'), $repository->find('file4.js')); - $this->assertSame(realpath(__DIR__.'/fixtures/dir2/file4.js'), $repository->find('subdir/../file4.js')); + $this->assertSame(realpath(__DIR__.'/Fixtures/dir2/file4.js'), $repository->find('file4.js')); + $this->assertSame(realpath(__DIR__.'/Fixtures/dir2/file4.js'), $repository->find('subdir/../file4.js')); } public function testFindWithNamespaces() @@ -58,11 +58,11 @@ public function testFindWithNamespaces() $repository = new AssetMapperRepository([ 'dir1' => 'dir1_namespace', 'dir2' => 'dir2_namespace', - ], __DIR__.'/fixtures'); + ], __DIR__.'/Fixtures'); - $this->assertSame(realpath(__DIR__.'/fixtures/dir1/file1.css'), $repository->find('dir1_namespace/file1.css')); - $this->assertSame(realpath(__DIR__.'/fixtures/dir2/file4.js'), $repository->find('dir2_namespace/file4.js')); - $this->assertSame(realpath(__DIR__.'/fixtures/dir2/subdir/file5.js'), $repository->find('dir2_namespace/subdir/file5.js')); + $this->assertSame(realpath(__DIR__.'/Fixtures/dir1/file1.css'), $repository->find('dir1_namespace/file1.css')); + $this->assertSame(realpath(__DIR__.'/Fixtures/dir2/file4.js'), $repository->find('dir2_namespace/file4.js')); + $this->assertSame(realpath(__DIR__.'/Fixtures/dir2/subdir/file5.js'), $repository->find('dir2_namespace/subdir/file5.js')); // non-namespaced path does not work $this->assertNull($repository->find('file4.js')); } @@ -73,10 +73,10 @@ public function testFindLogicalPath() 'dir' => '', 'dir1' => 'some_namespace', 'dir2' => '', - ], __DIR__.'/fixtures'); - $this->assertSame('subdir/file5.js', $repository->findLogicalPath(__DIR__.'/fixtures/dir2/subdir/file5.js')); - $this->assertSame('some_namespace/file2.js', $repository->findLogicalPath(__DIR__.'/fixtures/dir1/file2.js')); - $this->assertSame('some_namespace/file2.js', $repository->findLogicalPath(__DIR__.'/../Tests/fixtures/dir1/file2.js')); + ], __DIR__.'/Fixtures'); + $this->assertSame('subdir/file5.js', $repository->findLogicalPath(__DIR__.'/Fixtures/dir2/subdir/file5.js')); + $this->assertSame('some_namespace/file2.js', $repository->findLogicalPath(__DIR__.'/Fixtures/dir1/file2.js')); + $this->assertSame('some_namespace/file2.js', $repository->findLogicalPath(__DIR__.'/../Tests/Fixtures/dir1/file2.js')); } public function testAll() @@ -85,21 +85,21 @@ public function testAll() 'dir1' => '', 'dir2' => '', 'dir3' => '', - ], __DIR__.'/fixtures'); + ], __DIR__.'/Fixtures'); $actualAllAssets = $repository->all(); $this->assertCount(8, $actualAllAssets); // use realpath to normalize slashes on Windows for comparison $expectedAllAssets = array_map('realpath', [ - 'file1.css' => __DIR__.'/fixtures/dir1/file1.css', - 'file2.js' => __DIR__.'/fixtures/dir1/file2.js', - 'already-abcdefVWXYZ0123456789.digested.css' => __DIR__.'/fixtures/dir2/already-abcdefVWXYZ0123456789.digested.css', - 'file3.css' => __DIR__.'/fixtures/dir2/file3.css', - 'file4.js' => __DIR__.'/fixtures/dir2/file4.js', - 'subdir/file5.js' => __DIR__.'/fixtures/dir2/subdir/file5.js', - 'subdir/file6.js' => __DIR__.'/fixtures/dir2/subdir/file6.js', - 'test.gif.foo' => __DIR__.'/fixtures/dir3/test.gif.foo', + 'file1.css' => __DIR__.'/Fixtures/dir1/file1.css', + 'file2.js' => __DIR__.'/Fixtures/dir1/file2.js', + 'already-abcdefVWXYZ0123456789.digested.css' => __DIR__.'/Fixtures/dir2/already-abcdefVWXYZ0123456789.digested.css', + 'file3.css' => __DIR__.'/Fixtures/dir2/file3.css', + 'file4.js' => __DIR__.'/Fixtures/dir2/file4.js', + 'subdir/file5.js' => __DIR__.'/Fixtures/dir2/subdir/file5.js', + 'subdir/file6.js' => __DIR__.'/Fixtures/dir2/subdir/file6.js', + 'test.gif.foo' => __DIR__.'/Fixtures/dir3/test.gif.foo', ]); $this->assertEquals($expectedAllAssets, array_map('realpath', $actualAllAssets)); } @@ -110,17 +110,17 @@ public function testAllWithNamespaces() 'dir1' => 'dir1_namespace', 'dir2' => 'dir2_namespace', 'dir3' => 'dir3_namespace', - ], __DIR__.'/fixtures'); + ], __DIR__.'/Fixtures'); $expectedAllAssets = [ - 'dir1_namespace/file1.css' => __DIR__.'/fixtures/dir1/file1.css', - 'dir1_namespace/file2.js' => __DIR__.'/fixtures/dir1/file2.js', - 'dir2_namespace/already-abcdefVWXYZ0123456789.digested.css' => __DIR__.'/fixtures/dir2/already-abcdefVWXYZ0123456789.digested.css', - 'dir2_namespace/file3.css' => __DIR__.'/fixtures/dir2/file3.css', - 'dir2_namespace/file4.js' => __DIR__.'/fixtures/dir2/file4.js', - 'dir2_namespace/subdir/file5.js' => __DIR__.'/fixtures/dir2/subdir/file5.js', - 'dir2_namespace/subdir/file6.js' => __DIR__.'/fixtures/dir2/subdir/file6.js', - 'dir3_namespace/test.gif.foo' => __DIR__.'/fixtures/dir3/test.gif.foo', + 'dir1_namespace/file1.css' => __DIR__.'/Fixtures/dir1/file1.css', + 'dir1_namespace/file2.js' => __DIR__.'/Fixtures/dir1/file2.js', + 'dir2_namespace/already-abcdefVWXYZ0123456789.digested.css' => __DIR__.'/Fixtures/dir2/already-abcdefVWXYZ0123456789.digested.css', + 'dir2_namespace/file3.css' => __DIR__.'/Fixtures/dir2/file3.css', + 'dir2_namespace/file4.js' => __DIR__.'/Fixtures/dir2/file4.js', + 'dir2_namespace/subdir/file5.js' => __DIR__.'/Fixtures/dir2/subdir/file5.js', + 'dir2_namespace/subdir/file6.js' => __DIR__.'/Fixtures/dir2/subdir/file6.js', + 'dir3_namespace/test.gif.foo' => __DIR__.'/Fixtures/dir3/test.gif.foo', ]; $normalizedExpectedAllAssets = array_map('realpath', $expectedAllAssets); @@ -146,7 +146,7 @@ public function testExcludedPaths() 'dir1' => '', 'dir2' => '', 'dir3' => '', - ], __DIR__.'/fixtures', $excludedGlobs); + ], __DIR__.'/Fixtures', $excludedGlobs); $expectedAssets = [ 'file1.css', @@ -160,6 +160,6 @@ public function testExcludedPaths() $this->assertEquals($expectedAssets, $actualAssets); $this->assertNull($repository->find('file3.css')); - $this->assertNull($repository->findLogicalPath(__DIR__.'/fixtures/dir2/file3.css')); + $this->assertNull($repository->findLogicalPath(__DIR__.'/Fixtures/dir2/file3.css')); } } diff --git a/src/Symfony/Component/AssetMapper/Tests/AssetMapperTest.php b/src/Symfony/Component/AssetMapper/Tests/AssetMapperTest.php index 9705be5b0d1ef..8829089fb93f6 100644 --- a/src/Symfony/Component/AssetMapper/Tests/AssetMapperTest.php +++ b/src/Symfony/Component/AssetMapper/Tests/AssetMapperTest.php @@ -30,7 +30,7 @@ public function testGetAsset() $file1Asset = new MappedAsset('file1.css'); $this->mappedAssetFactory->expects($this->once()) ->method('createMappedAsset') - ->with('file1.css', realpath(__DIR__.'/fixtures/dir1/file1.css')) + ->with('file1.css', realpath(__DIR__.'/Fixtures/dir1/file1.css')) ->willReturn($file1Asset); $actualAsset = $assetMapper->getAsset('file1.css'); @@ -79,21 +79,21 @@ public function testGetAssetFromFilesystemPath() $this->mappedAssetFactory->expects($this->once()) ->method('createMappedAsset') - ->with('file1.css', realpath(__DIR__.'/fixtures/dir1/file1.css')) + ->with('file1.css', realpath(__DIR__.'/Fixtures/dir1/file1.css')) ->willReturn(new MappedAsset('file1.css')); - $asset = $assetMapper->getAssetFromSourcePath(__DIR__.'/fixtures/dir1/file1.css'); + $asset = $assetMapper->getAssetFromSourcePath(__DIR__.'/Fixtures/dir1/file1.css'); $this->assertSame('file1.css', $asset->logicalPath); } private function createAssetMapper(): AssetMapper { $dirs = ['dir1' => '', 'dir2' => '', 'dir3' => '']; - $repository = new AssetMapperRepository($dirs, __DIR__.'/fixtures'); + $repository = new AssetMapperRepository($dirs, __DIR__.'/Fixtures'); $pathResolver = $this->createMock(PublicAssetsPathResolverInterface::class); $pathResolver->expects($this->any()) ->method('getPublicFilesystemPath') - ->willReturn(__DIR__.'/fixtures/test_public/final-assets'); + ->willReturn(__DIR__.'/Fixtures/test_public/final-assets'); $this->mappedAssetFactory = $this->createMock(MappedAssetFactoryInterface::class); diff --git a/src/Symfony/Component/AssetMapper/Tests/Command/AssetMapperCompileCommandTest.php b/src/Symfony/Component/AssetMapper/Tests/Command/AssetMapperCompileCommandTest.php index 544d0c543a034..595f2a7509873 100644 --- a/src/Symfony/Component/AssetMapper/Tests/Command/AssetMapperCompileCommandTest.php +++ b/src/Symfony/Component/AssetMapper/Tests/Command/AssetMapperCompileCommandTest.php @@ -14,7 +14,7 @@ use PHPUnit\Framework\TestCase; use Symfony\Bundle\FrameworkBundle\Console\Application; use Symfony\Component\AssetMapper\Event\PreAssetsCompileEvent; -use Symfony\Component\AssetMapper\Tests\fixtures\AssetMapperTestAppKernel; +use Symfony\Component\AssetMapper\Tests\Fixtures\AssetMapperTestAppKernel; use Symfony\Component\Console\Output\OutputInterface; use Symfony\Component\Console\Tester\CommandTester; use Symfony\Component\EventDispatcher\EventDispatcherInterface; @@ -119,7 +119,7 @@ public function testEventIsDispatched() $listenerCalled = false; $dispatcher->addListener(PreAssetsCompileEvent::class, function (PreAssetsCompileEvent $event) use (&$listenerCalled) { $listenerCalled = true; - $this->assertSame(realpath(__DIR__.'/../fixtures').'/public/assets', $event->getOutputDir()); + $this->assertSame(realpath(__DIR__.'/../Fixtures').'/public/assets', $event->getOutputDir()); $this->assertInstanceOf(OutputInterface::class, $event->getOutput()); }); diff --git a/src/Symfony/Component/AssetMapper/Tests/Command/DebugAssetsMapperCommandTest.php b/src/Symfony/Component/AssetMapper/Tests/Command/DebugAssetsMapperCommandTest.php index 3d91d2f7d2d13..5d2530004096c 100644 --- a/src/Symfony/Component/AssetMapper/Tests/Command/DebugAssetsMapperCommandTest.php +++ b/src/Symfony/Component/AssetMapper/Tests/Command/DebugAssetsMapperCommandTest.php @@ -13,7 +13,7 @@ use PHPUnit\Framework\TestCase; use Symfony\Bundle\FrameworkBundle\Console\Application; -use Symfony\Component\AssetMapper\Tests\fixtures\AssetMapperTestAppKernel; +use Symfony\Component\AssetMapper\Tests\Fixtures\AssetMapperTestAppKernel; use Symfony\Component\Console\Tester\CommandTester; class DebugAssetsMapperCommandTest extends TestCase diff --git a/src/Symfony/Component/AssetMapper/Tests/Factory/CachedMappedAssetFactoryTest.php b/src/Symfony/Component/AssetMapper/Tests/Factory/CachedMappedAssetFactoryTest.php index d334e3863954d..eda4d63802165 100644 --- a/src/Symfony/Component/AssetMapper/Tests/Factory/CachedMappedAssetFactoryTest.php +++ b/src/Symfony/Component/AssetMapper/Tests/Factory/CachedMappedAssetFactoryTest.php @@ -23,7 +23,7 @@ class CachedMappedAssetFactoryTest extends TestCase { private Filesystem $filesystem; - private string $cacheDir = __DIR__.'/../fixtures/var/cache_for_mapped_asset_factory_test'; + private string $cacheDir = __DIR__.'/../Fixtures/var/cache_for_mapped_asset_factory_test'; protected function setUp(): void { @@ -45,7 +45,7 @@ public function testCreateMappedAssetCallsInsideWhenNoCache() true ); - $mappedAsset = new MappedAsset('file1.css', __DIR__.'/../fixtures/dir1/file1.css'); + $mappedAsset = new MappedAsset('file1.css', __DIR__.'/../Fixtures/dir1/file1.css'); $factory->expects($this->once()) ->method('createMappedAsset') @@ -59,12 +59,12 @@ public function testCreateMappedAssetCallsInsideWhenNoCache() $secondActualAsset = $cachedFactory->createMappedAsset('file1.css', '/anything/file1.css'); $this->assertNotSame($mappedAsset, $secondActualAsset); $this->assertSame('file1.css', $secondActualAsset->logicalPath); - $this->assertSame(__DIR__.'/../fixtures/dir1/file1.css', $secondActualAsset->sourcePath); + $this->assertSame(__DIR__.'/../Fixtures/dir1/file1.css', $secondActualAsset->sourcePath); } public function testAssetIsNotBuiltWhenCached() { - $sourcePath = __DIR__.'/../fixtures/dir1/file1.css'; + $sourcePath = __DIR__.'/../Fixtures/dir1/file1.css'; $mappedAsset = new MappedAsset('file1.css', $sourcePath, content: 'cached content'); $this->saveConfigCache($mappedAsset); @@ -85,19 +85,19 @@ public function testAssetIsNotBuiltWhenCached() public function testAssetConfigCacheResourceContainsDependencies() { - $sourcePath = realpath(__DIR__.'/../fixtures/dir1/file1.css'); + $sourcePath = realpath(__DIR__.'/../Fixtures/dir1/file1.css'); $mappedAsset = new MappedAsset('file1.css', $sourcePath, content: 'cached content'); - $dependentOnContentAsset = new MappedAsset('file3.css', realpath(__DIR__.'/../fixtures/dir2/file3.css')); + $dependentOnContentAsset = new MappedAsset('file3.css', realpath(__DIR__.'/../Fixtures/dir2/file3.css')); - $deeplyNestedAsset = new MappedAsset('file4.js', realpath(__DIR__.'/../fixtures/dir2/file4.js')); + $deeplyNestedAsset = new MappedAsset('file4.js', realpath(__DIR__.'/../Fixtures/dir2/file4.js')); $dependentOnContentAsset->addDependency($deeplyNestedAsset); $mappedAsset->addDependency($dependentOnContentAsset); // just adding any file as an example - $mappedAsset->addFileDependency(__DIR__.'/../fixtures/importmap.php'); - $mappedAsset->addFileDependency(__DIR__.'/../fixtures/dir3'); + $mappedAsset->addFileDependency(__DIR__.'/../Fixtures/importmap.php'); + $mappedAsset->addFileDependency(__DIR__.'/../Fixtures/dir3'); $factory = $this->createMock(MappedAssetFactoryInterface::class); $factory->expects($this->once()) @@ -116,7 +116,7 @@ public function testAssetConfigCacheResourceContainsDependencies() $this->assertInstanceOf(FileResource::class, $configCacheMetadata[0]); $this->assertInstanceOf(DirectoryResource::class, $configCacheMetadata[1]); $this->assertInstanceOf(FileResource::class, $configCacheMetadata[2]); - $this->assertSame(realpath(__DIR__.'/../fixtures/importmap.php'), $configCacheMetadata[0]->getResource()); + $this->assertSame(realpath(__DIR__.'/../Fixtures/importmap.php'), $configCacheMetadata[0]->getResource()); $this->assertSame($mappedAsset->sourcePath, $configCacheMetadata[2]->getResource()); $this->assertSame($dependentOnContentAsset->sourcePath, $configCacheMetadata[3]->getResource()); $this->assertSame($deeplyNestedAsset->sourcePath, $configCacheMetadata[4]->getResource()); diff --git a/src/Symfony/Component/AssetMapper/Tests/Factory/MappedAssetFactoryTest.php b/src/Symfony/Component/AssetMapper/Tests/Factory/MappedAssetFactoryTest.php index d4131ae39c377..f6897504e8001 100644 --- a/src/Symfony/Component/AssetMapper/Tests/Factory/MappedAssetFactoryTest.php +++ b/src/Symfony/Component/AssetMapper/Tests/Factory/MappedAssetFactoryTest.php @@ -32,7 +32,7 @@ public function testCreateMappedAsset() { $factory = $this->createFactory(); - $asset = $factory->createMappedAsset('file2.js', __DIR__.'/../fixtures/dir1/file2.js'); + $asset = $factory->createMappedAsset('file2.js', __DIR__.'/../Fixtures/dir1/file2.js'); $this->assertSame('file2.js', $asset->logicalPath); $this->assertMatchesRegularExpression('/^\/final-assets\/file2-[a-zA-Z0-9]{7,128}\.js$/', $asset->publicPath); $this->assertSame('/final-assets/file2.js', $asset->publicPathWithoutDigest); @@ -41,7 +41,7 @@ public function testCreateMappedAsset() public function testCreateMappedAssetRespectsPreDigestedPaths() { $assetMapper = $this->createFactory(); - $asset = $assetMapper->createMappedAsset('already-abcdefVWXYZ0123456789.digested.css', __DIR__.'/../fixtures/dir2/already-abcdefVWXYZ0123456789.digested.css'); + $asset = $assetMapper->createMappedAsset('already-abcdefVWXYZ0123456789.digested.css', __DIR__.'/../Fixtures/dir2/already-abcdefVWXYZ0123456789.digested.css'); $this->assertSame('already-abcdefVWXYZ0123456789.digested.css', $asset->logicalPath); $this->assertSame('/final-assets/already-abcdefVWXYZ0123456789.digested.css', $asset->publicPath); // for pre-digested files, the digest *is* part of the public path @@ -57,11 +57,11 @@ public function testCreateMappedAssetWithContentBasic() EOF; - $asset = $assetMapper->createMappedAsset('file1.css', __DIR__.'/../fixtures/dir1/file1.css'); + $asset = $assetMapper->createMappedAsset('file1.css', __DIR__.'/../Fixtures/dir1/file1.css'); $this->assertSame($expected, $asset->content); // verify internal caching doesn't cause issues - $asset = $assetMapper->createMappedAsset('file1.css', __DIR__.'/../fixtures/dir1/file1.css'); + $asset = $assetMapper->createMappedAsset('file1.css', __DIR__.'/../Fixtures/dir1/file1.css'); $this->assertSame($expected, $asset->content); } @@ -71,7 +71,7 @@ public function testCreateMappedAssetWithContentErrorsOnCircularReferences() $this->expectException(RuntimeException::class); $this->expectExceptionMessage('Circular reference detected while creating asset for "circular1.css": "circular1.css -> circular2.css -> circular1.css".'); - $factory->createMappedAsset('circular1.css', __DIR__.'/../fixtures/circular_dir/circular1.css'); + $factory->createMappedAsset('circular1.css', __DIR__.'/../Fixtures/circular_dir/circular1.css'); } public function testCreateMappedAssetWithDigest() @@ -93,7 +93,7 @@ public function compile(string $content, MappedAsset $asset, AssetMapperInterfac }; $factory = $this->createFactory(); - $asset = $factory->createMappedAsset('subdir/file6.js', __DIR__.'/../fixtures/dir2/subdir/file6.js'); + $asset = $factory->createMappedAsset('subdir/file6.js', __DIR__.'/../Fixtures/dir2/subdir/file6.js'); $this->assertSame('7f983f4053a57f07551fed6099c0da4e', $asset->digest); $this->assertFalse($asset->isPredigested); @@ -101,14 +101,14 @@ public function compile(string $content, MappedAsset $asset, AssetMapperInterfac // since file6.js imports file5.js, the digest for file6 should change, // because, internally, the file path in file6.js to file5.js will need to change $factory = $this->createFactory($file6Compiler); - $asset = $factory->createMappedAsset('subdir/file6.js', __DIR__.'/../fixtures/dir2/subdir/file6.js'); + $asset = $factory->createMappedAsset('subdir/file6.js', __DIR__.'/../Fixtures/dir2/subdir/file6.js'); $this->assertSame('7e4f24ebddd4ab2a3bcf0d89270b9f30', $asset->digest); } public function testCreateMappedAssetWithPredigested() { $assetMapper = $this->createFactory(); - $asset = $assetMapper->createMappedAsset('already-abcdefVWXYZ0123456789.digested.css', __DIR__.'/../fixtures/dir2/already-abcdefVWXYZ0123456789.digested.css'); + $asset = $assetMapper->createMappedAsset('already-abcdefVWXYZ0123456789.digested.css', __DIR__.'/../Fixtures/dir2/already-abcdefVWXYZ0123456789.digested.css'); $this->assertSame('abcdefVWXYZ0123456789.digested', $asset->digest); $this->assertTrue($asset->isPredigested); } @@ -116,7 +116,7 @@ public function testCreateMappedAssetWithPredigested() public function testCreateMappedAssetInVendor() { $assetMapper = $this->createFactory(); - $asset = $assetMapper->createMappedAsset('lodash.js', __DIR__.'/../fixtures/assets/vendor/lodash/lodash.index.js'); + $asset = $assetMapper->createMappedAsset('lodash.js', __DIR__.'/../Fixtures/assets/vendor/lodash/lodash.index.js'); $this->assertSame('lodash.js', $asset->logicalPath); $this->assertTrue($asset->isVendor); } @@ -146,7 +146,7 @@ private function createFactory(AssetCompilerInterface $extraCompiler = null): Ma $factory = new MappedAssetFactory( $pathResolver, $compiler, - __DIR__.'/../fixtures/assets/vendor', + __DIR__.'/../Fixtures/assets/vendor', ); // mock the AssetMapper to behave like normal: by calling back to the factory @@ -154,13 +154,13 @@ private function createFactory(AssetCompilerInterface $extraCompiler = null): Ma $this->assetMapper->expects($this->any()) ->method('getAsset') ->willReturnCallback(function (string $logicalPath) use ($factory) { - $sourcePath = __DIR__.'/../fixtures/dir1/'.$logicalPath; + $sourcePath = __DIR__.'/../Fixtures/dir1/'.$logicalPath; if (!is_file($sourcePath)) { - $sourcePath = __DIR__.'/../fixtures/dir2/'.$logicalPath; + $sourcePath = __DIR__.'/../Fixtures/dir2/'.$logicalPath; } if (!is_file($sourcePath)) { - $sourcePath = __DIR__.'/../fixtures/circular_dir/'.$logicalPath; + $sourcePath = __DIR__.'/../Fixtures/circular_dir/'.$logicalPath; } if (!is_file($sourcePath)) { diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/AssetMapperTestAppKernel.php b/src/Symfony/Component/AssetMapper/Tests/Fixtures/AssetMapperTestAppKernel.php similarity index 96% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/AssetMapperTestAppKernel.php rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/AssetMapperTestAppKernel.php index aed5e2457a753..52092b6bf6eae 100644 --- a/src/Symfony/Component/AssetMapper/Tests/fixtures/AssetMapperTestAppKernel.php +++ b/src/Symfony/Component/AssetMapper/Tests/Fixtures/AssetMapperTestAppKernel.php @@ -9,7 +9,7 @@ * file that was distributed with this source code. */ -namespace Symfony\Component\AssetMapper\Tests\fixtures; +namespace Symfony\Component\AssetMapper\Tests\Fixtures; use Psr\Log\NullLogger; use Symfony\Bundle\FrameworkBundle\FrameworkBundle; diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/assets/vendor/@hotwired/stimulus/stimulus.index.js b/src/Symfony/Component/AssetMapper/Tests/Fixtures/assets/vendor/@hotwired/stimulus/stimulus.index.js similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/assets/vendor/@hotwired/stimulus/stimulus.index.js rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/assets/vendor/@hotwired/stimulus/stimulus.index.js diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/assets/vendor/installed.php b/src/Symfony/Component/AssetMapper/Tests/Fixtures/assets/vendor/installed.php similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/assets/vendor/installed.php rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/assets/vendor/installed.php diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/assets/vendor/lodash/lodash.index.js b/src/Symfony/Component/AssetMapper/Tests/Fixtures/assets/vendor/lodash/lodash.index.js similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/assets/vendor/lodash/lodash.index.js rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/assets/vendor/lodash/lodash.index.js diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/circular_dir/circular1.css b/src/Symfony/Component/AssetMapper/Tests/Fixtures/circular_dir/circular1.css similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/circular_dir/circular1.css rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/circular_dir/circular1.css diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/circular_dir/circular2.css b/src/Symfony/Component/AssetMapper/Tests/Fixtures/circular_dir/circular2.css similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/circular_dir/circular2.css rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/circular_dir/circular2.css diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/dir/file9.js b/src/Symfony/Component/AssetMapper/Tests/Fixtures/dir/file9.js similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/dir/file9.js rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/dir/file9.js diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/dir1/file1.css b/src/Symfony/Component/AssetMapper/Tests/Fixtures/dir1/file1.css similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/dir1/file1.css rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/dir1/file1.css diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/dir1/file2.js b/src/Symfony/Component/AssetMapper/Tests/Fixtures/dir1/file2.js similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/dir1/file2.js rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/dir1/file2.js diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/dir2/already-abcdefVWXYZ0123456789.digested.css b/src/Symfony/Component/AssetMapper/Tests/Fixtures/dir2/already-abcdefVWXYZ0123456789.digested.css similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/dir2/already-abcdefVWXYZ0123456789.digested.css rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/dir2/already-abcdefVWXYZ0123456789.digested.css diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/dir2/file3.css b/src/Symfony/Component/AssetMapper/Tests/Fixtures/dir2/file3.css similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/dir2/file3.css rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/dir2/file3.css diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/dir2/file4.js b/src/Symfony/Component/AssetMapper/Tests/Fixtures/dir2/file4.js similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/dir2/file4.js rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/dir2/file4.js diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/dir2/subdir/file5.js b/src/Symfony/Component/AssetMapper/Tests/Fixtures/dir2/subdir/file5.js similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/dir2/subdir/file5.js rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/dir2/subdir/file5.js diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/dir2/subdir/file6.js b/src/Symfony/Component/AssetMapper/Tests/Fixtures/dir2/subdir/file6.js similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/dir2/subdir/file6.js rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/dir2/subdir/file6.js diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/dir3/test.gif.foo b/src/Symfony/Component/AssetMapper/Tests/Fixtures/dir3/test.gif.foo similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/dir3/test.gif.foo rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/dir3/test.gif.foo diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/importmap.php b/src/Symfony/Component/AssetMapper/Tests/Fixtures/importmap.php similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/importmap.php rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/importmap.php diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets/app.js b/src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets/app.js similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets/app.js rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets/app.js diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets/imported_async.js b/src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets/imported_async.js similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets/imported_async.js rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets/imported_async.js diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets/pizza/index.js b/src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets/pizza/index.js similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets/pizza/index.js rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets/pizza/index.js diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets/popcorn.js b/src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets/popcorn.js similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets/popcorn.js rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets/popcorn.js diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets/vendor/lodash.js b/src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets/vendor/lodash.js similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets/vendor/lodash.js rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets/vendor/lodash.js diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets2/app2.js b/src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets2/app2.js similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets2/app2.js rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets2/app2.js diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets2/imported.js b/src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets2/imported.js similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets2/imported.js rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets2/imported.js diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets2/styles/app.css b/src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets2/styles/app.css similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets2/styles/app.css rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets2/styles/app.css diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets2/styles/app2.css b/src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets2/styles/app2.css similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets2/styles/app2.css rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets2/styles/app2.css diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets2/styles/other.css b/src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets2/styles/other.css similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets2/styles/other.css rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets2/styles/other.css diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets2/styles/other2.css b/src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets2/styles/other2.css similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets2/styles/other2.css rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets2/styles/other2.css diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets2/styles/sunshine.css b/src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets2/styles/sunshine.css similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/assets2/styles/sunshine.css rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/assets2/styles/sunshine.css diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/importmap.php b/src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/importmap.php similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/importmaps/importmap.php rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/importmaps/importmap.php diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/test_public/final-assets/importmap.json b/src/Symfony/Component/AssetMapper/Tests/Fixtures/test_public/final-assets/importmap.json similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/test_public/final-assets/importmap.json rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/test_public/final-assets/importmap.json diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/test_public/final-assets/importmap.preload.json b/src/Symfony/Component/AssetMapper/Tests/Fixtures/test_public/final-assets/importmap.preload.json similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/test_public/final-assets/importmap.preload.json rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/test_public/final-assets/importmap.preload.json diff --git a/src/Symfony/Component/AssetMapper/Tests/fixtures/test_public/final-assets/manifest.json b/src/Symfony/Component/AssetMapper/Tests/Fixtures/test_public/final-assets/manifest.json similarity index 100% rename from src/Symfony/Component/AssetMapper/Tests/fixtures/test_public/final-assets/manifest.json rename to src/Symfony/Component/AssetMapper/Tests/Fixtures/test_public/final-assets/manifest.json diff --git a/src/Symfony/Component/AssetMapper/Tests/ImportMap/ImportMapConfigReaderTest.php b/src/Symfony/Component/AssetMapper/Tests/ImportMap/ImportMapConfigReaderTest.php index 5cfbf76c5e70b..2b5162bd42360 100644 --- a/src/Symfony/Component/AssetMapper/Tests/ImportMap/ImportMapConfigReaderTest.php +++ b/src/Symfony/Component/AssetMapper/Tests/ImportMap/ImportMapConfigReaderTest.php @@ -26,17 +26,17 @@ class ImportMapConfigReaderTest extends TestCase protected function setUp(): void { $this->filesystem = new Filesystem(); - if (!file_exists(__DIR__.'/../fixtures/importmaps_for_writing')) { - $this->filesystem->mkdir(__DIR__.'/../fixtures/importmaps_for_writing'); + if (!file_exists(__DIR__ . '/../Fixtures/importmaps_for_writing')) { + $this->filesystem->mkdir(__DIR__ . '/../Fixtures/importmaps_for_writing'); } - if (!file_exists(__DIR__.'/../fixtures/importmaps_for_writing/assets')) { - $this->filesystem->mkdir(__DIR__.'/../fixtures/importmaps_for_writing/assets'); + if (!file_exists(__DIR__ . '/../Fixtures/importmaps_for_writing/assets')) { + $this->filesystem->mkdir(__DIR__ . '/../Fixtures/importmaps_for_writing/assets'); } } protected function tearDown(): void { - $this->filesystem->remove(__DIR__.'/../fixtures/importmaps_for_writing'); + $this->filesystem->remove(__DIR__ . '/../Fixtures/importmaps_for_writing'); } public function testGetEntriesAndWriteEntries() @@ -63,7 +63,7 @@ public function testGetEntriesAndWriteEntries() ], ]; EOF; - file_put_contents(__DIR__.'/../fixtures/importmaps_for_writing/importmap.php', $importMap); + file_put_contents(__DIR__ . '/../Fixtures/importmaps_for_writing/importmap.php', $importMap); $remotePackageStorage = $this->createMock(RemotePackageStorage::class); $remotePackageStorage->expects($this->any()) @@ -72,7 +72,7 @@ public function testGetEntriesAndWriteEntries() return '/path/to/vendor/'.$packageModuleSpecifier.'.'.$type->value; }); $reader = new ImportMapConfigReader( - __DIR__.'/../fixtures/importmaps_for_writing/importmap.php', + __DIR__ . '/../Fixtures/importmaps_for_writing/importmap.php', $remotePackageStorage, ); $entries = $reader->getEntries(); @@ -100,18 +100,18 @@ public function testGetEntriesAndWriteEntries() $this->assertSame('package/with_file.js', $packageWithFileEntry->packageModuleSpecifier); // now save the original raw data from importmap.php and delete the file - $originalImportMapData = (static fn () => include __DIR__.'/../fixtures/importmaps_for_writing/importmap.php')(); - unlink(__DIR__.'/../fixtures/importmaps_for_writing/importmap.php'); + $originalImportMapData = (static fn () => include __DIR__ . '/../Fixtures/importmaps_for_writing/importmap.php')(); + unlink(__DIR__ . '/../Fixtures/importmaps_for_writing/importmap.php'); // dump the entries back to the file $reader->writeEntries($entries); - $newImportMapData = (static fn () => include __DIR__.'/../fixtures/importmaps_for_writing/importmap.php')(); + $newImportMapData = (static fn () => include __DIR__ . '/../Fixtures/importmaps_for_writing/importmap.php')(); $this->assertSame($originalImportMapData, $newImportMapData); } public function testGetRootDirectory() { - $configReader = new ImportMapConfigReader(__DIR__.'/../fixtures/importmap.php', $this->createMock(RemotePackageStorage::class)); - $this->assertSame(__DIR__.'/../fixtures', $configReader->getRootDirectory()); + $configReader = new ImportMapConfigReader(__DIR__ . '/../Fixtures/importmap.php', $this->createMock(RemotePackageStorage::class)); + $this->assertSame(__DIR__ . '/../Fixtures', $configReader->getRootDirectory()); } } diff --git a/src/Symfony/Component/AssetMapper/Tests/ImportMap/ImportMapManagerTest.php b/src/Symfony/Component/AssetMapper/Tests/ImportMap/ImportMapManagerTest.php index 6c42c6df051e3..a60e70fbae8c9 100644 --- a/src/Symfony/Component/AssetMapper/Tests/ImportMap/ImportMapManagerTest.php +++ b/src/Symfony/Component/AssetMapper/Tests/ImportMap/ImportMapManagerTest.php @@ -38,15 +38,15 @@ class ImportMapManagerTest extends TestCase private ImportMapManager $importMapManager; private Filesystem $filesystem; - private static string $writableRoot = __DIR__.'/../fixtures/importmaps_for_writing'; + private static string $writableRoot = __DIR__ . '/../Fixtures/importmaps_for_writing'; protected function setUp(): void { $this->filesystem = new Filesystem(); - if (!file_exists(__DIR__.'/../fixtures/importmaps_for_writing')) { + if (!file_exists(__DIR__ . '/../Fixtures/importmaps_for_writing')) { $this->filesystem->mkdir(self::$writableRoot); } - if (!file_exists(__DIR__.'/../fixtures/importmaps_for_writing/assets')) { + if (!file_exists(__DIR__ . '/../Fixtures/importmaps_for_writing/assets')) { $this->filesystem->mkdir(self::$writableRoot.'/assets'); } } diff --git a/src/Symfony/Component/AssetMapper/Tests/ImportMap/RemotePackageDownloaderTest.php b/src/Symfony/Component/AssetMapper/Tests/ImportMap/RemotePackageDownloaderTest.php index 89975b6ea61d2..c43f4993e257c 100644 --- a/src/Symfony/Component/AssetMapper/Tests/ImportMap/RemotePackageDownloaderTest.php +++ b/src/Symfony/Component/AssetMapper/Tests/ImportMap/RemotePackageDownloaderTest.php @@ -24,7 +24,7 @@ class RemotePackageDownloaderTest extends TestCase { private Filesystem $filesystem; - private static string $writableRoot = __DIR__.'/../fixtures/importmaps_for_writing'; + private static string $writableRoot = __DIR__ . '/../Fixtures/importmaps_for_writing'; protected function setUp(): void { diff --git a/src/Symfony/Component/AssetMapper/Tests/ImportMap/RemotePackageStorageTest.php b/src/Symfony/Component/AssetMapper/Tests/ImportMap/RemotePackageStorageTest.php index 724f24f124790..d28b0f49ff1a1 100644 --- a/src/Symfony/Component/AssetMapper/Tests/ImportMap/RemotePackageStorageTest.php +++ b/src/Symfony/Component/AssetMapper/Tests/ImportMap/RemotePackageStorageTest.php @@ -20,7 +20,7 @@ class RemotePackageStorageTest extends TestCase { private Filesystem $filesystem; - private static string $writableRoot = __DIR__.'/../fixtures/importmaps_for_writing'; + private static string $writableRoot = __DIR__ . '/../Fixtures/importmaps_for_writing'; protected function setUp(): void { diff --git a/src/Symfony/Component/AssetMapper/Tests/MapperAwareAssetPackageIntegrationTest.php b/src/Symfony/Component/AssetMapper/Tests/MapperAwareAssetPackageIntegrationTest.php index 1f6c627df3aec..28818fd7a6515 100644 --- a/src/Symfony/Component/AssetMapper/Tests/MapperAwareAssetPackageIntegrationTest.php +++ b/src/Symfony/Component/AssetMapper/Tests/MapperAwareAssetPackageIntegrationTest.php @@ -13,7 +13,7 @@ use Symfony\Bundle\FrameworkBundle\Test\KernelTestCase; use Symfony\Component\Asset\Packages; -use Symfony\Component\AssetMapper\Tests\fixtures\AssetMapperTestAppKernel; +use Symfony\Component\AssetMapper\Tests\Fixtures\AssetMapperTestAppKernel; class MapperAwareAssetPackageIntegrationTest extends KernelTestCase { diff --git a/src/Symfony/Component/Translation/Tests/Dumper/CsvFileDumperTest.php b/src/Symfony/Component/Translation/Tests/Dumper/CsvFileDumperTest.php index 0d1cf2c628651..f70c6fdbdd0a3 100644 --- a/src/Symfony/Component/Translation/Tests/Dumper/CsvFileDumperTest.php +++ b/src/Symfony/Component/Translation/Tests/Dumper/CsvFileDumperTest.php @@ -25,6 +25,6 @@ public function testFormatCatalogue() $dumper = new CsvFileDumper(); - $this->assertStringEqualsFile(__DIR__.'/../fixtures/valid.csv', $dumper->formatCatalogue($catalogue, 'messages')); + $this->assertStringEqualsFile(__DIR__ . '/../Fixtures/valid.csv', $dumper->formatCatalogue($catalogue, 'messages')); } } diff --git a/src/Symfony/Component/Translation/Tests/Dumper/IcuResFileDumperTest.php b/src/Symfony/Component/Translation/Tests/Dumper/IcuResFileDumperTest.php index dcb9c2c38f78b..229d048fdf059 100644 --- a/src/Symfony/Component/Translation/Tests/Dumper/IcuResFileDumperTest.php +++ b/src/Symfony/Component/Translation/Tests/Dumper/IcuResFileDumperTest.php @@ -24,6 +24,6 @@ public function testFormatCatalogue() $dumper = new IcuResFileDumper(); - $this->assertStringEqualsFile(__DIR__.'/../fixtures/resourcebundle/res/en.res', $dumper->formatCatalogue($catalogue, 'messages')); + $this->assertStringEqualsFile(__DIR__ . '/../Fixtures/resourcebundle/res/en.res', $dumper->formatCatalogue($catalogue, 'messages')); } } diff --git a/src/Symfony/Component/Translation/Tests/Dumper/IniFileDumperTest.php b/src/Symfony/Component/Translation/Tests/Dumper/IniFileDumperTest.php index 1ed168bdc3a12..caf3ef2d831bd 100644 --- a/src/Symfony/Component/Translation/Tests/Dumper/IniFileDumperTest.php +++ b/src/Symfony/Component/Translation/Tests/Dumper/IniFileDumperTest.php @@ -24,6 +24,6 @@ public function testFormatCatalogue() $dumper = new IniFileDumper(); - $this->assertStringEqualsFile(__DIR__.'/../fixtures/resources.ini', $dumper->formatCatalogue($catalogue, 'messages')); + $this->assertStringEqualsFile(__DIR__ . '/../Fixtures/resources.ini', $dumper->formatCatalogue($catalogue, 'messages')); } } diff --git a/src/Symfony/Component/Translation/Tests/Dumper/JsonFileDumperTest.php b/src/Symfony/Component/Translation/Tests/Dumper/JsonFileDumperTest.php index e353f85d990a6..6fff2888b6aa7 100644 --- a/src/Symfony/Component/Translation/Tests/Dumper/JsonFileDumperTest.php +++ b/src/Symfony/Component/Translation/Tests/Dumper/JsonFileDumperTest.php @@ -24,7 +24,7 @@ public function testFormatCatalogue() $dumper = new JsonFileDumper(); - $this->assertStringEqualsFile(__DIR__.'/../fixtures/resources.json', $dumper->formatCatalogue($catalogue, 'messages')); + $this->assertStringEqualsFile(__DIR__ . '/../Fixtures/resources.json', $dumper->formatCatalogue($catalogue, 'messages')); } public function testDumpWithCustomEncoding() @@ -34,6 +34,6 @@ public function testDumpWithCustomEncoding() $dumper = new JsonFileDumper(); - $this->assertStringEqualsFile(__DIR__.'/../fixtures/resources.dump.json', $dumper->formatCatalogue($catalogue, 'messages', ['json_encoding' => \JSON_HEX_QUOT])); + $this->assertStringEqualsFile(__DIR__ . '/../Fixtures/resources.dump.json', $dumper->formatCatalogue($catalogue, 'messages', ['json_encoding' => \JSON_HEX_QUOT])); } } diff --git a/src/Symfony/Component/Translation/Tests/Dumper/MoFileDumperTest.php b/src/Symfony/Component/Translation/Tests/Dumper/MoFileDumperTest.php index fbbd75dc3b490..6a1e277865970 100644 --- a/src/Symfony/Component/Translation/Tests/Dumper/MoFileDumperTest.php +++ b/src/Symfony/Component/Translation/Tests/Dumper/MoFileDumperTest.php @@ -24,6 +24,6 @@ public function testFormatCatalogue() $dumper = new MoFileDumper(); - $this->assertStringEqualsFile(__DIR__.'/../fixtures/resources.mo', $dumper->formatCatalogue($catalogue, 'messages')); + $this->assertStringEqualsFile(__DIR__ . '/../Fixtures/resources.mo', $dumper->formatCatalogue($catalogue, 'messages')); } } diff --git a/src/Symfony/Component/Translation/Tests/Dumper/PhpFileDumperTest.php b/src/Symfony/Component/Translation/Tests/Dumper/PhpFileDumperTest.php index 00e535da391cd..23c19337503bb 100644 --- a/src/Symfony/Component/Translation/Tests/Dumper/PhpFileDumperTest.php +++ b/src/Symfony/Component/Translation/Tests/Dumper/PhpFileDumperTest.php @@ -24,6 +24,6 @@ public function testFormatCatalogue() $dumper = new PhpFileDumper(); - $this->assertStringEqualsFile(__DIR__.'/../fixtures/resources.php', $dumper->formatCatalogue($catalogue, 'messages')); + $this->assertStringEqualsFile(__DIR__ . '/../Fixtures/resources.php', $dumper->formatCatalogue($catalogue, 'messages')); } } diff --git a/src/Symfony/Component/Translation/Tests/Dumper/PoFileDumperTest.php b/src/Symfony/Component/Translation/Tests/Dumper/PoFileDumperTest.php index 81f35f2d27012..5fecd8b3208ae 100644 --- a/src/Symfony/Component/Translation/Tests/Dumper/PoFileDumperTest.php +++ b/src/Symfony/Component/Translation/Tests/Dumper/PoFileDumperTest.php @@ -43,7 +43,7 @@ public function testFormatCatalogue() $dumper = new PoFileDumper(); - $this->assertStringEqualsFile(__DIR__.'/../fixtures/resources.po', $dumper->formatCatalogue($catalogue, 'messages')); + $this->assertStringEqualsFile(__DIR__ . '/../Fixtures/resources.po', $dumper->formatCatalogue($catalogue, 'messages')); } public function testDumpPlurals() @@ -56,6 +56,6 @@ public function testDumpPlurals() $dumper = new PoFileDumper(); - $this->assertStringEqualsFile(__DIR__.'/../fixtures/plurals.po', $dumper->formatCatalogue($catalogue, 'messages')); + $this->assertStringEqualsFile(__DIR__ . '/../Fixtures/plurals.po', $dumper->formatCatalogue($catalogue, 'messages')); } } diff --git a/src/Symfony/Component/Translation/Tests/Dumper/QtFileDumperTest.php b/src/Symfony/Component/Translation/Tests/Dumper/QtFileDumperTest.php index 6c4b559278277..5bfa85be5904c 100644 --- a/src/Symfony/Component/Translation/Tests/Dumper/QtFileDumperTest.php +++ b/src/Symfony/Component/Translation/Tests/Dumper/QtFileDumperTest.php @@ -43,6 +43,6 @@ public function testFormatCatalogue() $dumper = new QtFileDumper(); - $this->assertStringEqualsFile(__DIR__.'/../fixtures/resources.ts', $dumper->formatCatalogue($catalogue, 'resources')); + $this->assertStringEqualsFile(__DIR__ . '/../Fixtures/resources.ts', $dumper->formatCatalogue($catalogue, 'resources')); } } diff --git a/src/Symfony/Component/Translation/Tests/Dumper/XliffFileDumperTest.php b/src/Symfony/Component/Translation/Tests/Dumper/XliffFileDumperTest.php index 196f232bbef58..3c9f5bef2d877 100644 --- a/src/Symfony/Component/Translation/Tests/Dumper/XliffFileDumperTest.php +++ b/src/Symfony/Component/Translation/Tests/Dumper/XliffFileDumperTest.php @@ -31,7 +31,7 @@ public function testFormatCatalogue() $dumper = new XliffFileDumper(); $this->assertStringEqualsFile( - __DIR__.'/../fixtures/resources-clean.xlf', + __DIR__ . '/../Fixtures/resources-clean.xlf', $dumper->formatCatalogue($catalogue, 'messages', ['default_locale' => 'fr_FR']) ); } @@ -50,7 +50,7 @@ public function testFormatCatalogueXliff2() $dumper = new XliffFileDumper(); $this->assertStringEqualsFile( - __DIR__.'/../fixtures/resources-2.0-clean.xlf', + __DIR__ . '/../Fixtures/resources-2.0-clean.xlf', $dumper->formatCatalogue($catalogue, 'messages', ['default_locale' => 'fr_FR', 'xliff_version' => '2.0']) ); } @@ -65,7 +65,7 @@ public function testFormatIcuCatalogueXliff2() $dumper = new XliffFileDumper(); $this->assertStringEqualsFile( - __DIR__.'/../fixtures/resources-2.0+intl-icu.xlf', + __DIR__ . '/../Fixtures/resources-2.0+intl-icu.xlf', $dumper->formatCatalogue($catalogue, 'messages'.MessageCatalogue::INTL_DOMAIN_SUFFIX, ['default_locale' => 'fr_FR', 'xliff_version' => '2.0']) ); } @@ -83,7 +83,7 @@ public function testFormatCatalogueWithCustomToolInfo() $dumper = new XliffFileDumper(); $this->assertStringEqualsFile( - __DIR__.'/../fixtures/resources-tool-info.xlf', + __DIR__ . '/../Fixtures/resources-tool-info.xlf', $dumper->formatCatalogue($catalogue, 'messages', $options) ); } @@ -99,7 +99,7 @@ public function testFormatCatalogueWithTargetAttributesMetadata() $dumper = new XliffFileDumper(); $this->assertStringEqualsFile( - __DIR__.'/../fixtures/resources-target-attributes.xlf', + __DIR__ . '/../Fixtures/resources-target-attributes.xlf', $dumper->formatCatalogue($catalogue, 'messages', ['default_locale' => 'fr_FR']) ); } @@ -124,7 +124,7 @@ public function testFormatCatalogueWithNotesMetadata() $dumper = new XliffFileDumper(); $this->assertStringEqualsFile( - __DIR__.'/../fixtures/resources-notes-meta.xlf', + __DIR__ . '/../Fixtures/resources-notes-meta.xlf', $dumper->formatCatalogue($catalogue, 'messages', ['default_locale' => 'fr_FR', 'xliff_version' => '2.0']) ); } @@ -143,7 +143,7 @@ public function testDumpCatalogueWithXliffExtension() $dumper = new XliffFileDumper('xliff'); $this->assertStringEqualsFile( - __DIR__.'/../fixtures/resources-clean.xliff', + __DIR__ . '/../Fixtures/resources-clean.xliff', $dumper->formatCatalogue($catalogue, 'messages', ['default_locale' => 'fr_FR']) ); } diff --git a/src/Symfony/Component/Translation/Tests/Dumper/YamlFileDumperTest.php b/src/Symfony/Component/Translation/Tests/Dumper/YamlFileDumperTest.php index e46da5a7e8089..6ecb2c3344209 100644 --- a/src/Symfony/Component/Translation/Tests/Dumper/YamlFileDumperTest.php +++ b/src/Symfony/Component/Translation/Tests/Dumper/YamlFileDumperTest.php @@ -27,7 +27,7 @@ public function testTreeFormatCatalogue() $dumper = new YamlFileDumper(); - $this->assertStringEqualsFile(__DIR__.'/../fixtures/messages.yml', $dumper->formatCatalogue($catalogue, 'messages', ['as_tree' => true, 'inline' => 999])); + $this->assertStringEqualsFile(__DIR__ . '/../Fixtures/messages.yml', $dumper->formatCatalogue($catalogue, 'messages', ['as_tree' => true, 'inline' => 999])); } public function testLinearFormatCatalogue() @@ -40,6 +40,6 @@ public function testLinearFormatCatalogue() $dumper = new YamlFileDumper(); - $this->assertStringEqualsFile(__DIR__.'/../fixtures/messages_linear.yml', $dumper->formatCatalogue($catalogue, 'messages')); + $this->assertStringEqualsFile(__DIR__ . '/../Fixtures/messages_linear.yml', $dumper->formatCatalogue($catalogue, 'messages')); } } diff --git a/src/Symfony/Component/Translation/Tests/Extractor/PhpAstExtractorTest.php b/src/Symfony/Component/Translation/Tests/Extractor/PhpAstExtractorTest.php index 96a12bd216ca9..380bdee26bc99 100644 --- a/src/Symfony/Component/Translation/Tests/Extractor/PhpAstExtractorTest.php +++ b/src/Symfony/Component/Translation/Tests/Extractor/PhpAstExtractorTest.php @@ -144,19 +144,19 @@ public function testExtraction(iterable|string $resource) $this->assertEquals($expectedCatalogue, $actualCatalogue); - $filename = str_replace(\DIRECTORY_SEPARATOR, '/', __DIR__).'/../fixtures/extractor-ast/translatable.html.php'; + $filename = str_replace(\DIRECTORY_SEPARATOR, '/', __DIR__).'/../Fixtures/extractor-ast/translatable.html.php'; $this->assertEquals(['sources' => [$filename.':2']], $catalogue->getMetadata('translatable single-quoted key')); $this->assertEquals(['sources' => [$filename.':37']], $catalogue->getMetadata('translatable other-domain-test-no-params-short-array', 'not_messages')); - $filename = str_replace(\DIRECTORY_SEPARATOR, '/', __DIR__).'/../fixtures/extractor-ast/translatable-fqn.html.php'; + $filename = str_replace(\DIRECTORY_SEPARATOR, '/', __DIR__).'/../Fixtures/extractor-ast/translatable-fqn.html.php'; $this->assertEquals(['sources' => [$filename.':2']], $catalogue->getMetadata('translatable-fqn single-quoted key')); $this->assertEquals(['sources' => [$filename.':37']], $catalogue->getMetadata('translatable-fqn other-domain-test-no-params-short-array', 'not_messages')); - $filename = str_replace(\DIRECTORY_SEPARATOR, '/', __DIR__).'/../fixtures/extractor-ast/translatable-short.html.php'; + $filename = str_replace(\DIRECTORY_SEPARATOR, '/', __DIR__).'/../Fixtures/extractor-ast/translatable-short.html.php'; $this->assertEquals(['sources' => [$filename.':2']], $catalogue->getMetadata('translatable-short single-quoted key')); $this->assertEquals(['sources' => [$filename.':37']], $catalogue->getMetadata('translatable-short other-domain-test-no-params-short-array', 'not_messages')); - $filename = str_replace(\DIRECTORY_SEPARATOR, '/', __DIR__).'/../fixtures/extractor-ast/translation.html.php'; + $filename = str_replace(\DIRECTORY_SEPARATOR, '/', __DIR__).'/../Fixtures/extractor-ast/translation.html.php'; $this->assertEquals(['sources' => [$filename.':2']], $catalogue->getMetadata('single-quoted key')); $this->assertEquals(['sources' => [$filename.':37']], $catalogue->getMetadata('other-domain-test-no-params-short-array', 'not_messages')); } @@ -175,7 +175,7 @@ public function testExtractionFromIndentedHeredocNowdoc() ], new TranslatableMessageVisitor()), ]); $extractor->setPrefix('prefix'); - $extractor->extract(__DIR__.'/../fixtures/extractor-7.3/translation.html.php', $catalogue); + $extractor->extract(__DIR__ . '/../Fixtures/extractor-7.3/translation.html.php', $catalogue); $expectedCatalogue = [ 'messages' => [ @@ -189,7 +189,7 @@ public function testExtractionFromIndentedHeredocNowdoc() public static function resourcesProvider(): array { - $directory = __DIR__.'/../fixtures/extractor-ast/'; + $directory = __DIR__ . '/../Fixtures/extractor-ast/'; $phpFiles = []; $splFiles = []; foreach (new \DirectoryIterator($directory) as $fileInfo) { diff --git a/src/Symfony/Component/Translation/Tests/Extractor/PhpExtractorTest.php b/src/Symfony/Component/Translation/Tests/Extractor/PhpExtractorTest.php index 07fc136d0f941..85d538f929837 100644 --- a/src/Symfony/Component/Translation/Tests/Extractor/PhpExtractorTest.php +++ b/src/Symfony/Component/Translation/Tests/Extractor/PhpExtractorTest.php @@ -116,19 +116,19 @@ public function testExtraction($resource) $this->assertEquals($expectedCatalogue, $actualCatalogue); - $filename = str_replace(\DIRECTORY_SEPARATOR, '/', __DIR__).'/../fixtures/extractor/translatable.html.php'; + $filename = str_replace(\DIRECTORY_SEPARATOR, '/', __DIR__).'/../Fixtures/extractor/translatable.html.php'; $this->assertEquals(['sources' => [$filename.':2']], $catalogue->getMetadata('translatable single-quoted key')); $this->assertEquals(['sources' => [$filename.':37']], $catalogue->getMetadata('translatable other-domain-test-no-params-short-array', 'not_messages')); - $filename = str_replace(\DIRECTORY_SEPARATOR, '/', __DIR__).'/../fixtures/extractor/translatable-fqn.html.php'; + $filename = str_replace(\DIRECTORY_SEPARATOR, '/', __DIR__).'/../Fixtures/extractor/translatable-fqn.html.php'; $this->assertEquals(['sources' => [$filename.':2']], $catalogue->getMetadata('translatable-fqn single-quoted key')); $this->assertEquals(['sources' => [$filename.':37']], $catalogue->getMetadata('translatable-fqn other-domain-test-no-params-short-array', 'not_messages')); - $filename = str_replace(\DIRECTORY_SEPARATOR, '/', __DIR__).'/../fixtures/extractor/translatable-short.html.php'; + $filename = str_replace(\DIRECTORY_SEPARATOR, '/', __DIR__).'/../Fixtures/extractor/translatable-short.html.php'; $this->assertEquals(['sources' => [$filename.':2']], $catalogue->getMetadata('translatable-short single-quoted key')); $this->assertEquals(['sources' => [$filename.':37']], $catalogue->getMetadata('translatable-short other-domain-test-no-params-short-array', 'not_messages')); - $filename = str_replace(\DIRECTORY_SEPARATOR, '/', __DIR__).'/../fixtures/extractor/translation.html.php'; + $filename = str_replace(\DIRECTORY_SEPARATOR, '/', __DIR__).'/../Fixtures/extractor/translation.html.php'; $this->assertEquals(['sources' => [$filename.':2']], $catalogue->getMetadata('single-quoted key')); $this->assertEquals(['sources' => [$filename.':37']], $catalogue->getMetadata('other-domain-test-no-params-short-array', 'not_messages')); } @@ -139,7 +139,7 @@ public function testExtractionFromIndentedHeredocNowdoc() $extractor = new PhpExtractor(); $extractor->setPrefix('prefix'); - $extractor->extract(__DIR__.'/../fixtures/extractor-7.3/translation.html.php', $catalogue); + $extractor->extract(__DIR__ . '/../Fixtures/extractor-7.3/translation.html.php', $catalogue); $expectedCatalogue = [ 'messages' => [ @@ -153,7 +153,7 @@ public function testExtractionFromIndentedHeredocNowdoc() public static function resourcesProvider() { - $directory = __DIR__.'/../fixtures/extractor/'; + $directory = __DIR__ . '/../Fixtures/extractor/'; $phpFiles = []; $splFiles = []; foreach (new \DirectoryIterator($directory) as $fileInfo) { diff --git a/src/Symfony/Component/Translation/Tests/fixtures/empty-translation.mo b/src/Symfony/Component/Translation/Tests/Fixtures/empty-translation.mo similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/empty-translation.mo rename to src/Symfony/Component/Translation/Tests/Fixtures/empty-translation.mo diff --git a/src/Symfony/Component/Translation/Tests/fixtures/empty-translation.po b/src/Symfony/Component/Translation/Tests/Fixtures/empty-translation.po similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/empty-translation.po rename to src/Symfony/Component/Translation/Tests/Fixtures/empty-translation.po diff --git a/src/Symfony/Component/Translation/Tests/fixtures/empty.csv b/src/Symfony/Component/Translation/Tests/Fixtures/empty.csv similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/empty.csv rename to src/Symfony/Component/Translation/Tests/Fixtures/empty.csv diff --git a/src/Symfony/Component/Translation/Tests/fixtures/empty.ini b/src/Symfony/Component/Translation/Tests/Fixtures/empty.ini similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/empty.ini rename to src/Symfony/Component/Translation/Tests/Fixtures/empty.ini diff --git a/src/Symfony/Component/Translation/Tests/fixtures/empty.json b/src/Symfony/Component/Translation/Tests/Fixtures/empty.json similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/empty.json rename to src/Symfony/Component/Translation/Tests/Fixtures/empty.json diff --git a/src/Symfony/Component/Translation/Tests/fixtures/empty.mo b/src/Symfony/Component/Translation/Tests/Fixtures/empty.mo similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/empty.mo rename to src/Symfony/Component/Translation/Tests/Fixtures/empty.mo diff --git a/src/Symfony/Component/Translation/Tests/fixtures/empty.po b/src/Symfony/Component/Translation/Tests/Fixtures/empty.po similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/empty.po rename to src/Symfony/Component/Translation/Tests/Fixtures/empty.po diff --git a/src/Symfony/Component/Translation/Tests/fixtures/empty.xlf b/src/Symfony/Component/Translation/Tests/Fixtures/empty.xlf similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/empty.xlf rename to src/Symfony/Component/Translation/Tests/Fixtures/empty.xlf diff --git a/src/Symfony/Component/Translation/Tests/fixtures/empty.yml b/src/Symfony/Component/Translation/Tests/Fixtures/empty.yml similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/empty.yml rename to src/Symfony/Component/Translation/Tests/Fixtures/empty.yml diff --git a/src/Symfony/Component/Translation/Tests/fixtures/encoding.xlf b/src/Symfony/Component/Translation/Tests/Fixtures/encoding.xlf similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/encoding.xlf rename to src/Symfony/Component/Translation/Tests/Fixtures/encoding.xlf diff --git a/src/Symfony/Component/Translation/Tests/fixtures/escaped-id-plurals.po b/src/Symfony/Component/Translation/Tests/Fixtures/escaped-id-plurals.po similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/escaped-id-plurals.po rename to src/Symfony/Component/Translation/Tests/Fixtures/escaped-id-plurals.po diff --git a/src/Symfony/Component/Translation/Tests/fixtures/escaped-id.po b/src/Symfony/Component/Translation/Tests/Fixtures/escaped-id.po similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/escaped-id.po rename to src/Symfony/Component/Translation/Tests/Fixtures/escaped-id.po diff --git a/src/Symfony/Component/Translation/Tests/fixtures/extractor-7.3/translation.html.php b/src/Symfony/Component/Translation/Tests/Fixtures/extractor-7.3/translation.html.php similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/extractor-7.3/translation.html.php rename to src/Symfony/Component/Translation/Tests/Fixtures/extractor-7.3/translation.html.php diff --git a/src/Symfony/Component/Translation/Tests/fixtures/extractor-ast/resource.format.engine b/src/Symfony/Component/Translation/Tests/Fixtures/extractor-ast/resource.format.engine similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/extractor-ast/resource.format.engine rename to src/Symfony/Component/Translation/Tests/Fixtures/extractor-ast/resource.format.engine diff --git a/src/Symfony/Component/Translation/Tests/fixtures/extractor-ast/this.is.a.template.format.engine b/src/Symfony/Component/Translation/Tests/Fixtures/extractor-ast/this.is.a.template.format.engine similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/extractor-ast/this.is.a.template.format.engine rename to src/Symfony/Component/Translation/Tests/Fixtures/extractor-ast/this.is.a.template.format.engine diff --git a/src/Symfony/Component/Translation/Tests/fixtures/extractor-ast/translatable-fqn.html.php b/src/Symfony/Component/Translation/Tests/Fixtures/extractor-ast/translatable-fqn.html.php similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/extractor-ast/translatable-fqn.html.php rename to src/Symfony/Component/Translation/Tests/Fixtures/extractor-ast/translatable-fqn.html.php diff --git a/src/Symfony/Component/Translation/Tests/fixtures/extractor-ast/translatable-short.html.php b/src/Symfony/Component/Translation/Tests/Fixtures/extractor-ast/translatable-short.html.php similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/extractor-ast/translatable-short.html.php rename to src/Symfony/Component/Translation/Tests/Fixtures/extractor-ast/translatable-short.html.php diff --git a/src/Symfony/Component/Translation/Tests/fixtures/extractor-ast/translatable.html.php b/src/Symfony/Component/Translation/Tests/Fixtures/extractor-ast/translatable.html.php similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/extractor-ast/translatable.html.php rename to src/Symfony/Component/Translation/Tests/Fixtures/extractor-ast/translatable.html.php diff --git a/src/Symfony/Component/Translation/Tests/fixtures/extractor-ast/translation.html.php b/src/Symfony/Component/Translation/Tests/Fixtures/extractor-ast/translation.html.php similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/extractor-ast/translation.html.php rename to src/Symfony/Component/Translation/Tests/Fixtures/extractor-ast/translation.html.php diff --git a/src/Symfony/Component/Translation/Tests/fixtures/extractor-ast/validator-constraints.php b/src/Symfony/Component/Translation/Tests/Fixtures/extractor-ast/validator-constraints.php similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/extractor-ast/validator-constraints.php rename to src/Symfony/Component/Translation/Tests/Fixtures/extractor-ast/validator-constraints.php diff --git a/src/Symfony/Component/Translation/Tests/fixtures/extractor/resource.format.engine b/src/Symfony/Component/Translation/Tests/Fixtures/extractor/resource.format.engine similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/extractor/resource.format.engine rename to src/Symfony/Component/Translation/Tests/Fixtures/extractor/resource.format.engine diff --git a/src/Symfony/Component/Translation/Tests/fixtures/extractor/this.is.a.template.format.engine b/src/Symfony/Component/Translation/Tests/Fixtures/extractor/this.is.a.template.format.engine similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/extractor/this.is.a.template.format.engine rename to src/Symfony/Component/Translation/Tests/Fixtures/extractor/this.is.a.template.format.engine diff --git a/src/Symfony/Component/Translation/Tests/fixtures/extractor/translatable-fqn.html.php b/src/Symfony/Component/Translation/Tests/Fixtures/extractor/translatable-fqn.html.php similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/extractor/translatable-fqn.html.php rename to src/Symfony/Component/Translation/Tests/Fixtures/extractor/translatable-fqn.html.php diff --git a/src/Symfony/Component/Translation/Tests/fixtures/extractor/translatable-short.html.php b/src/Symfony/Component/Translation/Tests/Fixtures/extractor/translatable-short.html.php similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/extractor/translatable-short.html.php rename to src/Symfony/Component/Translation/Tests/Fixtures/extractor/translatable-short.html.php diff --git a/src/Symfony/Component/Translation/Tests/fixtures/extractor/translatable.html.php b/src/Symfony/Component/Translation/Tests/Fixtures/extractor/translatable.html.php similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/extractor/translatable.html.php rename to src/Symfony/Component/Translation/Tests/Fixtures/extractor/translatable.html.php diff --git a/src/Symfony/Component/Translation/Tests/fixtures/extractor/translation.html.php b/src/Symfony/Component/Translation/Tests/Fixtures/extractor/translation.html.php similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/extractor/translation.html.php rename to src/Symfony/Component/Translation/Tests/Fixtures/extractor/translation.html.php diff --git a/src/Symfony/Component/Translation/Tests/fixtures/fuzzy-translations.po b/src/Symfony/Component/Translation/Tests/Fixtures/fuzzy-translations.po similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/fuzzy-translations.po rename to src/Symfony/Component/Translation/Tests/Fixtures/fuzzy-translations.po diff --git a/src/Symfony/Component/Translation/Tests/fixtures/invalid-xml-resources.xlf b/src/Symfony/Component/Translation/Tests/Fixtures/invalid-xml-resources.xlf similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/invalid-xml-resources.xlf rename to src/Symfony/Component/Translation/Tests/Fixtures/invalid-xml-resources.xlf diff --git a/src/Symfony/Component/Translation/Tests/fixtures/malformed.json b/src/Symfony/Component/Translation/Tests/Fixtures/malformed.json similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/malformed.json rename to src/Symfony/Component/Translation/Tests/Fixtures/malformed.json diff --git a/src/Symfony/Component/Translation/Tests/fixtures/messages.yml b/src/Symfony/Component/Translation/Tests/Fixtures/messages.yml similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/messages.yml rename to src/Symfony/Component/Translation/Tests/Fixtures/messages.yml diff --git a/src/Symfony/Component/Translation/Tests/fixtures/messages_linear.yml b/src/Symfony/Component/Translation/Tests/Fixtures/messages_linear.yml similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/messages_linear.yml rename to src/Symfony/Component/Translation/Tests/Fixtures/messages_linear.yml diff --git a/src/Symfony/Component/Translation/Tests/fixtures/missing-plurals.po b/src/Symfony/Component/Translation/Tests/Fixtures/missing-plurals.po similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/missing-plurals.po rename to src/Symfony/Component/Translation/Tests/Fixtures/missing-plurals.po diff --git a/src/Symfony/Component/Translation/Tests/fixtures/non-string.yml b/src/Symfony/Component/Translation/Tests/Fixtures/non-string.yml similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/non-string.yml rename to src/Symfony/Component/Translation/Tests/Fixtures/non-string.yml diff --git a/src/Symfony/Component/Translation/Tests/fixtures/non-valid.xlf b/src/Symfony/Component/Translation/Tests/Fixtures/non-valid.xlf similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/non-valid.xlf rename to src/Symfony/Component/Translation/Tests/Fixtures/non-valid.xlf diff --git a/src/Symfony/Component/Translation/Tests/fixtures/non-valid.yml b/src/Symfony/Component/Translation/Tests/Fixtures/non-valid.yml similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/non-valid.yml rename to src/Symfony/Component/Translation/Tests/Fixtures/non-valid.yml diff --git a/src/Symfony/Component/Translation/Tests/fixtures/plurals.mo b/src/Symfony/Component/Translation/Tests/Fixtures/plurals.mo similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/plurals.mo rename to src/Symfony/Component/Translation/Tests/Fixtures/plurals.mo diff --git a/src/Symfony/Component/Translation/Tests/fixtures/plurals.po b/src/Symfony/Component/Translation/Tests/Fixtures/plurals.po similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/plurals.po rename to src/Symfony/Component/Translation/Tests/Fixtures/plurals.po diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resname.xlf b/src/Symfony/Component/Translation/Tests/Fixtures/resname.xlf similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resname.xlf rename to src/Symfony/Component/Translation/Tests/Fixtures/resname.xlf diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resourcebundle/corrupted/resources.dat b/src/Symfony/Component/Translation/Tests/Fixtures/resourcebundle/corrupted/resources.dat similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resourcebundle/corrupted/resources.dat rename to src/Symfony/Component/Translation/Tests/Fixtures/resourcebundle/corrupted/resources.dat diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resourcebundle/dat/en.res b/src/Symfony/Component/Translation/Tests/Fixtures/resourcebundle/dat/en.res similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resourcebundle/dat/en.res rename to src/Symfony/Component/Translation/Tests/Fixtures/resourcebundle/dat/en.res diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resourcebundle/dat/en.txt b/src/Symfony/Component/Translation/Tests/Fixtures/resourcebundle/dat/en.txt similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resourcebundle/dat/en.txt rename to src/Symfony/Component/Translation/Tests/Fixtures/resourcebundle/dat/en.txt diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resourcebundle/dat/fr.res b/src/Symfony/Component/Translation/Tests/Fixtures/resourcebundle/dat/fr.res similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resourcebundle/dat/fr.res rename to src/Symfony/Component/Translation/Tests/Fixtures/resourcebundle/dat/fr.res diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resourcebundle/dat/fr.txt b/src/Symfony/Component/Translation/Tests/Fixtures/resourcebundle/dat/fr.txt similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resourcebundle/dat/fr.txt rename to src/Symfony/Component/Translation/Tests/Fixtures/resourcebundle/dat/fr.txt diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resourcebundle/dat/packagelist.txt b/src/Symfony/Component/Translation/Tests/Fixtures/resourcebundle/dat/packagelist.txt similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resourcebundle/dat/packagelist.txt rename to src/Symfony/Component/Translation/Tests/Fixtures/resourcebundle/dat/packagelist.txt diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resourcebundle/dat/resources.dat b/src/Symfony/Component/Translation/Tests/Fixtures/resourcebundle/dat/resources.dat similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resourcebundle/dat/resources.dat rename to src/Symfony/Component/Translation/Tests/Fixtures/resourcebundle/dat/resources.dat diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resourcebundle/res/en.res b/src/Symfony/Component/Translation/Tests/Fixtures/resourcebundle/res/en.res similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resourcebundle/res/en.res rename to src/Symfony/Component/Translation/Tests/Fixtures/resourcebundle/res/en.res diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resources-2.0+intl-icu.xlf b/src/Symfony/Component/Translation/Tests/Fixtures/resources-2.0+intl-icu.xlf similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resources-2.0+intl-icu.xlf rename to src/Symfony/Component/Translation/Tests/Fixtures/resources-2.0+intl-icu.xlf diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resources-2.0-clean.xlf b/src/Symfony/Component/Translation/Tests/Fixtures/resources-2.0-clean.xlf similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resources-2.0-clean.xlf rename to src/Symfony/Component/Translation/Tests/Fixtures/resources-2.0-clean.xlf diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resources-2.0-multi-segment-unit.xlf b/src/Symfony/Component/Translation/Tests/Fixtures/resources-2.0-multi-segment-unit.xlf similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resources-2.0-multi-segment-unit.xlf rename to src/Symfony/Component/Translation/Tests/Fixtures/resources-2.0-multi-segment-unit.xlf diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resources-2.0-name.xlf b/src/Symfony/Component/Translation/Tests/Fixtures/resources-2.0-name.xlf similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resources-2.0-name.xlf rename to src/Symfony/Component/Translation/Tests/Fixtures/resources-2.0-name.xlf diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resources-2.0.xlf b/src/Symfony/Component/Translation/Tests/Fixtures/resources-2.0.xlf similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resources-2.0.xlf rename to src/Symfony/Component/Translation/Tests/Fixtures/resources-2.0.xlf diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resources-clean.xlf b/src/Symfony/Component/Translation/Tests/Fixtures/resources-clean.xlf similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resources-clean.xlf rename to src/Symfony/Component/Translation/Tests/Fixtures/resources-clean.xlf diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resources-clean.xliff b/src/Symfony/Component/Translation/Tests/Fixtures/resources-clean.xliff similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resources-clean.xliff rename to src/Symfony/Component/Translation/Tests/Fixtures/resources-clean.xliff diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resources-multi-files.xlf b/src/Symfony/Component/Translation/Tests/Fixtures/resources-multi-files.xlf similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resources-multi-files.xlf rename to src/Symfony/Component/Translation/Tests/Fixtures/resources-multi-files.xlf diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resources-notes-meta.xlf b/src/Symfony/Component/Translation/Tests/Fixtures/resources-notes-meta.xlf similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resources-notes-meta.xlf rename to src/Symfony/Component/Translation/Tests/Fixtures/resources-notes-meta.xlf diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resources-target-attributes.xlf b/src/Symfony/Component/Translation/Tests/Fixtures/resources-target-attributes.xlf similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resources-target-attributes.xlf rename to src/Symfony/Component/Translation/Tests/Fixtures/resources-target-attributes.xlf diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resources-tool-info.xlf b/src/Symfony/Component/Translation/Tests/Fixtures/resources-tool-info.xlf similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resources-tool-info.xlf rename to src/Symfony/Component/Translation/Tests/Fixtures/resources-tool-info.xlf diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resources.csv b/src/Symfony/Component/Translation/Tests/Fixtures/resources.csv similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resources.csv rename to src/Symfony/Component/Translation/Tests/Fixtures/resources.csv diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resources.dump.json b/src/Symfony/Component/Translation/Tests/Fixtures/resources.dump.json similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resources.dump.json rename to src/Symfony/Component/Translation/Tests/Fixtures/resources.dump.json diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resources.ini b/src/Symfony/Component/Translation/Tests/Fixtures/resources.ini similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resources.ini rename to src/Symfony/Component/Translation/Tests/Fixtures/resources.ini diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resources.json b/src/Symfony/Component/Translation/Tests/Fixtures/resources.json similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resources.json rename to src/Symfony/Component/Translation/Tests/Fixtures/resources.json diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resources.mo b/src/Symfony/Component/Translation/Tests/Fixtures/resources.mo similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resources.mo rename to src/Symfony/Component/Translation/Tests/Fixtures/resources.mo diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resources.php b/src/Symfony/Component/Translation/Tests/Fixtures/resources.php similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resources.php rename to src/Symfony/Component/Translation/Tests/Fixtures/resources.php diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resources.po b/src/Symfony/Component/Translation/Tests/Fixtures/resources.po similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resources.po rename to src/Symfony/Component/Translation/Tests/Fixtures/resources.po diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resources.ts b/src/Symfony/Component/Translation/Tests/Fixtures/resources.ts similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resources.ts rename to src/Symfony/Component/Translation/Tests/Fixtures/resources.ts diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resources.xlf b/src/Symfony/Component/Translation/Tests/Fixtures/resources.xlf similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resources.xlf rename to src/Symfony/Component/Translation/Tests/Fixtures/resources.xlf diff --git a/src/Symfony/Component/Translation/Tests/fixtures/resources.yml b/src/Symfony/Component/Translation/Tests/Fixtures/resources.yml similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/resources.yml rename to src/Symfony/Component/Translation/Tests/Fixtures/resources.yml diff --git a/src/Symfony/Component/Translation/Tests/fixtures/valid.csv b/src/Symfony/Component/Translation/Tests/Fixtures/valid.csv similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/valid.csv rename to src/Symfony/Component/Translation/Tests/Fixtures/valid.csv diff --git a/src/Symfony/Component/Translation/Tests/fixtures/with-attributes.xlf b/src/Symfony/Component/Translation/Tests/Fixtures/with-attributes.xlf similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/with-attributes.xlf rename to src/Symfony/Component/Translation/Tests/Fixtures/with-attributes.xlf diff --git a/src/Symfony/Component/Translation/Tests/fixtures/withdoctype.xlf b/src/Symfony/Component/Translation/Tests/Fixtures/withdoctype.xlf similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/withdoctype.xlf rename to src/Symfony/Component/Translation/Tests/Fixtures/withdoctype.xlf diff --git a/src/Symfony/Component/Translation/Tests/fixtures/withnote.xlf b/src/Symfony/Component/Translation/Tests/Fixtures/withnote.xlf similarity index 100% rename from src/Symfony/Component/Translation/Tests/fixtures/withnote.xlf rename to src/Symfony/Component/Translation/Tests/Fixtures/withnote.xlf diff --git a/src/Symfony/Component/Translation/Tests/Loader/CsvFileLoaderTest.php b/src/Symfony/Component/Translation/Tests/Loader/CsvFileLoaderTest.php index 062ea538ece0a..e684e7ce9ff54 100644 --- a/src/Symfony/Component/Translation/Tests/Loader/CsvFileLoaderTest.php +++ b/src/Symfony/Component/Translation/Tests/Loader/CsvFileLoaderTest.php @@ -22,7 +22,7 @@ class CsvFileLoaderTest extends TestCase public function testLoad() { $loader = new CsvFileLoader(); - $resource = __DIR__.'/../fixtures/resources.csv'; + $resource = __DIR__ . '/../Fixtures/resources.csv'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals(['foo' => 'bar'], $catalogue->all('domain1')); @@ -33,7 +33,7 @@ public function testLoad() public function testLoadDoesNothingIfEmpty() { $loader = new CsvFileLoader(); - $resource = __DIR__.'/../fixtures/empty.csv'; + $resource = __DIR__ . '/../Fixtures/empty.csv'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals([], $catalogue->all('domain1')); @@ -45,7 +45,7 @@ public function testLoadNonExistingResource() { $this->expectException(NotFoundResourceException::class); $loader = new CsvFileLoader(); - $resource = __DIR__.'/../fixtures/not-exists.csv'; + $resource = __DIR__ . '/../Fixtures/not-exists.csv'; $loader->load($resource, 'en', 'domain1'); } diff --git a/src/Symfony/Component/Translation/Tests/Loader/IcuDatFileLoaderTest.php b/src/Symfony/Component/Translation/Tests/Loader/IcuDatFileLoaderTest.php index 0f7ffa6fdc852..accfa5d4d3a54 100644 --- a/src/Symfony/Component/Translation/Tests/Loader/IcuDatFileLoaderTest.php +++ b/src/Symfony/Component/Translation/Tests/Loader/IcuDatFileLoaderTest.php @@ -25,7 +25,7 @@ public function testLoadInvalidResource() { $this->expectException(InvalidResourceException::class); $loader = new IcuDatFileLoader(); - $loader->load(__DIR__.'/../fixtures/resourcebundle/corrupted/resources', 'es', 'domain2'); + $loader->load(__DIR__ . '/../Fixtures/resourcebundle/corrupted/resources', 'es', 'domain2'); } public function testDatEnglishLoad() @@ -34,7 +34,7 @@ public function testDatEnglishLoad() // you must specify an temporary build directory which is not the same as current directory and // MUST reside on the same partition. pkgdata -p resources -T /srv -d.packagelist.txt $loader = new IcuDatFileLoader(); - $resource = __DIR__.'/../fixtures/resourcebundle/dat/resources'; + $resource = __DIR__ . '/../Fixtures/resourcebundle/dat/resources'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals(['symfony' => 'Symfony 2 is great'], $catalogue->all('domain1')); @@ -45,7 +45,7 @@ public function testDatEnglishLoad() public function testDatFrenchLoad() { $loader = new IcuDatFileLoader(); - $resource = __DIR__.'/../fixtures/resourcebundle/dat/resources'; + $resource = __DIR__ . '/../Fixtures/resourcebundle/dat/resources'; $catalogue = $loader->load($resource, 'fr', 'domain1'); $this->assertEquals(['symfony' => 'Symfony 2 est génial'], $catalogue->all('domain1')); @@ -57,6 +57,6 @@ public function testLoadNonExistingResource() { $this->expectException(NotFoundResourceException::class); $loader = new IcuDatFileLoader(); - $loader->load(__DIR__.'/../fixtures/non-existing.txt', 'en', 'domain1'); + $loader->load(__DIR__ . '/../Fixtures/non-existing.txt', 'en', 'domain1'); } } diff --git a/src/Symfony/Component/Translation/Tests/Loader/IcuResFileLoaderTest.php b/src/Symfony/Component/Translation/Tests/Loader/IcuResFileLoaderTest.php index 1388f8a91e6ef..0b2f9069146a9 100644 --- a/src/Symfony/Component/Translation/Tests/Loader/IcuResFileLoaderTest.php +++ b/src/Symfony/Component/Translation/Tests/Loader/IcuResFileLoaderTest.php @@ -25,7 +25,7 @@ public function testLoad() { // resource is build using genrb command $loader = new IcuResFileLoader(); - $resource = __DIR__.'/../fixtures/resourcebundle/res'; + $resource = __DIR__ . '/../Fixtures/resourcebundle/res'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals(['foo' => 'bar'], $catalogue->all('domain1')); @@ -37,13 +37,13 @@ public function testLoadNonExistingResource() { $this->expectException(NotFoundResourceException::class); $loader = new IcuResFileLoader(); - $loader->load(__DIR__.'/../fixtures/non-existing.txt', 'en', 'domain1'); + $loader->load(__DIR__ . '/../Fixtures/non-existing.txt', 'en', 'domain1'); } public function testLoadInvalidResource() { $this->expectException(InvalidResourceException::class); $loader = new IcuResFileLoader(); - $loader->load(__DIR__.'/../fixtures/resourcebundle/corrupted', 'en', 'domain1'); + $loader->load(__DIR__ . '/../Fixtures/resourcebundle/corrupted', 'en', 'domain1'); } } diff --git a/src/Symfony/Component/Translation/Tests/Loader/IniFileLoaderTest.php b/src/Symfony/Component/Translation/Tests/Loader/IniFileLoaderTest.php index 9e2027c41e10b..5d761ae20a3ab 100644 --- a/src/Symfony/Component/Translation/Tests/Loader/IniFileLoaderTest.php +++ b/src/Symfony/Component/Translation/Tests/Loader/IniFileLoaderTest.php @@ -21,7 +21,7 @@ class IniFileLoaderTest extends TestCase public function testLoad() { $loader = new IniFileLoader(); - $resource = __DIR__.'/../fixtures/resources.ini'; + $resource = __DIR__ . '/../Fixtures/resources.ini'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals(['foo' => 'bar'], $catalogue->all('domain1')); @@ -32,7 +32,7 @@ public function testLoad() public function testLoadDoesNothingIfEmpty() { $loader = new IniFileLoader(); - $resource = __DIR__.'/../fixtures/empty.ini'; + $resource = __DIR__ . '/../Fixtures/empty.ini'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals([], $catalogue->all('domain1')); @@ -44,7 +44,7 @@ public function testLoadNonExistingResource() { $this->expectException(NotFoundResourceException::class); $loader = new IniFileLoader(); - $resource = __DIR__.'/../fixtures/non-existing.ini'; + $resource = __DIR__ . '/../Fixtures/non-existing.ini'; $loader->load($resource, 'en', 'domain1'); } } diff --git a/src/Symfony/Component/Translation/Tests/Loader/JsonFileLoaderTest.php b/src/Symfony/Component/Translation/Tests/Loader/JsonFileLoaderTest.php index 6dfaec8d9dec4..ed82f9cf94305 100644 --- a/src/Symfony/Component/Translation/Tests/Loader/JsonFileLoaderTest.php +++ b/src/Symfony/Component/Translation/Tests/Loader/JsonFileLoaderTest.php @@ -22,7 +22,7 @@ class JsonFileLoaderTest extends TestCase public function testLoad() { $loader = new JsonFileLoader(); - $resource = __DIR__.'/../fixtures/resources.json'; + $resource = __DIR__ . '/../Fixtures/resources.json'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals(['foo' => 'bar'], $catalogue->all('domain1')); @@ -33,7 +33,7 @@ public function testLoad() public function testLoadDoesNothingIfEmpty() { $loader = new JsonFileLoader(); - $resource = __DIR__.'/../fixtures/empty.json'; + $resource = __DIR__ . '/../Fixtures/empty.json'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals([], $catalogue->all('domain1')); @@ -45,7 +45,7 @@ public function testLoadNonExistingResource() { $this->expectException(NotFoundResourceException::class); $loader = new JsonFileLoader(); - $resource = __DIR__.'/../fixtures/non-existing.json'; + $resource = __DIR__ . '/../Fixtures/non-existing.json'; $loader->load($resource, 'en', 'domain1'); } @@ -54,7 +54,7 @@ public function testParseException() $this->expectException(InvalidResourceException::class); $this->expectExceptionMessage('Error parsing JSON: Syntax error, malformed JSON'); $loader = new JsonFileLoader(); - $resource = __DIR__.'/../fixtures/malformed.json'; + $resource = __DIR__ . '/../Fixtures/malformed.json'; $loader->load($resource, 'en', 'domain1'); } } diff --git a/src/Symfony/Component/Translation/Tests/Loader/MoFileLoaderTest.php b/src/Symfony/Component/Translation/Tests/Loader/MoFileLoaderTest.php index 637fb1c7b78d5..7432ed4a7d311 100644 --- a/src/Symfony/Component/Translation/Tests/Loader/MoFileLoaderTest.php +++ b/src/Symfony/Component/Translation/Tests/Loader/MoFileLoaderTest.php @@ -22,7 +22,7 @@ class MoFileLoaderTest extends TestCase public function testLoad() { $loader = new MoFileLoader(); - $resource = __DIR__.'/../fixtures/resources.mo'; + $resource = __DIR__ . '/../Fixtures/resources.mo'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals(['foo' => 'bar'], $catalogue->all('domain1')); @@ -33,7 +33,7 @@ public function testLoad() public function testLoadPlurals() { $loader = new MoFileLoader(); - $resource = __DIR__.'/../fixtures/plurals.mo'; + $resource = __DIR__ . '/../Fixtures/plurals.mo'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals([ @@ -48,7 +48,7 @@ public function testLoadNonExistingResource() { $this->expectException(NotFoundResourceException::class); $loader = new MoFileLoader(); - $resource = __DIR__.'/../fixtures/non-existing.mo'; + $resource = __DIR__ . '/../Fixtures/non-existing.mo'; $loader->load($resource, 'en', 'domain1'); } @@ -56,14 +56,14 @@ public function testLoadInvalidResource() { $this->expectException(InvalidResourceException::class); $loader = new MoFileLoader(); - $resource = __DIR__.'/../fixtures/empty.mo'; + $resource = __DIR__ . '/../Fixtures/empty.mo'; $loader->load($resource, 'en', 'domain1'); } public function testLoadEmptyTranslation() { $loader = new MoFileLoader(); - $resource = __DIR__.'/../fixtures/empty-translation.mo'; + $resource = __DIR__ . '/../Fixtures/empty-translation.mo'; $catalogue = $loader->load($resource, 'en', 'message'); $this->assertEquals([], $catalogue->all('message')); diff --git a/src/Symfony/Component/Translation/Tests/Loader/PhpFileLoaderTest.php b/src/Symfony/Component/Translation/Tests/Loader/PhpFileLoaderTest.php index ec6ad37b2fbdf..685ae4867af0a 100644 --- a/src/Symfony/Component/Translation/Tests/Loader/PhpFileLoaderTest.php +++ b/src/Symfony/Component/Translation/Tests/Loader/PhpFileLoaderTest.php @@ -22,7 +22,7 @@ class PhpFileLoaderTest extends TestCase public function testLoad() { $loader = new PhpFileLoader(); - $resource = __DIR__.'/../fixtures/resources.php'; + $resource = __DIR__ . '/../Fixtures/resources.php'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals(['foo' => 'bar'], $catalogue->all('domain1')); @@ -34,7 +34,7 @@ public function testLoadNonExistingResource() { $this->expectException(NotFoundResourceException::class); $loader = new PhpFileLoader(); - $resource = __DIR__.'/../fixtures/non-existing.php'; + $resource = __DIR__ . '/../Fixtures/non-existing.php'; $loader->load($resource, 'en', 'domain1'); } diff --git a/src/Symfony/Component/Translation/Tests/Loader/PoFileLoaderTest.php b/src/Symfony/Component/Translation/Tests/Loader/PoFileLoaderTest.php index c346a4be4fab6..626eda48f635e 100644 --- a/src/Symfony/Component/Translation/Tests/Loader/PoFileLoaderTest.php +++ b/src/Symfony/Component/Translation/Tests/Loader/PoFileLoaderTest.php @@ -21,7 +21,7 @@ class PoFileLoaderTest extends TestCase public function testLoad() { $loader = new PoFileLoader(); - $resource = __DIR__.'/../fixtures/resources.po'; + $resource = __DIR__ . '/../Fixtures/resources.po'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals(['foo' => 'bar', 'bar' => 'foo'], $catalogue->all('domain1')); @@ -32,7 +32,7 @@ public function testLoad() public function testLoadPlurals() { $loader = new PoFileLoader(); - $resource = __DIR__.'/../fixtures/plurals.po'; + $resource = __DIR__ . '/../Fixtures/plurals.po'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals([ @@ -46,7 +46,7 @@ public function testLoadPlurals() public function testLoadDoesNothingIfEmpty() { $loader = new PoFileLoader(); - $resource = __DIR__.'/../fixtures/empty.po'; + $resource = __DIR__ . '/../Fixtures/empty.po'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals([], $catalogue->all('domain1')); @@ -58,14 +58,14 @@ public function testLoadNonExistingResource() { $this->expectException(NotFoundResourceException::class); $loader = new PoFileLoader(); - $resource = __DIR__.'/../fixtures/non-existing.po'; + $resource = __DIR__ . '/../Fixtures/non-existing.po'; $loader->load($resource, 'en', 'domain1'); } public function testLoadEmptyTranslation() { $loader = new PoFileLoader(); - $resource = __DIR__.'/../fixtures/empty-translation.po'; + $resource = __DIR__ . '/../Fixtures/empty-translation.po'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals(['foo' => ''], $catalogue->all('domain1')); @@ -76,7 +76,7 @@ public function testLoadEmptyTranslation() public function testEscapedId() { $loader = new PoFileLoader(); - $resource = __DIR__.'/../fixtures/escaped-id.po'; + $resource = __DIR__ . '/../Fixtures/escaped-id.po'; $catalogue = $loader->load($resource, 'en', 'domain1'); $messages = $catalogue->all('domain1'); @@ -87,7 +87,7 @@ public function testEscapedId() public function testEscapedIdPlurals() { $loader = new PoFileLoader(); - $resource = __DIR__.'/../fixtures/escaped-id-plurals.po'; + $resource = __DIR__ . '/../Fixtures/escaped-id-plurals.po'; $catalogue = $loader->load($resource, 'en', 'domain1'); $messages = $catalogue->all('domain1'); @@ -98,7 +98,7 @@ public function testEscapedIdPlurals() public function testSkipFuzzyTranslations() { $loader = new PoFileLoader(); - $resource = __DIR__.'/../fixtures/fuzzy-translations.po'; + $resource = __DIR__ . '/../Fixtures/fuzzy-translations.po'; $catalogue = $loader->load($resource, 'en', 'domain1'); $messages = $catalogue->all('domain1'); @@ -110,7 +110,7 @@ public function testSkipFuzzyTranslations() public function testMissingPlurals() { $loader = new PoFileLoader(); - $resource = __DIR__.'/../fixtures/missing-plurals.po'; + $resource = __DIR__ . '/../Fixtures/missing-plurals.po'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals([ diff --git a/src/Symfony/Component/Translation/Tests/Loader/QtFileLoaderTest.php b/src/Symfony/Component/Translation/Tests/Loader/QtFileLoaderTest.php index 0ab69414eb784..593fd9e7860bf 100644 --- a/src/Symfony/Component/Translation/Tests/Loader/QtFileLoaderTest.php +++ b/src/Symfony/Component/Translation/Tests/Loader/QtFileLoaderTest.php @@ -22,7 +22,7 @@ class QtFileLoaderTest extends TestCase public function testLoad() { $loader = new QtFileLoader(); - $resource = __DIR__.'/../fixtures/resources.ts'; + $resource = __DIR__ . '/../Fixtures/resources.ts'; $catalogue = $loader->load($resource, 'en', 'resources'); $this->assertEquals([ @@ -38,7 +38,7 @@ public function testLoadNonExistingResource() { $this->expectException(NotFoundResourceException::class); $loader = new QtFileLoader(); - $resource = __DIR__.'/../fixtures/non-existing.ts'; + $resource = __DIR__ . '/../Fixtures/non-existing.ts'; $loader->load($resource, 'en', 'domain1'); } @@ -54,14 +54,14 @@ public function testLoadInvalidResource() { $this->expectException(InvalidResourceException::class); $loader = new QtFileLoader(); - $resource = __DIR__.'/../fixtures/invalid-xml-resources.xlf'; + $resource = __DIR__ . '/../Fixtures/invalid-xml-resources.xlf'; $loader->load($resource, 'en', 'domain1'); } public function testLoadEmptyResource() { $loader = new QtFileLoader(); - $resource = __DIR__.'/../fixtures/empty.xlf'; + $resource = __DIR__ . '/../Fixtures/empty.xlf'; $this->expectException(InvalidResourceException::class); $this->expectExceptionMessage(sprintf('Unable to load "%s".', $resource)); diff --git a/src/Symfony/Component/Translation/Tests/Loader/XliffFileLoaderTest.php b/src/Symfony/Component/Translation/Tests/Loader/XliffFileLoaderTest.php index 9f5ed50677088..d2d5a371321f4 100644 --- a/src/Symfony/Component/Translation/Tests/Loader/XliffFileLoaderTest.php +++ b/src/Symfony/Component/Translation/Tests/Loader/XliffFileLoaderTest.php @@ -22,7 +22,7 @@ class XliffFileLoaderTest extends TestCase public function testLoadFile() { $loader = new XliffFileLoader(); - $resource = __DIR__.'/../fixtures/resources.xlf'; + $resource = __DIR__ . '/../Fixtures/resources.xlf'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals('en', $catalogue->getLocale()); @@ -74,7 +74,7 @@ public function testLoadWithInternalErrorsEnabled() $this->assertSame([], libxml_get_errors()); $loader = new XliffFileLoader(); - $resource = __DIR__.'/../fixtures/resources.xlf'; + $resource = __DIR__ . '/../Fixtures/resources.xlf'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals('en', $catalogue->getLocale()); @@ -88,7 +88,7 @@ public function testLoadWithInternalErrorsEnabled() public function testLoadWithExternalEntitiesDisabled() { $loader = new XliffFileLoader(); - $resource = __DIR__.'/../fixtures/resources.xlf'; + $resource = __DIR__ . '/../Fixtures/resources.xlf'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals('en', $catalogue->getLocale()); @@ -98,7 +98,7 @@ public function testLoadWithExternalEntitiesDisabled() public function testLoadWithResname() { $loader = new XliffFileLoader(); - $catalogue = $loader->load(__DIR__.'/../fixtures/resname.xlf', 'en', 'domain1'); + $catalogue = $loader->load(__DIR__ . '/../Fixtures/resname.xlf', 'en', 'domain1'); $this->assertEquals(['foo' => 'bar', 'bar' => 'baz', 'baz' => 'foo', 'qux' => 'qux source'], $catalogue->all('domain1')); } @@ -106,7 +106,7 @@ public function testLoadWithResname() public function testIncompleteResource() { $loader = new XliffFileLoader(); - $catalogue = $loader->load(__DIR__.'/../fixtures/resources.xlf', 'en', 'domain1'); + $catalogue = $loader->load(__DIR__ . '/../Fixtures/resources.xlf', 'en', 'domain1'); $this->assertEquals(['foo' => 'bar', 'extra' => 'extra', 'key' => '', 'test' => 'with'], $catalogue->all('domain1')); } @@ -114,7 +114,7 @@ public function testIncompleteResource() public function testEncoding() { $loader = new XliffFileLoader(); - $catalogue = $loader->load(__DIR__.'/../fixtures/encoding.xlf', 'en', 'domain1'); + $catalogue = $loader->load(__DIR__ . '/../Fixtures/encoding.xlf', 'en', 'domain1'); $this->assertEquals(mb_convert_encoding('föö', 'ISO-8859-1', 'UTF-8'), $catalogue->get('bar', 'domain1')); $this->assertEquals(mb_convert_encoding('bär', 'ISO-8859-1', 'UTF-8'), $catalogue->get('foo', 'domain1')); @@ -134,7 +134,7 @@ public function testEncoding() public function testTargetAttributesAreStoredCorrectly() { $loader = new XliffFileLoader(); - $catalogue = $loader->load(__DIR__.'/../fixtures/with-attributes.xlf', 'en', 'domain1'); + $catalogue = $loader->load(__DIR__ . '/../Fixtures/with-attributes.xlf', 'en', 'domain1'); $metadata = $catalogue->getMetadata('foo', 'domain1'); $this->assertEquals('translated', $metadata['target-attributes']['state']); @@ -144,21 +144,21 @@ public function testLoadInvalidResource() { $this->expectException(InvalidResourceException::class); $loader = new XliffFileLoader(); - $loader->load(__DIR__.'/../fixtures/resources.php', 'en', 'domain1'); + $loader->load(__DIR__ . '/../Fixtures/resources.php', 'en', 'domain1'); } public function testLoadResourceDoesNotValidate() { $this->expectException(InvalidResourceException::class); $loader = new XliffFileLoader(); - $loader->load(__DIR__.'/../fixtures/non-valid.xlf', 'en', 'domain1'); + $loader->load(__DIR__ . '/../Fixtures/non-valid.xlf', 'en', 'domain1'); } public function testLoadNonExistingResource() { $this->expectException(NotFoundResourceException::class); $loader = new XliffFileLoader(); - $resource = __DIR__.'/../fixtures/non-existing.xlf'; + $resource = __DIR__ . '/../Fixtures/non-existing.xlf'; $loader->load($resource, 'en', 'domain1'); } @@ -175,13 +175,13 @@ public function testDocTypeIsNotAllowed() $this->expectException(InvalidResourceException::class); $this->expectExceptionMessage('Document types are not allowed.'); $loader = new XliffFileLoader(); - $loader->load(__DIR__.'/../fixtures/withdoctype.xlf', 'en', 'domain1'); + $loader->load(__DIR__ . '/../Fixtures/withdoctype.xlf', 'en', 'domain1'); } public function testParseEmptyFile() { $loader = new XliffFileLoader(); - $resource = __DIR__.'/../fixtures/empty.xlf'; + $resource = __DIR__ . '/../Fixtures/empty.xlf'; $this->expectException(InvalidResourceException::class); $this->expectExceptionMessage(sprintf('Unable to load "%s":', $resource)); @@ -192,7 +192,7 @@ public function testParseEmptyFile() public function testLoadNotes() { $loader = new XliffFileLoader(); - $catalogue = $loader->load(__DIR__.'/../fixtures/withnote.xlf', 'en', 'domain1'); + $catalogue = $loader->load(__DIR__ . '/../Fixtures/withnote.xlf', 'en', 'domain1'); $this->assertEquals( [ @@ -237,7 +237,7 @@ public function testLoadNotes() public function testLoadVersion2() { $loader = new XliffFileLoader(); - $resource = __DIR__.'/../fixtures/resources-2.0.xlf'; + $resource = __DIR__ . '/../Fixtures/resources-2.0.xlf'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals('en', $catalogue->getLocale()); @@ -255,7 +255,7 @@ public function testLoadVersion2() public function testLoadVersion2WithNoteMeta() { $loader = new XliffFileLoader(); - $resource = __DIR__.'/../fixtures/resources-notes-meta.xlf'; + $resource = __DIR__ . '/../Fixtures/resources-notes-meta.xlf'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals('en', $catalogue->getLocale()); @@ -295,7 +295,7 @@ public function testLoadVersion2WithNoteMeta() public function testLoadVersion2WithMultiSegmentUnit() { $loader = new XliffFileLoader(); - $resource = __DIR__.'/../fixtures/resources-2.0-multi-segment-unit.xlf'; + $resource = __DIR__ . '/../Fixtures/resources-2.0-multi-segment-unit.xlf'; $catalog = $loader->load($resource, 'en', 'domain1'); $this->assertSame('en', $catalog->getLocale()); @@ -324,7 +324,7 @@ public function testLoadVersion2WithMultiSegmentUnit() public function testLoadWithMultipleFileNodes() { $loader = new XliffFileLoader(); - $catalogue = $loader->load(__DIR__.'/../fixtures/resources-multi-files.xlf', 'en', 'domain1'); + $catalogue = $loader->load(__DIR__ . '/../Fixtures/resources-multi-files.xlf', 'en', 'domain1'); $this->assertEquals( [ @@ -352,7 +352,7 @@ public function testLoadWithMultipleFileNodes() public function testLoadVersion2WithName() { $loader = new XliffFileLoader(); - $catalogue = $loader->load(__DIR__.'/../fixtures/resources-2.0-name.xlf', 'en', 'domain1'); + $catalogue = $loader->load(__DIR__ . '/../Fixtures/resources-2.0-name.xlf', 'en', 'domain1'); $this->assertEquals(['foo' => 'bar', 'bar' => 'baz', 'baz' => 'foo', 'qux' => 'qux source'], $catalogue->all('domain1')); } diff --git a/src/Symfony/Component/Translation/Tests/Loader/YamlFileLoaderTest.php b/src/Symfony/Component/Translation/Tests/Loader/YamlFileLoaderTest.php index cac0b6f87823a..bdbb16411b376 100644 --- a/src/Symfony/Component/Translation/Tests/Loader/YamlFileLoaderTest.php +++ b/src/Symfony/Component/Translation/Tests/Loader/YamlFileLoaderTest.php @@ -22,7 +22,7 @@ class YamlFileLoaderTest extends TestCase public function testLoad() { $loader = new YamlFileLoader(); - $resource = __DIR__.'/../fixtures/resources.yml'; + $resource = __DIR__ . '/../Fixtures/resources.yml'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals(['foo' => 'bar'], $catalogue->all('domain1')); @@ -33,7 +33,7 @@ public function testLoad() public function testLoadNonStringMessages() { $loader = new YamlFileLoader(); - $resource = __DIR__.'/../fixtures/non-string.yml'; + $resource = __DIR__ . '/../Fixtures/non-string.yml'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertSame(['root.foo2' => '', 'root.bar' => 'bar'], $catalogue->all('domain1')); @@ -42,7 +42,7 @@ public function testLoadNonStringMessages() public function testLoadDoesNothingIfEmpty() { $loader = new YamlFileLoader(); - $resource = __DIR__.'/../fixtures/empty.yml'; + $resource = __DIR__ . '/../Fixtures/empty.yml'; $catalogue = $loader->load($resource, 'en', 'domain1'); $this->assertEquals([], $catalogue->all('domain1')); @@ -54,7 +54,7 @@ public function testLoadNonExistingResource() { $this->expectException(NotFoundResourceException::class); $loader = new YamlFileLoader(); - $resource = __DIR__.'/../fixtures/non-existing.yml'; + $resource = __DIR__ . '/../Fixtures/non-existing.yml'; $loader->load($resource, 'en', 'domain1'); } @@ -70,7 +70,7 @@ public function testLoadThrowsAnExceptionIfNotAnArray() { $this->expectException(InvalidResourceException::class); $loader = new YamlFileLoader(); - $resource = __DIR__.'/../fixtures/non-valid.yml'; + $resource = __DIR__ . '/../Fixtures/non-valid.yml'; $loader->load($resource, 'en', 'domain1'); } } diff --git a/src/Symfony/Component/Translation/Tests/TranslatorTest.php b/src/Symfony/Component/Translation/Tests/TranslatorTest.php index d6dee409fb6e2..b53b388457d2d 100644 --- a/src/Symfony/Component/Translation/Tests/TranslatorTest.php +++ b/src/Symfony/Component/Translation/Tests/TranslatorTest.php @@ -225,8 +225,8 @@ public function testTransWithoutFallbackLocaleFile($format, $loader) $loaderClass = 'Symfony\\Component\\Translation\\Loader\\'.$loader; $translator = new Translator('en'); $translator->addLoader($format, new $loaderClass()); - $translator->addResource($format, __DIR__.'/fixtures/non-existing', 'en'); - $translator->addResource($format, __DIR__.'/fixtures/resources.'.$format, 'en'); + $translator->addResource($format, __DIR__ . '/Fixtures/non-existing', 'en'); + $translator->addResource($format, __DIR__ . '/Fixtures/resources.' .$format, 'en'); // force catalogue loading $translator->trans('foo'); @@ -240,8 +240,8 @@ public function testTransWithFallbackLocaleFile($format, $loader) $loaderClass = 'Symfony\\Component\\Translation\\Loader\\'.$loader; $translator = new Translator('en_GB'); $translator->addLoader($format, new $loaderClass()); - $translator->addResource($format, __DIR__.'/fixtures/non-existing', 'en_GB'); - $translator->addResource($format, __DIR__.'/fixtures/resources.'.$format, 'en', 'resources'); + $translator->addResource($format, __DIR__ . '/Fixtures/non-existing', 'en_GB'); + $translator->addResource($format, __DIR__ . '/Fixtures/resources.' .$format, 'en', 'resources'); $this->assertEquals('bar', $translator->trans('foo', [], 'resources')); } @@ -364,20 +364,20 @@ public function testFallbackCatalogueResources() { $translator = new Translator('en_GB'); $translator->addLoader('yml', new \Symfony\Component\Translation\Loader\YamlFileLoader()); - $translator->addResource('yml', __DIR__.'/fixtures/empty.yml', 'en_GB'); - $translator->addResource('yml', __DIR__.'/fixtures/resources.yml', 'en'); + $translator->addResource('yml', __DIR__ . '/Fixtures/empty.yml', 'en_GB'); + $translator->addResource('yml', __DIR__ . '/Fixtures/resources.yml', 'en'); // force catalogue loading $this->assertEquals('bar', $translator->trans('foo', [])); $resources = $translator->getCatalogue('en')->getResources(); $this->assertCount(1, $resources); - $this->assertContainsEquals(__DIR__.\DIRECTORY_SEPARATOR.'fixtures'.\DIRECTORY_SEPARATOR.'resources.yml', $resources); + $this->assertContainsEquals(__DIR__ . \DIRECTORY_SEPARATOR . 'Fixtures' .\DIRECTORY_SEPARATOR.'resources.yml', $resources); $resources = $translator->getCatalogue('en_GB')->getResources(); $this->assertCount(2, $resources); - $this->assertContainsEquals(__DIR__.\DIRECTORY_SEPARATOR.'fixtures'.\DIRECTORY_SEPARATOR.'empty.yml', $resources); - $this->assertContainsEquals(__DIR__.\DIRECTORY_SEPARATOR.'fixtures'.\DIRECTORY_SEPARATOR.'resources.yml', $resources); + $this->assertContainsEquals(__DIR__ . \DIRECTORY_SEPARATOR . 'Fixtures' .\DIRECTORY_SEPARATOR.'empty.yml', $resources); + $this->assertContainsEquals(__DIR__ . \DIRECTORY_SEPARATOR . 'Fixtures' .\DIRECTORY_SEPARATOR.'resources.yml', $resources); } /** diff --git a/src/Symfony/Component/Workflow/Tests/Dumper/PlantUmlDumperTest.php b/src/Symfony/Component/Workflow/Tests/Dumper/PlantUmlDumperTest.php index 71e4065389cc0..3b0d0108e5ff8 100644 --- a/src/Symfony/Component/Workflow/Tests/Dumper/PlantUmlDumperTest.php +++ b/src/Symfony/Component/Workflow/Tests/Dumper/PlantUmlDumperTest.php @@ -96,6 +96,6 @@ public function testDumpWorkflowWithSpacesInTheStateNamesAndDescription() private function getFixturePath($name, $transitionType): string { - return __DIR__.'/../fixtures/puml/'.$transitionType.'/'.$name.'.puml'; + return __DIR__ . '/../Fixtures/puml/' .$transitionType.'/'.$name.'.puml'; } } diff --git a/src/Symfony/Component/Workflow/Tests/fixtures/puml/arrow/complex-state-machine-marking.puml b/src/Symfony/Component/Workflow/Tests/Fixtures/puml/arrow/complex-state-machine-marking.puml similarity index 100% rename from src/Symfony/Component/Workflow/Tests/fixtures/puml/arrow/complex-state-machine-marking.puml rename to src/Symfony/Component/Workflow/Tests/Fixtures/puml/arrow/complex-state-machine-marking.puml diff --git a/src/Symfony/Component/Workflow/Tests/fixtures/puml/arrow/complex-state-machine-nomarking.puml b/src/Symfony/Component/Workflow/Tests/Fixtures/puml/arrow/complex-state-machine-nomarking.puml similarity index 100% rename from src/Symfony/Component/Workflow/Tests/fixtures/puml/arrow/complex-state-machine-nomarking.puml rename to src/Symfony/Component/Workflow/Tests/Fixtures/puml/arrow/complex-state-machine-nomarking.puml diff --git a/src/Symfony/Component/Workflow/Tests/fixtures/puml/square/complex-workflow-marking.puml b/src/Symfony/Component/Workflow/Tests/Fixtures/puml/square/complex-workflow-marking.puml similarity index 100% rename from src/Symfony/Component/Workflow/Tests/fixtures/puml/square/complex-workflow-marking.puml rename to src/Symfony/Component/Workflow/Tests/Fixtures/puml/square/complex-workflow-marking.puml diff --git a/src/Symfony/Component/Workflow/Tests/fixtures/puml/square/complex-workflow-nomarking.puml b/src/Symfony/Component/Workflow/Tests/Fixtures/puml/square/complex-workflow-nomarking.puml similarity index 100% rename from src/Symfony/Component/Workflow/Tests/fixtures/puml/square/complex-workflow-nomarking.puml rename to src/Symfony/Component/Workflow/Tests/Fixtures/puml/square/complex-workflow-nomarking.puml diff --git a/src/Symfony/Component/Workflow/Tests/fixtures/puml/square/simple-workflow-marking.puml b/src/Symfony/Component/Workflow/Tests/Fixtures/puml/square/simple-workflow-marking.puml similarity index 100% rename from src/Symfony/Component/Workflow/Tests/fixtures/puml/square/simple-workflow-marking.puml rename to src/Symfony/Component/Workflow/Tests/Fixtures/puml/square/simple-workflow-marking.puml diff --git a/src/Symfony/Component/Workflow/Tests/fixtures/puml/square/simple-workflow-nomarking.puml b/src/Symfony/Component/Workflow/Tests/Fixtures/puml/square/simple-workflow-nomarking.puml similarity index 100% rename from src/Symfony/Component/Workflow/Tests/fixtures/puml/square/simple-workflow-nomarking.puml rename to src/Symfony/Component/Workflow/Tests/Fixtures/puml/square/simple-workflow-nomarking.puml diff --git a/src/Symfony/Component/Workflow/Tests/fixtures/puml/square/simple-workflow-with-spaces.puml b/src/Symfony/Component/Workflow/Tests/Fixtures/puml/square/simple-workflow-with-spaces.puml similarity index 100% rename from src/Symfony/Component/Workflow/Tests/fixtures/puml/square/simple-workflow-with-spaces.puml rename to src/Symfony/Component/Workflow/Tests/Fixtures/puml/square/simple-workflow-with-spaces.puml