-
Notifications
You must be signed in to change notification settings - Fork 112
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
phantomjs_test: resilience improvements (#453)
phantomjs tests fail spuriously on our CI infrastructure with two different errors: 1. G_testRunner is not defined. I believe this is due to the harness setTimeout of 200ms firing before the js binary under test finished loading. 2. The test completes successfully, but Bazel does not get the message and eventually reports it as TIMEOUT. I believe this is due to the test runner resource fetch timing out. These errors are addressed as follows: 1. Add an attribute to enable phantomjs debug logging. 2. Load the test runner as the last script instead of the first. That eliminates the race to solve issue 1. 3. Detect and log resource timeouts and retry the test. Assuming the resource timeouts happen with a low enough frequency, this should get tests that suffer one resource timeout to succeed on retry. Additionally, the logging will make the situation clear -- previously nothing was logged. If resource timeouts continue to be an issue, the next step would be to increase the 2s hardcoded timeout, or make it configurable. Co-authored-by: Goktug Gokdogan <[email protected]>
- Loading branch information
Showing
4 changed files
with
53 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters