Skip to content

Commit b99abf7

Browse files
author
Yurii Torbyk
committed
MAGETWO-35561: Stabilize story
1 parent f823916 commit b99abf7

File tree

5 files changed

+7
-7
lines changed

5 files changed

+7
-7
lines changed

dev/tools/Magento/Tools/Di/Code/Scanner/PhpScanner.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ protected function _findMissingClasses($file, $classReflection, $methodName, $en
4949
if (class_exists($missingClassName)) {
5050
continue;
5151
}
52-
} catch (\Magento\Framework\Exception\LocalizedException $e) {
52+
} catch (\Exception $e) {
5353
}
5454
$sourceClassName = $this->getSourceClassName($missingClassName, $entityType);
5555
if (!class_exists($sourceClassName) && !interface_exists($sourceClassName)) {

dev/tools/Magento/Tools/Di/Code/Scanner/XmlScanner.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ protected function _filterEntities(array $output)
6868
$isClassExists = false;
6969
try {
7070
$isClassExists = class_exists($className);
71-
} catch (\Magento\Framework\Exception\LocalizedException $e) {
71+
} catch (\Exception $e) {
7272
}
7373
if (false === $isClassExists) {
7474
if (class_exists($entityName) || interface_exists($entityName)) {

lib/internal/Magento/Framework/Code/Test/Unit/GeneratorTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ public function testGetGeneratedEntities()
6060
}
6161

6262
/**
63-
* @expectedException \Magento\Framework\Exception\LocalizedException
63+
* @expectedException \Exception
6464
* @dataProvider generateValidClassDataProvider
6565
*/
6666
public function testGenerateClass($className, $entityType)
@@ -117,7 +117,7 @@ public function testGenerateClassWithWrongName()
117117
}
118118

119119
/**
120-
* @expectedException \Magento\Framework\Exception\LocalizedException
120+
* @expectedException \Exception
121121
*/
122122
public function testGenerateClassWithError()
123123
{

lib/internal/Magento/Framework/ObjectManager/Test/Unit/Relations/RuntimeTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ public function getParentsDataProvider()
4242

4343
/**
4444
* @param $entity
45-
* @expectedException \Magento\Framework\Exception\LocalizedException
45+
* @expectedException \Exception
4646
* @dataProvider nonExistentGeneratorsDataProvider
4747
*/
4848
public function testHasIfNonExists($entity)

lib/internal/Magento/Framework/Test/Unit/ShellTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ public function executeDataProvider()
111111
}
112112

113113
/**
114-
* @expectedException \Magento\Framework\Exception\LocalizedException
114+
* @expectedException \Exception
115115
* @expectedExceptionMessage Command returned non-zero exit code:
116116
* @expectedExceptionCode 0
117117
*/
@@ -133,7 +133,7 @@ public function testExecuteFailureDetails($command, $commandArgs, $expectedError
133133
/* Force command to return non-zero exit code */
134134
$commandArgs[count($commandArgs) - 1] .= ' exit(42);';
135135
$this->testExecute($command, $commandArgs, ''); // no result is expected in a case of a command failure
136-
} catch (\Magento\Framework\Exception\LocalizedException $e) {
136+
} catch (\Exception $e) {
137137
$this->assertInstanceOf('Exception', $e->getPrevious());
138138
$this->assertEquals($expectedError, $e->getPrevious()->getMessage());
139139
$this->assertEquals(42, $e->getPrevious()->getCode());

0 commit comments

Comments
 (0)