In my model, I use the (swift)mailer extension to construct and send email.
Problem comes when I am doing unit testing on the model. Inside the mailer extension there is part that requires
Yii::app()->controller->renderPartial(..
But controller seems not loaded
PHP Fatal error: Call to a member function renderPartial() on a non-object
How do I solve this?