X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/c900f416c36cd74675c5bf4c33ad1dbe5d1e78fa..0bcf6869ed21baf852ed9278413a93df6b002b43:/services/keep-balance/balance_test.go diff --git a/services/keep-balance/balance_test.go b/services/keep-balance/balance_test.go index 682a5fb070..b93939c052 100644 --- a/services/keep-balance/balance_test.go +++ b/services/keep-balance/balance_test.go @@ -76,7 +76,7 @@ func (bal *balancerSuite) SetUpTest(c *check.C) { bal.KeepServices[srv.UUID] = srv } - bal.MinMtime = time.Now().Unix() - bal.signatureTTL + bal.MinMtime = time.Now().UnixNano() - bal.signatureTTL*1e9 } func (bal *balancerSuite) TestPerfect(c *check.C) { @@ -240,7 +240,7 @@ func (bal *balancerSuite) srvList(knownBlockID int, order slots) (srvs []*KeepSe // replList is like srvList but returns an "existing replicas" slice, // suitable for a BlockState test fixture. func (bal *balancerSuite) replList(knownBlockID int, order slots) (repls []Replica) { - mtime := time.Now().Unix() - bal.signatureTTL - 86400 + mtime := time.Now().UnixNano() - (bal.signatureTTL+86400)*1e9 for _, srv := range bal.srvList(knownBlockID, order) { repls = append(repls, Replica{srv, mtime}) mtime++