diff --git a/backend/protondrive/protondrive_test.go b/backend/protondrive/protondrive_test.go index 86aa0c075..ec7d518ea 100644 --- a/backend/protondrive/protondrive_test.go +++ b/backend/protondrive/protondrive_test.go @@ -1,6 +1,7 @@ package protondrive_test import ( + "flag" "testing" "github.com/rclone/rclone/backend/protondrive" @@ -9,6 +10,13 @@ import ( // TestIntegration runs integration tests against the remote func TestIntegration(t *testing.T) { + // A golden capture runs with the real config, where this test would + // write to and delete from the live remote if -run let it through. + for _, name := range []string{"capture", "capture-remote"} { + if f := flag.Lookup(name); f != nil && f.Value.String() != "" { + t.Skipf("-%s is set: not running integration tests during a golden capture", name) + } + } fstests.Run(t, &fstests.Opt{ RemoteName: "TestProtonDrive:", NilObject: (*protondrive.Object)(nil),