Fix more ineffassign warnings.
[arvados.git] / services / keep-balance / collection_test.go
index a2200e1db90a4ddf69fd65112c432df9bbcba2c6..3ab9d07b2e2ed6bcc7220ae17aad4e6e7a665855 100644 (file)
@@ -5,10 +5,11 @@
 package main
 
 import (
+       "context"
        "sync"
        "time"
 
-       "git.curoverse.com/arvados.git/sdk/go/arvados"
+       "git.arvados.org/arvados.git/sdk/go/arvados"
        check "gopkg.in/check.v1"
 )
 
@@ -29,8 +30,8 @@ func (s *integrationSuite) TestIdenticalTimestamps(c *check.C) {
                        longestStreak := 0
                        var lastMod time.Time
                        sawUUID := make(map[string]bool)
-                       err := EachCollection(s.client, pageSize, func(c arvados.Collection) error {
-                               if c.ModifiedAt == nil {
+                       err := EachCollection(context.Background(), s.client, pageSize, func(c arvados.Collection) error {
+                               if c.ModifiedAt.IsZero() {
                                        return nil
                                }
                                if sawUUID[c.UUID] {
@@ -39,14 +40,14 @@ func (s *integrationSuite) TestIdenticalTimestamps(c *check.C) {
                                }
                                got[trial] = append(got[trial], c.UUID)
                                sawUUID[c.UUID] = true
-                               if lastMod == *c.ModifiedAt {
+                               if lastMod == c.ModifiedAt {
                                        streak++
                                        if streak > longestStreak {
                                                longestStreak = streak
                                        }
                                } else {
                                        streak = 0
-                                       lastMod = *c.ModifiedAt
+                                       lastMod = c.ModifiedAt
                                }
                                return nil
                        }, nil)