File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed
dev/tests/integration/testsuite/Magento/MediaStorage/Model/File Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change 66namespace Magento \MediaStorage \Model \File ;
77
88use Magento \Framework \App \Filesystem \DirectoryList ;
9+ use Magento \Framework \Filesystem \Driver \File ;
910
1011class StorageTest extends \PHPUnit \Framework \TestCase
1112{
@@ -27,10 +28,11 @@ public function testGetScriptConfig()
2728 $ filesystem = \Magento \TestFramework \Helper \Bootstrap::getObjectManager ()->get (
2829 \Magento \Framework \Filesystem::class
2930 );
30- $ this ->assertEquals (
31- $ filesystem ->getDirectoryRead (DirectoryList::MEDIA )->getAbsolutePath (),
32- $ config ['media_directory ' ]
33- );
31+
32+ $ mediaDirectory = $ filesystem ->getDirectoryWrite (DirectoryList::MEDIA );
33+ if ($ mediaDirectory ->getDriver () instanceof File) {
34+ $ this ->assertEquals ($ config ['media_directory ' ], $ mediaDirectory ->getAbsolutePath ());
35+ }
3436 $ this ->assertIsArray ($ config ['allowed_resources ' ]);
3537 $ this ->assertContains ('css ' , $ config ['allowed_resources ' ]);
3638 $ this ->assertContains ('css_secure ' , $ config ['allowed_resources ' ]);
You can’t perform that action at this time.
0 commit comments