@@ -111,22 +111,23 @@ public function setUp()
111
111
$ objectManagerProvider ->expects ($ this ->once ())
112
112
->method ('get ' )
113
113
->willReturn ($ objectManager );
114
- $ packageInfoFactory = $ this ->getMock ('Magento\Framework\Module\PackageInfoFactory ' , [], [], '' , false );
115
- $ enabledModuleList = $ this ->getMock ('Magento\Framework\Module\ModuleList ' , [], [], '' , false );
116
- $ enabledModuleList ->expects ($ this ->any ())->method ('has ' )->willReturn (true );
117
- $ fullModuleList = $ this ->getMock ('Magento\Framework\Module\FullModuleList ' , [], [], '' , false );
118
- $ fullModuleList ->expects ($ this ->any ())->method ('getNames ' )->willReturn ($ allComponentData );
114
+ $ this ->packageInfoFactoryMock = $ this
115
+ ->getMock ('Magento\Framework\Module\PackageInfoFactory ' , [], [], '' , false );
116
+ $ this ->enabledModuleListMock = $ this ->getMock ('Magento\Framework\Module\ModuleList ' , [], [], '' , false );
117
+ $ this ->enabledModuleListMock ->expects ($ this ->any ())->method ('has ' )->willReturn (true );
118
+ $ this ->fullModuleListMock = $ this ->getMock ('Magento\Framework\Module\FullModuleList ' , [], [], '' , false );
119
+ $ this ->fullModuleListMock ->expects ($ this ->any ())->method ('getNames ' )->willReturn ($ allComponentData );
119
120
$ objectManager ->expects ($ this ->exactly (3 ))
120
121
->method ('get ' )
121
122
->willReturnMap ([
122
- ['Magento\Framework\Module\PackageInfoFactory ' , $ packageInfoFactory ],
123
- ['Magento\Framework\Module\FullModuleList ' , $ fullModuleList ],
124
- ['Magento\Framework\Module\ModuleList ' , $ enabledModuleList ]
123
+ ['Magento\Framework\Module\PackageInfoFactory ' , $ this -> packageInfoFactoryMock ],
124
+ ['Magento\Framework\Module\FullModuleList ' , $ this -> fullModuleListMock ],
125
+ ['Magento\Framework\Module\ModuleList ' , $ this -> enabledModuleListMock ]
125
126
]);
126
127
$ this ->packageInfo = $ this ->getMock ('Magento\Framework\Module\PackageInfo ' , [], [], '' , false );
127
128
$ this ->updatePackagesCacheMock = $ this ->getMock ('Magento\Setup\Model\UpdatePackagesCache ' , [], [], '' , false );
128
129
$ this ->connectManagerMock = $ this ->getMock ('Magento\Setup\Model\ConnectManager ' , [], [], '' , false );
129
- $ packageInfoFactory ->expects ($ this ->once ())->method ('create ' )->willReturn ($ this ->packageInfo );
130
+ $ this -> packageInfoFactoryMock ->expects ($ this ->once ())->method ('create ' )->willReturn ($ this ->packageInfo );
130
131
$ this ->controller = new ComponentGrid (
131
132
$ this ->composerInformationMock ,
132
133
$ objectManagerProvider ,
0 commit comments