-
Notifications
You must be signed in to change notification settings - Fork 166
Commit
…hpunit version to major one
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -134,7 +134,20 @@ public static function applyTestScope() | |
EcomDev_Utils_Reflection::setRestrictedPropertyValue('Mage', '_registry', array()); | ||
|
||
// All unit tests will be run in admin scope, to get rid of frontend restrictions | ||
Mage::app()->initTest(); | ||
// Init modules runs install process for table structures, | ||
// It is required for setting up proper setup script | ||
try { | ||
set_error_handler(function ($errorCode, $errorMessage) { | ||
echo $errorMessage, $errorCode; | ||
debug_print_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS); | ||
exit; | ||
}); | ||
Mage::app()->initTest(); | ||
restore_error_handler(); | ||
} catch (Exception $e) { | ||
echo $e->getMessage(), "\n", $e->getTraceAsString(); | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
ozzyogkush
|
||
exit; | ||
} | ||
} | ||
|
||
/** | ||
|
@@ -383,7 +396,6 @@ public function getResponse() | |
protected function _getClassNameFromConfig($configPath, $interface = null) | ||
{ | ||
$className = (string)$this->getConfig()->getNode($configPath); | ||
|
||
$reflection = EcomDev_Utils_Reflection::getReflection($className); | ||
if ($interface !== null && !$reflection->implementsInterface($interface)) { | ||
throw new RuntimeException( | ||
|
the stack trace should be optional via a flag... the buffer can be huge and seeing an enormous stack trace isn't helpful when you can't even find the start of the message.