54
54
use PHPUnit \Framework \MockObject \MockObject ;
55
55
use PHPUnit \Framework \TestCase ;
56
56
use Magento \Setup \Model \SearchConfig ;
57
+ use Magento \RemoteStorage \Setup \ConfigOptionsList as FileStorageValidator ;
57
58
58
59
/**
59
60
* @SuppressWarnings(PHPMD.TooManyFields)
@@ -107,11 +108,6 @@ class InstallerTest extends TestCase
107
108
*/
108
109
private $ moduleLoader ;
109
110
110
- /**
111
- * @var DirectoryList|MockObject
112
- */
113
- private $ directoryList ;
114
-
115
111
/**
116
112
* @var AdminAccountFactory|MockObject
117
113
*/
@@ -123,12 +119,7 @@ class InstallerTest extends TestCase
123
119
private $ logger ;
124
120
125
121
/**
126
- * @var Random|MockObject
127
- */
128
- private $ random ;
129
-
130
- /**
131
- * @var MockObject
122
+ * @var AdapterInterface|MockObject
132
123
*/
133
124
private $ connection ;
134
125
@@ -188,7 +179,7 @@ class InstallerTest extends TestCase
188
179
private $ phpReadinessCheck ;
189
180
190
181
/**
191
- * @var \Magento\Framework\Setup\ DeclarationInstaller|MockObject
182
+ * @var DeclarationInstaller|MockObject
192
183
*/
193
184
private $ declarationInstallerMock ;
194
185
@@ -365,6 +356,11 @@ public function testInstall(array $request, array $logMessages)
365
356
->with (Area::AREA_GLOBAL );
366
357
$ registry = $ this ->createMock (Registry::class);
367
358
$ searchConfigMock = $ this ->getMockBuilder (SearchConfig::class)->disableOriginalConstructor ()->getMock ();
359
+
360
+ $ fileStorageValidatorMock = $ this ->getMockBuilder (FileStorageValidator::class)
361
+ ->disableOriginalConstructor ()
362
+ ->getMock ();
363
+
368
364
$ this ->setupFactory ->expects ($ this ->atLeastOnce ())->method ('create ' )->with ($ resource )->willReturn ($ setup );
369
365
$ this ->dataSetupFactory ->expects ($ this ->atLeastOnce ())->method ('create ' )->willReturn ($ dataSetup );
370
366
$ this ->objectManager ->expects ($ this ->any ())
@@ -397,7 +393,8 @@ public function testInstall(array $request, array $logMessages)
397
393
[Manager::class, $ cacheManager ],
398
394
[DeclarationInstaller::class, $ this ->declarationInstallerMock ],
399
395
[Registry::class, $ registry ],
400
- [SearchConfig::class, $ searchConfigMock ]
396
+ [SearchConfig::class, $ searchConfigMock ],
397
+ [FileStorageValidator::class, $ fileStorageValidatorMock ],
401
398
]);
402
399
$ this ->adminFactory ->expects ($ this ->any ())->method ('create ' )->willReturn (
403
400
$ this ->createMock (AdminAccount::class)
@@ -452,6 +449,7 @@ public function installDataProvider()
452
449
['Module \'Foo_One \': ' ],
453
450
['Module \'Bar_Two \': ' ],
454
451
['Installing search configuration... ' ],
452
+ ['Validating file storage configuration... ' ],
455
453
['Installing user configuration... ' ],
456
454
['Enabling caches: ' ],
457
455
['Current status: ' ],
@@ -503,6 +501,7 @@ public function installDataProvider()
503
501
['Module \'Foo_One \': ' ],
504
502
['Module \'Bar_Two \': ' ],
505
503
['Installing search configuration... ' ],
504
+ ['Validating file storage configuration... ' ],
506
505
['Installing user configuration... ' ],
507
506
['Enabling caches: ' ],
508
507
['Current status: ' ],
0 commit comments