mirror of
https://github.com/rclone/rclone.git
synced 2025-09-16 08:36:38 +02:00
local: fix time zones on tests
Before this change, TestMetadata could fail due to a difference between the user's local time zone and UTC causing the string representation of the date to be off by one day. This change fixes the issue by comparing both in the Local time zone.
This commit is contained in:
@@ -334,7 +334,7 @@ func TestMetadata(t *testing.T) {
|
||||
|
||||
func testMetadata(t *testing.T, r *fstest.Run, o *Object, when time.Time) {
|
||||
ctx := context.Background()
|
||||
whenRFC := when.Format(time.RFC3339Nano)
|
||||
whenRFC := when.Local().Format(time.RFC3339Nano)
|
||||
const dayLength = len("2001-01-01")
|
||||
|
||||
f := r.Flocal.(*Fs)
|
||||
|
Reference in New Issue
Block a user