Remove test-function-check_playbook_file_removed_and_added test #10982
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:
The
ansible-file-removed-and-added
test in upstream CI is a very slow test which usually takes 8 - 10 minutes, as reported by @jan-cerny. I investigated this case and concluded the test can be safely removed.Context:
The test was introduced to catch a very specific case already fixed by #7228
I believe this was one of my first PRs in the project and on it I fixed an inefficient usage of Ansible modules.
The Playbook should use the
copy
module for that specific case but instead it used an inefficient combination offile
andlineinfile
to achieve the same outcome.Back in the time I remember to search this pattern in other rules but this was, fortunately, the unique case I found.
So, the test was introduced by #7376 in order to catch if this specific case is again proposed in any PR.
Rationale:
It is very hard to have this specific case again in any PR. This never happened again in within at least two years.
If this happen, it is also pretty easy to see during the review of Ansible playbooks. If not, it is not also harmful. It will show unnecessary
changed
in a eventual task.Review Hints:
This PR simply removes stuff. If nothing is broken by these changes, it should be fine.