mirror of
https://github.com/rclone/rclone.git
synced 2024-11-25 09:54:44 +01:00
operations: use --download for TestApplyTransforms #7591
This makes it possible to run the test even on remotes without MD5 support.
This commit is contained in:
parent
f3680d222c
commit
885a543023
@ -563,9 +563,6 @@ func TestApplyTransforms(t *testing.T) {
|
||||
|
||||
testScenario := func(checkfileName, remotefileName, scenario string) {
|
||||
r := fstest.NewRunIndividual(t)
|
||||
if !r.Flocal.Hashes().Contains(hashType) || !r.Fremote.Hashes().Contains(hashType) {
|
||||
t.Skipf("Fs lacks %s, skipping", hashType)
|
||||
}
|
||||
ctx := context.Background()
|
||||
ci := fs.GetConfig(ctx)
|
||||
opt := operations.CheckOpt{}
|
||||
@ -580,7 +577,7 @@ func TestApplyTransforms(t *testing.T) {
|
||||
ci.NoUnicodeNormalization = true
|
||||
ci.IgnoreCaseSync = false
|
||||
accounting.GlobalStats().ResetCounters()
|
||||
err := operations.CheckSum(ctx, r.Fremote, r.Flocal, "test.sum", hashType, &opt, false)
|
||||
err := operations.CheckSum(ctx, r.Fremote, r.Flocal, "test.sum", hashType, &opt, true)
|
||||
assert.Error(t, err, "no expected error for %s %v %v", testname, checkfileName, remotefileName)
|
||||
|
||||
testname = scenario + " (with normalization)"
|
||||
@ -588,7 +585,7 @@ func TestApplyTransforms(t *testing.T) {
|
||||
ci.NoUnicodeNormalization = false
|
||||
ci.IgnoreCaseSync = true
|
||||
accounting.GlobalStats().ResetCounters()
|
||||
err = operations.CheckSum(ctx, r.Fremote, r.Flocal, "test.sum", hashType, &opt, false)
|
||||
err = operations.CheckSum(ctx, r.Fremote, r.Flocal, "test.sum", hashType, &opt, true)
|
||||
assert.NoError(t, err, "unexpected error for %s %v %v", testname, checkfileName, remotefileName)
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user