58 lines
1.6 KiB
Diff
58 lines
1.6 KiB
Diff
From cdaa60828f12a4e3f122e2120e57c6508456cb4d Mon Sep 17 00:00:00 2001
|
|
From: Jamie Anderson <jamieand@amazon.com>
|
|
Date: Wed, 3 Mar 2021 17:55:10 +0000
|
|
Subject: [PATCH] Skip mutating volume/local tests
|
|
|
|
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
|
---
|
|
volume/local/local_test.go | 5 +++++
|
|
1 file changed, 5 insertions(+)
|
|
|
|
diff --git a/volume/local/local_test.go b/volume/local/local_test.go
|
|
index 8045e87..12bc7d8 100644
|
|
--- a/volume/local/local_test.go
|
|
+++ b/volume/local/local_test.go
|
|
@@ -8,6 +8,7 @@ import (
|
|
"runtime"
|
|
"strings"
|
|
"testing"
|
|
+ "github.com/docker/docker/testutil"
|
|
|
|
"github.com/docker/docker/pkg/idtools"
|
|
"github.com/moby/sys/mountinfo"
|
|
@@ -31,6 +32,7 @@ func TestGetAddress(t *testing.T) {
|
|
}
|
|
|
|
func TestRemove(t *testing.T) {
|
|
+ testutil.RequiresRoot(t)
|
|
skip.If(t, runtime.GOOS == "windows", "FIXME: investigate why this test fails on CI")
|
|
rootDir, err := os.MkdirTemp("", "local-volume-test")
|
|
if err != nil {
|
|
@@ -74,6 +76,7 @@ func TestRemove(t *testing.T) {
|
|
}
|
|
|
|
func TestInitializeWithVolumes(t *testing.T) {
|
|
+ testutil.RequiresRoot(t)
|
|
rootDir, err := os.MkdirTemp("", "local-volume-test")
|
|
if err != nil {
|
|
t.Fatal(err)
|
|
@@ -106,6 +109,7 @@ func TestInitializeWithVolumes(t *testing.T) {
|
|
}
|
|
|
|
func TestCreate(t *testing.T) {
|
|
+ testutil.RequiresRoot(t)
|
|
rootDir, err := os.MkdirTemp("", "local-volume-test")
|
|
if err != nil {
|
|
t.Fatal(err)
|
|
@@ -277,6 +281,7 @@ func TestCreateWithOpts(t *testing.T) {
|
|
}
|
|
|
|
func TestRelaodNoOpts(t *testing.T) {
|
|
+ testutil.RequiresRoot(t)
|
|
rootDir, err := os.MkdirTemp("", "volume-test-reload-no-opts")
|
|
if err != nil {
|
|
t.Fatal(err)
|
|
--
|
|
2.25.0.24.gbc7a3d4
|
|
|