gwt /
gwt /
b7b978f720af750dc1309c97a5b256160b8c90e9 Fix a race condition in the GWTTestCase runner.
If a web browser was quick to report its first results to the GWTTestCase
servlet, RunStyle.launchModule() was sometimes called twice. This caused
an unexpected page reload, so there were more clients than expected
but the first one was gone, resulting in the test timing out.
The race is most likely when the first test block is small, for example
when the first test class is in a different module than the rest and
has few test methods.
The race was in notDone() where the code would check the number of clients
and then later check if it got enough test results back. If the first check
failed but the second one succeeded, notDone() could return false without
setting firstLaunch to false.
Fixed by replacing the firstLaunch variable with two variables that have
clearer purposes.
Change-Id: Id75762a714fd489f624734308017ac53cddf886f
Review-Link: https://gwt-review.googlesource.com/#/c/2150/
Review by: mdempsky@google.com
git-svn-id: https://google-web-toolkit.googlecode.com/svn/trunk@11547 8db76d5a-ed1c-0410-87a9-c151d255dfc7
1 file changed