File tree Expand file tree Collapse file tree 1 file changed +8
-5
lines changed
dev/tests/integration/framework/Magento/TestFramework/Annotation Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -272,11 +272,14 @@ protected function _restoreConfigData()
272
272
*/
273
273
public function startTest (TestCase $ test )
274
274
{
275
- $ eventObj = Magento::getCurrentEventObject ();
276
- $ testData = $ eventObj ->test ()->testData ();
277
- if ($ testData ->hasDataFromDataProvider ()){
278
- $ dataSetName = $ testData ->dataFromDataProvider ()->dataSetName ();
279
- $ test ->setData ($ dataSetName , ['' ]);
275
+ if ($ eventObj = Magento::getCurrentEventObject ()) {
276
+ $ testData = $ eventObj ->test ()->testData ();
277
+
278
+ if ($ testData ->hasDataFromDataProvider ()) {
279
+ $ dataFromDataProvider = $ testData ->dataFromDataProvider ();
280
+ $ dataSetName = $ dataFromDataProvider ->dataSetName ();
281
+ $ test ->setData ($ dataSetName , ['' ]);
282
+ }
280
283
}
281
284
282
285
$ this ->_currentTest = $ test ;
You can’t perform that action at this time.
0 commit comments