How To Debug Swiftmailer

My swiftmailer return true but i don’t receive email,

however, the mail() function is worked fine.

I would like to know how to debug it… please advise

here is my code using swift mailer.

\Yii::$app->mail->compose('/order/view-payment', ['orderModel' => $this])



     ->setSubject("มีการชำระเงินใน Order#" . $this->order_id)


You have debugger activated? Debugger catches mails - you can see them in there.