-
Notifications
You must be signed in to change notification settings - Fork 2.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improvement on basic_setup() of helpers of test/system (Clean up phase) #9930
Comments
I would like to work on the issue. Due to some obligation, I cannot until early May. If the issue is to be solved, and assigned to me, I am more than happy to do so when I get back. |
I have assigned it to you, I don't think anyone is going to grab it. Lots of other work to be done. |
Removing |
A friendly reminder that this issue had no activity for 30 days. |
@edsantiago PTAL |
@aliaslanturk does #10008 address your concerns? |
A friendly reminder that this issue had no activity for 30 days. |
Since we never heard back, I am going to assume yes, Please reopen if I am mistaken. |
/kind feature
This issue proposes an improvement on basic_setup() function of helpers in its clean up phase.
Current flow of the function
basic_setup() function includes following lines to clean up unnecessary images before running tests:
The for loop iterates to find the test image and remove any other image if present. Removing part uses
{{.Repository}}:{{.Tag}}
and{{.ID}}
keywords to feedpodman rmi
. First key (Repository:Tag) works fine. However, ID key causes a problem if the test image has been tagged before.What happens?
When a system test (XXX-*.bats) uses default
basic_setup()
, test passes if normal conditions are present.The problem occurs if the test image
($IMAGE/$PODMAN_TEST_IMAGE_FQN)
was tagged before as in:podman tag $IMAGE same_image_with:new-tag
Following output can be observed as a result of the failure :
Root cause
As far as I can trace it, the problem is caused by
run_podman rmi --force "$2" >/dev/null 2>&1 || true
which removes the test image sincerun_podman rmi --force "$1" >/dev/null 2>&1 || true
already removed the new_tag.An improvement can be provided to avoid this case. I have not find a flow that reproduces the problem naturally, yet.
The text was updated successfully, but these errors were encountered: