Fixed issue with selector not being found on load.
Add event listener to output page's JS errors to console.
Fix issue where modals were not fully loaded in time for tests.
Roll back increased CasperJS timeout.
Merge pull request #3104 from DFurnes/fix-failing-tests

Fix failing tests