mirror of
https://github.com/golang/go
synced 2024-11-22 15:04:52 -07:00
c50e4f5e2f
Refactors the benchmarks and test code. Now benchmarks can call Errorf, Fail, etc., and the runner will act accordingly. Because functionality has been folded into an embedded type, a number of methods' docs no longer appear in godoc output. A fix is underway; if it doesn't happen fast enough, I'll add wrapper methods to restore the documentation. R=bradfitz, adg, rsc CC=golang-dev https://golang.org/cl/5492060
21 lines
481 B
Go
21 lines
481 B
Go
// errchk $G -e $D/$F.go
|
|
|
|
// Copyright 2009 The Go Authors. All rights reserved.
|
|
// Use of this source code is governed by a BSD-style
|
|
// license that can be found in the LICENSE file.
|
|
|
|
package main
|
|
|
|
import "testing"
|
|
|
|
func main() {
|
|
var t testing.T
|
|
|
|
// make sure error mentions that
|
|
// name is unexported, not just "name not found".
|
|
|
|
t.name = nil // ERROR "unexported"
|
|
|
|
println(testing.anyLowercaseName("asdf")) // ERROR "unexported" "undefined: testing.anyLowercaseName"
|
|
}
|