Provide hook to prevent browser alerts from being shown when logging

For automation and some uses of WebODF, a browser alert window is not a suitable way of communicating errors as they usually require user interaction. Though longer term WebODF should grow (or use) a more mature logging framework, for the immediate requirements for Bella I simply need a way of eliminating calls to alert.

This patch improves information provided when an assertion occurs, and cleans up the assert function parameters to remove the non-standard callback param.