On Github shamsher31 / yii-training-day-4
Based on PHP 5 exception mechanism.
throw new ExceptionClass('ExceptionMessage');
CException
First Method
return array( ...... 'components'=>array( 'errorHandler'=>array( 'errorAction'=>'site/error', ), ), );
Second Method
public function actionError()
{
if($error=Yii::app()->errorHandler->error)
$this->render('error', $error);
}
class CommentTest extends CDbTestCase
{
public $fixtures=array(
'posts'=>'Post',
'comments'=>'Comment',
);
......
}
Stored under directory protected/tests/unit
"No one knows better then Google"