MCPcopy
hub / github.com/rclone/rclone / TestTouchUpdateTimestamp

Function TestTouchUpdateTimestamp

cmd/touch/touch_test.go:69–81  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

67}
68
69func TestTouchUpdateTimestamp(t *testing.T) {
70 r := fstest.NewRun(t)
71
72 srcFileName := "a"
73 content := "aaa"
74 file1 := r.WriteObject(context.Background(), srcFileName, content, t1)
75 r.CheckRemoteItems(t, file1)
76
77 timeAsArgument = "121212"
78 err := Touch(context.Background(), r.Fremote, "a")
79 require.NoError(t, err)
80 checkFile(t, r.Fremote, srcFileName, content)
81}
82
83func TestTouchUpdateTimestampWithCFlag(t *testing.T) {
84 r := fstest.NewRun(t)

Callers

nothing calls this directly

Calls 5

WriteObjectMethod · 0.95
CheckRemoteItemsMethod · 0.95
NewRunFunction · 0.92
TouchFunction · 0.85
checkFileFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…