Created
March 3, 2016 13:39
-
-
Save crmpicco/125eceda1adf91d9448f to your computer and use it in GitHub Desktop.
it_imports_image_assets
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function it_imports_image_assets( | |
Filesystem $filesystem, | |
EntityManager $entityManager, | |
Finder $finder, | |
SplFileInfo $file1, | |
SplFileInfo $file2 | |
) { | |
$imageImportPath = '/var/www/crmpicco/app/files/images/rfc-1872/'; | |
$filesystem->exists($imageImportPath)->willReturn(true); | |
$finder->files()->shouldBeCalled()->willReturn($finder); | |
$finder->in($imageImportPath)->willReturn($finder); | |
$finder->getIterator()->willReturn(new \ArrayIterator([ | |
$file1->getWrappedObject(), | |
$file2->getWrappedObject(), | |
])); | |
$file1->getPathname()->willReturn($imageImportPath.'file1.txt'); | |
$file2->getPathname()->willReturn($imageImportPath.'file1.txt'); | |
$this->importImageAssets($imageImportPath)->shouldReturn([]); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment