mirror of
https://github.com/rclone/rclone.git
synced 2025-12-11 22:14:05 +01:00
fstest: remove spurious contents return from PutTestContents and friends
This commit is contained in:
@@ -38,7 +38,7 @@ func (f *Fs) TestInternalReadOnly(t *testing.T) {
|
||||
// Put a file onto the read only fs
|
||||
contents := random.String(50)
|
||||
file1 := fstest.NewItem(dir+"/file.txt", contents, time.Now())
|
||||
_, obj1 := fstests.PutTestContents(ctx, t, rofs, &file1, contents, true)
|
||||
obj1 := fstests.PutTestContents(ctx, t, rofs, &file1, contents, true)
|
||||
|
||||
// Check read from readonly fs via union
|
||||
o, err := f.NewObject(ctx, file1.Path)
|
||||
@@ -109,14 +109,14 @@ func TestMoveCopy(t *testing.T) {
|
||||
// Put a file onto the local fs
|
||||
contentsLocal := random.String(50)
|
||||
fileLocal := fstest.NewItem("local.txt", contentsLocal, time.Now())
|
||||
_, _ = fstests.PutTestContents(ctx, t, fLocal, &fileLocal, contentsLocal, true)
|
||||
_ = fstests.PutTestContents(ctx, t, fLocal, &fileLocal, contentsLocal, true)
|
||||
objLocal, err := f.NewObject(ctx, fileLocal.Path)
|
||||
require.NoError(t, err)
|
||||
|
||||
// Put a file onto the memory fs
|
||||
contentsMemory := random.String(60)
|
||||
fileMemory := fstest.NewItem("memory.txt", contentsMemory, time.Now())
|
||||
_, _ = fstests.PutTestContents(ctx, t, fMemory, &fileMemory, contentsMemory, true)
|
||||
_ = fstests.PutTestContents(ctx, t, fMemory, &fileMemory, contentsMemory, true)
|
||||
objMemory, err := f.NewObject(ctx, fileMemory.Path)
|
||||
require.NoError(t, err)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user