Hi,
Add
after the var_dump. It will stop the processing and should display the var_dump in the popup without it closing.
Also, HikaShop has a function hikashop_writeToLog($data)
When you call that function, it will store the content of $data in the "payment log file" you can access under the Main tab of the HikaShop configuration. So it's a great way to debug things where you don't have a way to display things to the browser.
For example, when the payment gateway calls the payment plugin to notify it of the payment, this usually happens in a server-to-server way and thus if you var_dump something in the payment plugin, or a plugin acting upon the order status change, it will be output to the payment gateway server. So using hikashop_writeToLog() comes in handy.