From f8e398fce157376088dcf060f73789ba3c2eb6bb Mon Sep 17 00:00:00 2001 From: Lucas Winther Date: Thu, 12 Nov 2026 12:31:02 +0100 Subject: [PATCH] protondrive: skip the live integration test during a golden capture Co-Authored-By: Claude Opus 5.5 --- backend/protondrive/protondrive_test.go | 8 ++++++++ 1 file changed, 8 insertions(+) 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),