public function testCreateSnippetFileCollection(): void
{ $snippetFileLoaderMock =
$this->
createMock(SnippetFileLoaderInterface::
class);
$snippetFileLoaderMock->
expects(static::
once()) ->
method('loadSnippetFilesIntoCollection'
) ->
willReturnCallback(function DSnippetFileCollection
$fileCollection): void
{ $fileCollection->
add(new MockSnippetFile('storefront.de-DE', 'de-DE', '{}', true
));
});
$factory =
new SnippetFileCollectionFactory($snippetFileLoaderMock);
$collection =
$factory->
createSnippetFileCollection();
static::
assertCount(1,
$collection);
}}