func main() { flag.Parse() b := komoku.Benchmarks() if len(os.Args) == 1 { // No arguments supplied, so simply print the available benchmarks. bn := "" for _, n := range b { bn += n.Name + " " } fmt.Println("benchmarks:") fmt.Println(bn) return } matchAlways := func(pat, str string) (bool, os.Error) { return regexp.MatchString(pat, str) } testing.RunBenchmarks(matchAlways, b) }
func main() { testing.Main(__regexp__.MatchString, tests) testing.RunBenchmarks(__regexp__.MatchString, benchmarks) }
func main() { testing.Main(tests) testing.RunBenchmarks(benchmarks) }