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

Unified Diff: common/errors/multierror_test.go

Issue 1284323002: Make LazyMultiError only constructable via function (Closed) Base URL: https://github.com/luci/luci-go.git@master
Patch Set: Created 5 years, 4 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
« common/errors/multierror.go ('K') | « common/errors/multierror.go ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: common/errors/multierror_test.go
diff --git a/common/errors/multierror_test.go b/common/errors/multierror_test.go
index a7a15329e1f430accde5798033af90a1a3d0b129..435cc452c9982f916c92494969ecbc9b5eed0974 100644
--- a/common/errors/multierror_test.go
+++ b/common/errors/multierror_test.go
@@ -65,7 +65,7 @@ func TestLazyMultiError(t *testing.T) {
t.Parallel()
Convey("Test LazyMultiError", t, func() {
- lme := LazyMultiError{Size: 10}
+ lme := NewLazyMultiError(10)
So(lme.Get(), ShouldEqual, nil)
e := errors.New("sup")
@@ -80,7 +80,7 @@ func TestLazyMultiError(t *testing.T) {
So(func() { lme.Assign(20, e) }, ShouldPanic)
Convey("Try to freak out the race detector", func() {
- lme := LazyMultiError{Size: 64}
+ lme := NewLazyMultiError(64)
Convey("all nils", func() {
wg := sync.WaitGroup{}
for i := 0; i < 64; i++ {
« common/errors/multierror.go ('K') | « common/errors/multierror.go ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698