diff options
author | Wolfy-J <[email protected]> | 2018-06-11 11:32:22 +0300 |
---|---|---|
committer | Wolfy-J <[email protected]> | 2018-06-11 11:32:22 +0300 |
commit | f1e09d869e9a177228aadb6385ad578d2e29f90d (patch) | |
tree | fbc6228c4fa314d9379414cd28c20e71316acd5b /state.go | |
parent | 2f135b359575cc1625d1461bb6d8e478da8ccf54 (diff) |
fixing tests
Diffstat (limited to 'state.go')
-rw-r--r-- | state.go | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -47,7 +47,7 @@ type state struct { } func newState(value int64) *state { - return &state{value: value, updated: time.Now().Unix()} + return &state{value: value, updated: time.Now().UnixNano()} } // String returns current state as string. @@ -91,7 +91,7 @@ func (s *state) NumExecs() int64 { // change state value (status) func (s *state) set(value int64) { atomic.StoreInt64(&s.value, value) - atomic.StoreInt64(&s.updated, time.Now().Unix()) + atomic.StoreInt64(&s.updated, time.Now().UnixNano()) } // register new execution atomically |