Skip to content

Instantly share code, notes, and snippets.

@andrey-yantsen
Created August 13, 2013 10:48
Show Gist options
  • Save andrey-yantsen/6220014 to your computer and use it in GitHub Desktop.
Save andrey-yantsen/6220014 to your computer and use it in GitHub Desktop.
Correct AspectMock configuration for Yii1
$kernel->init([
'debug' => false,
'includePaths' => [
__DIR__ . '/../'
],
'appDir' => __DIR__ . '/../',
'excludePaths' => [
__DIR__ . '/../config',
__DIR__ . '/../vendor/codeception/aspect-mock',
__DIR__ . '/../runtime',
__DIR__ . '/../vendor/yiisoft/yii/framework/base/CComponent.php',
],
]);
@anildhiman03
Copy link

i am getting error when i am trying default setting and even with your setting getting error
Fatal error: Call to a member function registerClass() on a non-object in vendor\codeception\aspect-mock\src\AspectMock\Core\Registry.php on line 25

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment