Skip to content

fix: flaky TestPrunePromptTermination test - #7168

Open
hirehamir wants to merge 1 commit into
docker:masterfrom
hirehamir:fix/flaky-test-prune-prompt-termination
Open

fix: flaky TestPrunePromptTermination test#7168
hirehamir wants to merge 1 commit into
docker:masterfrom
hirehamir:fix/flaky-test-prune-prompt-termination

Conversation

@hirehamir

Copy link
Copy Markdown
Contributor

- What I did

Addressed #5802

- How I did it

I kept the write end of the pipe alive for the duration of the test with

defer w.Close()

- How to verify it

# without the changes from this branch: fails most runs
# with the changes from this branch: 0 failures
GOGC=1 GOMEMLIMIT=8MiB go test ./cli/command/container/ -run TestContainerPrunePromptTermination -count=40 -v
GC forced (GOGC=1 GOMEMLIMIT=8MiB) GC off (GOGC=off)
without this change 33 of 40 fail 0 of 40 fail
with this change 0 of 40 fail 0 of 40 fail

@codecov-commenter

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 0% with 2 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
internal/test/cmd.go 0.00% 2 Missing ⚠️

📢 Thoughts on this report? Let us know!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants