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

Unified Diff: common/auth/localauth/ctx_test.go

Issue 2988263002: Fix mocked time in 'common/auth/localauth' tests. (Closed)
Patch Set: doh Created 3 years, 5 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 | « no previous file | common/auth/localauth/server_test.go » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: common/auth/localauth/ctx_test.go
diff --git a/common/auth/localauth/ctx_test.go b/common/auth/localauth/ctx_test.go
index 97bfa9489a8f8189b113ae6d3d3059bbc40b3abc..a1ca40c825f99a9d35c4f72cb1ea2ea5a31755f8 100644
--- a/common/auth/localauth/ctx_test.go
+++ b/common/auth/localauth/ctx_test.go
@@ -32,7 +32,7 @@ func TestWithLocalAuth(t *testing.T) {
t.Parallel()
ctx := context.Background()
- ctx, _ = testclock.UseTime(ctx, testclock.TestRecentTimeLocal)
+ ctx, _ = testclock.UseTime(ctx, testclock.TestRecentTimeUTC)
gen := func(ctx context.Context, scopes []string, lifetime time.Duration) (*oauth2.Token, error) {
return &oauth2.Token{
@@ -54,7 +54,7 @@ func TestWithLocalAuth(t *testing.T) {
"secret": p.Secret,
"account_id": "acc_id",
})
- So(call(req), ShouldEqual, `HTTP 200 (json): {"access_token":"tok","expiry":1454502906}`)
+ So(call(req), ShouldEqual, `HTTP 200 (json): {"access_token":"tok","expiry":1454474106}`)
return nil
})
})
« no previous file with comments | « no previous file | common/auth/localauth/server_test.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698