BUG: On Macs, the test playback is relying on timeouts to detect modal dialogs.
Now, this timeout can happen, even when we are not really waiting a modal dialog's exec() e.g. when we are simply waiting for a short time for the GUI to refresh. This was resulting in the test playing continuing oddly causing some tests that use too many modal dialogs to fail. This should fix that that issue.