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

Unified Diff: logdog/appengine/coordinator/context_test.go

Issue 2626433004: Move "common/config" common types into cfgtypes. (Closed)
Patch Set: 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « logdog/appengine/coordinator/context.go ('k') | logdog/appengine/coordinator/coordinatorTest/context.go » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: logdog/appengine/coordinator/context_test.go
diff --git a/logdog/appengine/coordinator/context_test.go b/logdog/appengine/coordinator/context_test.go
index 8ef09cc9efa265d6faf701fee0fdf8b81f552a49..428f7716fcfeff5ce3a8061cf98acd25c333208f 100644
--- a/logdog/appengine/coordinator/context_test.go
+++ b/logdog/appengine/coordinator/context_test.go
@@ -13,6 +13,7 @@ import (
luciConfig "github.com/luci/luci-go/common/config"
"github.com/luci/luci-go/logdog/api/config/svcconfig"
"github.com/luci/luci-go/logdog/appengine/coordinator/config"
+ "github.com/luci/luci-go/luci_config/common/cfgtypes"
"github.com/luci/luci-go/server/auth"
"github.com/luci/luci-go/server/auth/authtest"
"github.com/luci/luci-go/server/auth/identity"
@@ -27,10 +28,10 @@ type testServices struct {
Services
configErr error
- configs map[luciConfig.ProjectName]*svcconfig.ProjectConfig
+ configs map[cfgtypes.ProjectName]*svcconfig.ProjectConfig
}
-func (s *testServices) ProjectConfig(c context.Context, project luciConfig.ProjectName) (*svcconfig.ProjectConfig, error) {
+func (s *testServices) ProjectConfig(c context.Context, project cfgtypes.ProjectName) (*svcconfig.ProjectConfig, error) {
if err := s.configErr; err != nil {
return nil, err
}
@@ -63,7 +64,7 @@ func TestWithProjectNamespace(t *testing.T) {
// Fake service with fake project configs.
svc := testServices{
- configs: map[luciConfig.ProjectName]*svcconfig.ProjectConfig{
+ configs: map[cfgtypes.ProjectName]*svcconfig.ProjectConfig{
"all-access": {
ReaderAuthGroups: []string{"all"},
WriterAuthGroups: []string{"all"},
@@ -160,7 +161,7 @@ func TestWithProjectNamespace(t *testing.T) {
Convey(`When config service returns an unexpected error`, func() {
svc.configErr = errors.New("misc")
- for _, proj := range []luciConfig.ProjectName{"all-access", "exclusive-access", "does-not-exist"} {
+ for _, proj := range []cfgtypes.ProjectName{"all-access", "exclusive-access", "does-not-exist"} {
Convey(fmt.Sprintf(`Will fail to access %q with Internal.`, proj), func() {
So(WithProjectNamespace(&c, "all-access", tc.access), ShouldBeRPCInternal)
})
« no previous file with comments | « logdog/appengine/coordinator/context.go ('k') | logdog/appengine/coordinator/coordinatorTest/context.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698