Skip to content

Commit 24d874c

Browse files
committed
Mark flaky tests
Signed-off-by: apostasie <[email protected]>
1 parent 29d963c commit 24d874c

File tree

6 files changed

+24
-3
lines changed

6 files changed

+24
-3
lines changed

cmd/nerdctl/container/container_create_linux_test.go

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,11 @@ func TestCreateWithTty(t *testing.T) {
187187
func TestIssue2993(t *testing.T) {
188188
testCase := nerdtest.Setup()
189189

190-
testCase.Require = test.Not(nerdtest.Docker)
190+
testCase.Require = test.Require(
191+
test.Not(nerdtest.Docker),
192+
// Maybe the use of a custom data root has an impact?
193+
nerdtest.IsFlaky("https://github.com/containerd/nerdctl/issues/3518"),
194+
)
191195

192196
const (
193197
containersPathKey = "containersPath"

cmd/nerdctl/image/image_history_test.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,9 @@ func TestImageHistory(t *testing.T) {
7676
test.Not(test.Windows),
7777
// XXX Currently, history does not work on non-native platform, so, we cannot test reliably on other platforms
7878
test.Arm64,
79+
// XXX this here is very likely breaking other tests because of one of the variants of
80+
// https://github.com/containerd/nerdctl/issues/3513 so, making it private to try avoid that
81+
nerdtest.Private,
7982
),
8083
Setup: func(data test.Data, helpers test.Helpers) {
8184
helpers.Ensure("pull", "--platform", "linux/arm64", testutil.CommonImage)

cmd/nerdctl/image/image_inspect_test.go

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ package image
1818

1919
import (
2020
"encoding/json"
21+
"runtime"
2122
"strings"
2223
"testing"
2324

@@ -35,7 +36,7 @@ func TestImageInspectSimpleCases(t *testing.T) {
3536
testCase := &test.Case{
3637
Description: "TestImageInspect",
3738
Setup: func(data test.Data, helpers test.Helpers) {
38-
helpers.Ensure("pull", testutil.CommonImage)
39+
helpers.Ensure("pull", "--quiet", testutil.CommonImage)
3940
},
4041
SubTests: []*test.Case{
4142
{
@@ -64,6 +65,10 @@ func TestImageInspectSimpleCases(t *testing.T) {
6465
},
6566
}
6667

68+
if runtime.GOOS == "windows" {
69+
testCase.Require = nerdtest.IsFlaky("https://github.com/containerd/nerdctl/issues/3524")
70+
}
71+
6772
testCase.Run(t)
6873
}
6974

cmd/nerdctl/image/image_list_test.go

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,10 @@ func TestImagesFilter(t *testing.T) {
125125

126126
testCase := &test.Case{
127127
Description: "TestImagesFilter",
128-
Require: nerdtest.Build,
128+
Require: test.Require(
129+
nerdtest.Build,
130+
nerdtest.IsFlaky("https://github.com/containerd/nerdctl/issues/3512"),
131+
),
129132
Setup: func(data test.Data, helpers test.Helpers) {
130133
helpers.Ensure("pull", testutil.CommonImage)
131134
helpers.Ensure("tag", testutil.CommonImage, "taggedimage:one-fragment-one")

cmd/nerdctl/image/image_save_test.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ package image
1919
import (
2020
"os"
2121
"path/filepath"
22+
"runtime"
2223
"strings"
2324
"testing"
2425

@@ -70,6 +71,10 @@ func TestSave(t *testing.T) {
7071
// See https://github.com/containerd/nerdctl/issues/3425 and others for details.
7172
testCase.Require = nerdtest.Private
7273

74+
if runtime.GOOS == "windows" {
75+
testCase.Require = test.Require(testCase.Require, nerdtest.IsFlaky("https://github.com/containerd/nerdctl/issues/3524"))
76+
}
77+
7378
testCase.SubTests = []*test.Case{
7479
{
7580
Description: "Single image, by id",

cmd/nerdctl/ipfs/ipfs_compose_linux_test.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@ func TestIPFSCompNoBuild(t *testing.T) {
4646
test.Not(nerdtest.Docker),
4747
nerdtest.Registry,
4848
nerdtest.IPFS,
49+
nerdtest.IsFlaky("https://github.com/containerd/nerdctl/issues/3510"),
4950
// See note below
5051
// nerdtest.Private,
5152
)

0 commit comments

Comments
 (0)