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

Side by Side Diff: milo/appengine/buildbot/build_test.go

Issue 2926263003: Disable broken Milo tests. (Closed)
Patch Set: Created 3 years, 6 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 | « no previous file | milo/appengine/frontend/main_test.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 2016 The LUCI Authors. All rights reserved. 1 // Copyright 2016 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 buildbot 5 package buildbot
6 6
7 import ( 7 import (
8 "encoding/json" 8 "encoding/json"
9 "flag" 9 "flag"
10 "fmt" 10 "fmt"
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 71
72 Convey(`A test Environment`, t, func() { 72 Convey(`A test Environment`, t, func() {
73 c = testconfig.WithCommonClient(c, memcfg.New(bbAclConfigs)) 73 c = testconfig.WithCommonClient(c, memcfg.New(bbAclConfigs))
74 c = auth.WithState(c, &authtest.FakeState{ 74 c = auth.WithState(c, &authtest.FakeState{
75 Identity: identity.AnonymousIdentity, 75 Identity: identity.AnonymousIdentity,
76 IdentityGroups: []string{"all"}, 76 IdentityGroups: []string{"all"},
77 }) 77 })
78 78
79 for _, tc := range TestCases { 79 for _, tc := range TestCases {
80 Convey(fmt.Sprintf("Test Case: %s/%s", tc.Builder, tc.Bu ild), func() { 80 Convey(fmt.Sprintf("Test Case: %s/%s", tc.Builder, tc.Bu ild), func() {
81 » » » » build, err := Build(c, "debug", tc.Builder, tc.B uild) 81 » » » » _, err := Build(c, "debug", tc.Builder, tc.Build )
82 So(err, ShouldBeNil) 82 So(err, ShouldBeNil)
83 » » » » fname := fmt.Sprintf("%s.%d.build.json", tc.Buil der, tc.Build) 83 » » » » _ = fmt.Sprintf("%s.%d.build.json", tc.Builder, tc.Build)
84 » » » » So(build, shouldMatchExpectationsFor, fname) 84 » » » » // TODO(hinoka): Fix and re-enable. crbug/73156 2.
85 » » » » // So(build, shouldMatchExpectationsFor, fname)
85 }) 86 })
86 } 87 }
87 88
88 Convey(`Disallow anonomyous users from accessing internal builds `, func() { 89 Convey(`Disallow anonomyous users from accessing internal builds `, func() {
89 ds.Put(c, &buildbotBuild{ 90 ds.Put(c, &buildbotBuild{
90 Master: "fake", 91 Master: "fake",
91 Buildername: "fake", 92 Buildername: "fake",
92 Number: 1, 93 Number: 1,
93 Internal: true, 94 Internal: true,
94 }) 95 })
95 _, err := getBuild(c, "fake", "fake", 1) 96 _, err := getBuild(c, "fake", "fake", 1)
96 So(err, ShouldResemble, errNotAuth) 97 So(err, ShouldResemble, errNotAuth)
97 }) 98 })
98 }) 99 })
99 } 100 }
100 101
101 var internalConfig = ` 102 var internalConfig = `
102 buildbot: { 103 buildbot: {
103 internal_reader: "googlers" 104 internal_reader: "googlers"
104 public_subscription: "projects/luci-milo/subscriptions/buildbot-public" 105 public_subscription: "projects/luci-milo/subscriptions/buildbot-public"
105 internal_subscription: "projects/luci-milo/subscriptions/buildbot-privat e" 106 internal_subscription: "projects/luci-milo/subscriptions/buildbot-privat e"
106 } 107 }
107 ` 108 `
108 109
109 var bbAclConfigs = map[string]memcfg.ConfigSet{ 110 var bbAclConfigs = map[string]memcfg.ConfigSet{
110 "services/luci-milo": { 111 "services/luci-milo": {
111 "settings.cfg": internalConfig, 112 "settings.cfg": internalConfig,
112 }, 113 },
113 } 114 }
OLDNEW
« no previous file with comments | « no previous file | milo/appengine/frontend/main_test.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698