mirror of
https://github.com/rclone/rclone.git
synced 2024-11-22 08:23:47 +01:00
sync: don't test reading metadata if we can't write it
This commit is contained in:
parent
a52e887ddd
commit
003f4531fe
@ -152,10 +152,10 @@ func testCopyMetadata(t *testing.T, createEmptySrcDirs bool) {
|
|||||||
r.CheckDirectoryModTimes(t, dirPath)
|
r.CheckDirectoryModTimes(t, dirPath)
|
||||||
|
|
||||||
// Check that the metadata on the directory and file is correct
|
// Check that the metadata on the directory and file is correct
|
||||||
if features.ReadMetadata {
|
if features.WriteMetadata && features.ReadMetadata {
|
||||||
fstest.CheckEntryMetadata(ctx, t, r.Fremote, fstest.NewObject(ctx, t, r.Fremote, filePath), fileMetadata)
|
fstest.CheckEntryMetadata(ctx, t, r.Fremote, fstest.NewObject(ctx, t, r.Fremote, filePath), fileMetadata)
|
||||||
}
|
}
|
||||||
if features.ReadDirMetadata {
|
if features.WriteDirMetadata && features.ReadDirMetadata {
|
||||||
fstest.CheckEntryMetadata(ctx, t, r.Fremote, fstest.NewDirectory(ctx, t, r.Fremote, dirPath), dirMetadata)
|
fstest.CheckEntryMetadata(ctx, t, r.Fremote, fstest.NewDirectory(ctx, t, r.Fremote, dirPath), dirMetadata)
|
||||||
}
|
}
|
||||||
if !createEmptySrcDirs {
|
if !createEmptySrcDirs {
|
||||||
|
Loading…
Reference in New Issue
Block a user