Skip to content

Commit 2f9e652

Browse files
committed
B2B-2058: ImageUploader uses Name class which works only with local FS
1 parent 1013ab3 commit 2f9e652

File tree

2 files changed

+7
-8
lines changed
  • dev/tests/integration/testsuite/Magento/Framework/File
  • lib/internal/Magento/Framework/File

2 files changed

+7
-8
lines changed

dev/tests/integration/testsuite/Magento/Framework/File/NameTest.php

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -39,14 +39,6 @@ protected function setUp(): void
3939
$this->nameModel = $objectManager->get(Name::class);
4040
}
4141

42-
/**
43-
*
44-
* @return void
45-
* @magentoDataFixture Magento/Framework/File/_files/framework_file_name.php
46-
*
47-
* @dataProvider getNewFileNameDataProvider
48-
*/
49-
5042
/**
5143
* @param string $destinationFile
5244
* @param string $expectedFileName
@@ -63,6 +55,10 @@ public function testGetNewFileName($destinationFile, $expectedFileName)
6355
$this->assertEquals($expectedFileName, $name);
6456
}
6557

58+
/**
59+
* Data provider for testGetNewFileName
60+
* @return array
61+
*/
6662
public function getNewFileNameDataProvider()
6763
{
6864
return [

lib/internal/Magento/Framework/File/Name.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@ class Name
2121
*/
2222
private $targetDirectory;
2323

24+
/**
25+
* @param TargetDirectory|null $targetDirectory
26+
*/
2427
public function __construct(TargetDirectory $targetDirectory = null)
2528
{
2629
$this->targetDirectory = $targetDirectory ?? ObjectManager::getInstance()->get(TargetDirectory::class);

0 commit comments

Comments
 (0)