When we execute the same set of end-to-end browser-automated tests on BrowserStack, we notice a dramatic slowdown - tests are much slower than if executed locally and there are occasional failures because of timing issues. We try to address the failures by adding explicit waits, which overall make the tests less readable and the test flow less understandable and clean.
What are the general guidelines to improve on end-to-end testing execution speed?
Our stack includes Protractor/WebDriverJS; we use grunt
tasks to start a local build server and expose it to BrowserStack via ngrok
.