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

Side by Side Diff: logdog/client/coordinator/query_test.go

Issue 2575383002: Add server/cache support to gaeconfig. (Closed)
Patch Set: Un-collapse. Created 3 years, 11 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 unified diff | Download patch
« no previous file with comments | « logdog/client/coordinator/query.go ('k') | logdog/client/coordinator/stream.go » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The LUCI Authors. All rights reserved. 1 // Copyright 2015 The LUCI Authors. All rights reserved.
2 // Use of this source code is governed under the Apache License, Version 2.0 2 // Use of this source code is governed under the Apache License, Version 2.0
3 // that can be found in the LICENSE file. 3 // that can be found in the LICENSE file.
4 4
5 package coordinator 5 package coordinator
6 6
7 import ( 7 import (
8 "errors" 8 "errors"
9 "fmt" 9 "fmt"
10 "testing" 10 "testing"
11 11
12 "github.com/luci/luci-go/common/clock/testclock" 12 "github.com/luci/luci-go/common/clock/testclock"
13 "github.com/luci/luci-go/common/proto/google" 13 "github.com/luci/luci-go/common/proto/google"
14 "github.com/luci/luci-go/common/testing/prpctest" 14 "github.com/luci/luci-go/common/testing/prpctest"
15 "github.com/luci/luci-go/grpc/grpcutil" 15 "github.com/luci/luci-go/grpc/grpcutil"
16 "github.com/luci/luci-go/logdog/api/endpoints/coordinator/logs/v1" 16 "github.com/luci/luci-go/logdog/api/endpoints/coordinator/logs/v1"
17 "github.com/luci/luci-go/logdog/api/logpb" 17 "github.com/luci/luci-go/logdog/api/logpb"
18 "github.com/luci/luci-go/luci_config/common/cfgtypes" 18 "github.com/luci/luci-go/luci_config/common/cfgtypes"
19
19 "golang.org/x/net/context" 20 "golang.org/x/net/context"
20 21
21 . "github.com/smartystreets/goconvey/convey" 22 . "github.com/smartystreets/goconvey/convey"
22 ) 23 )
23 24
24 type testQueryLogsService struct { 25 type testQueryLogsService struct {
25 testLogsServiceBase 26 testLogsServiceBase
26 27
27 LR logdog.QueryRequest 28 LR logdog.QueryRequest
28 H func(*logdog.QueryRequest) (*logdog.QueryResponse, error) 29 H func(*logdog.QueryRequest) (*logdog.QueryResponse, error)
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after
217 Convey(`Will return ErrNoAccess if permission denied.`, func() { 218 Convey(`Will return ErrNoAccess if permission denied.`, func() {
218 svc.H = func(*logdog.QueryRequest) (*logdog.Quer yResponse, error) { 219 svc.H = func(*logdog.QueryRequest) (*logdog.Quer yResponse, error) {
219 return nil, grpcutil.Unauthenticated 220 return nil, grpcutil.Unauthenticated
220 } 221 }
221 222
222 So(client.Query(c, project, path, q, accumulate) , ShouldEqual, ErrNoAccess) 223 So(client.Query(c, project, path, q, accumulate) , ShouldEqual, ErrNoAccess)
223 }) 224 })
224 }) 225 })
225 }) 226 })
226 } 227 }
OLDNEW
« no previous file with comments | « logdog/client/coordinator/query.go ('k') | logdog/client/coordinator/stream.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698