Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(42)

Unified Diff: go/src/infra/tools/cipd/clock_test.go

Issue 1129043003: cipd: Refactor client to make it more readable. (Closed) Base URL: https://chromium.googlesource.com/infra/infra.git@master
Patch Set: Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « go/src/infra/tools/cipd/clock.go ('k') | go/src/infra/tools/cipd/common.go » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: go/src/infra/tools/cipd/clock_test.go
diff --git a/go/src/infra/tools/cipd/clock_test.go b/go/src/infra/tools/cipd/clock_test.go
deleted file mode 100644
index 2e5bedda071dbe057cf6e9d76add842616b93dbd..0000000000000000000000000000000000000000
--- a/go/src/infra/tools/cipd/clock_test.go
+++ /dev/null
@@ -1,26 +0,0 @@
-// Copyright 2014 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-package cipd
-
-// No tests in this file, just a mockClock function used from other tests.
-
-import (
- "time"
-
- . "github.com/smartystreets/goconvey/convey"
-)
-
-type mockedClocked struct {
- now time.Time
-}
-
-func (c *mockedClocked) Now() time.Time { return c.now }
-func (c *mockedClocked) Sleep(d time.Duration) { c.now = c.now.Add(d) }
-
-func mockClock(now time.Time) {
- prev := clock
- clock = &mockedClocked{now: now}
- Reset(func() { clock = prev })
-}
« no previous file with comments | « go/src/infra/tools/cipd/clock.go ('k') | go/src/infra/tools/cipd/common.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698