Skip to content

Commit 3ac31be

Browse files
HeikoKlaremickaelistria
authored andcommitted
Rewrite ParallelBuildChainTest and fix random failures #609
The ParallelBuildChainTest has random failing test methods. Its implementation relies on specific timing behavior. It spawns builds for different projects or the workspace that take a specific (absolute, hard-coded) amount of time to finish. This has two drawbacks: 1. It induces a race conditions, as whenever execution times exceed these amounts of time (e.g., due to slow infrastructure), the tests will randomly fail. 2. The tests spent much time for unnecessary busy waiting making them require more time / resources than necessary. This change addresses the issues by not relying on builds to finish but on builds to be started. This is sufficient, as the tests are supposed to validate under which circumstances parallel builds are allowed or expected. To this end, the test now uses either immediately finishing builds or by making them run for a very long time. The long running builds will only be validated regarding whether they have started and will be explicitly aborted when the actual test has finished. This removes the necessity to rely on specific timing behavior. Only one test case validating that a build is not started uses a timeout to wait for, as a blocked build cannot be detected easily. This change also adds two additional test cases reflecting further combinations of scheduling rules and build configurations. Fixes #609.
1 parent adca2ac commit 3ac31be

File tree

3 files changed

+552
-338
lines changed

3 files changed

+552
-338
lines changed

0 commit comments

Comments
 (0)