Added 'mode' as optional parameter when called printStackTrace(options)

This patch improve the usability in a testing environment.
The `run()` methos already accept the mode, now the parameter is exposed.