disable parallelism from our tests #885
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
go-tfe tests are failing with errors such as:
Because those same tests don't fail locally, only for the tflocal box, I approached the TDP team with the suspicion that the box configuration may need to be adjusted. Reason being that, to me, those errors seem to indicate that the agent cannot properly run terraform init (every time that it runs plan and apply) and it is timing out due to not having enough network capacity.
Well, turns out that the TDP team had recently approved a PR that actually, for the first time, forces integrations tests to use agents! In the past, the CI pipeline was running integration tests using an instance in terraform build worker, rather than using agent pools.
https://github.com/hashicorp/atlas/pull/19179
https://github.com/hashicorp/atlas/pull/19204
As a consequence of these changes, our go-tfe tests got thrown onto the agents by surprise. The tests failures that we are seeing are highlighting an underlying issue with the agent environment where you cannot run multiple concurrent runs because they will compete with each other and fail. All runs are executed from within a nomad container and they all touch the same directory path. Disabling parallelism for our test solves the issue. The test suite may be slower, however, now that we are using the same agent dispatch system that production uses, at least we can that the tests are more reliable.
Testing plan
External links
Output from tests
Including output from tests may require access to a TFE instance. Ignore this section if you have no environment to test against.