test: pull image in setup for TestRunUmask and TestRunUserGID#4998
Open
mayur-tolexo wants to merge 1 commit into
Open
test: pull image in setup for TestRunUmask and TestRunUserGID#4998mayur-tolexo wants to merge 1 commit into
mayur-tolexo wants to merge 1 commit into
Conversation
Both tests use AlpineImage but never pull it, relying on the default run --pull missing behavior. When the image manifest is already in the shared content store but a layer blob has been removed by a concurrent test's prune/GC, run sees the image as present and skips the fetch, so it fails with "content digest <sha> not found". Pull the image in Setup, matching the existing pattern in TestRunAddGroup_CVE_2023_25173. pull re-fetches any missing blobs, so the store is repaired before the run. Signed-off-by: Mayur Das <mayur.das@neevcloud.com>
AkihiroSuda
reviewed
Jun 23, 2026
| func TestRunUserGID(t *testing.T) { | ||
| testCase := nerdtest.Setup() | ||
| testCase.Setup = func(data test.Data, helpers test.Helpers) { | ||
| helpers.Ensure("pull", "--quiet", testutil.AlpineImage) |
Member
There was a problem hiding this comment.
Should we rather de-parallelize the test that removes the alpine image?
Otherwise we will need to duplicate this Setup function to almost all the tests?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
TestRunUmask and TestRunUserGID use AlpineImage but never pull it, so they rely on
run --pull missingfinding it in the content store. The content store is shared across the parallel integration tests, and when a concurrent test prunes/GCs a layer blob while the image manifest is still around,runtreats the image as present and skips the fetch. It then fails withcontent digest <sha> not found.Saw this on the almalinux-8 rootless lane:
The fix pulls the image in Setup, the same thing TestRunAddGroup_CVE_2023_25173 already does.
pullre-fetches any missing blobs, so the store is consistent before the run.