Issue #3174928 by alexpott, andypost: Improve the stability of core JS testing and prepare for update of MinkSelenium2Driver