Skip to content

Commit d9f01f2

Browse files
authored
Bugfix for dir attribute update: Allow 0 in NSec values (#74)
1 parent 2995bb3 commit d9f01f2

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

pkg/dataplane/test/sync_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,7 @@ func (suite *syncContainerTestSuite) TestSetDirsAttrs() {
227227
updateObjectInput := &v3io.UpdateObjectInput{}
228228
updateObjectInput.Path = fmt.Sprintf("%sdir-test/", path)
229229
layout := "2006-01-02T15:04:05.00Z"
230-
atime, err := time.Parse(layout, "2020-11-22T19:27:33.49Z")
230+
atime, err := time.Parse(layout, "2020-11-22T19:27:33.00Z")
231231
suite.Require().NoError(err)
232232
ctime, err := time.Parse(layout, "2020-09-20T15:10:35.08Z")
233233
suite.Require().NoError(err)

pkg/dataplane/types.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -212,11 +212,11 @@ type DirAttributes struct {
212212
UID int `json:"uid"`
213213
GID int `json:"gid"`
214214
AtimeSec int `json:"atime.sec,omitempty"`
215-
AtimeNSec int `json:"atime.nsec,omitempty"`
215+
AtimeNSec int `json:"atime.nsec"`
216216
CtimeSec int `json:"ctime.sec,omitempty"`
217-
CtimeNSec int `json:"ctime.nsec,omitempty"`
217+
CtimeNSec int `json:"ctime.nsec"`
218218
MtimeSec int `json:"mtime.sec,omitempty"`
219-
MtimeNSec int `json:"mtime.nsec,omitempty"`
219+
MtimeNSec int `json:"mtime.nsec"`
220220
}
221221

222222
//

0 commit comments

Comments
 (0)