示例#1
0
func main() {
	config.Flags.VisitAll(func(f *flag.Flag) {
		flag.Var(f.Value, f.Name, f.Usage)
	})
	flag.Parse()

	r := runner.New(log.New(os.Stderr, "", 0))
	r.Add("TestBasic", placehold.TestBasic, 1)

	r.Test(nil)
}
示例#2
0
func main() {
	config.Flags.VisitAll(func(f *flag.Flag) {
		flag.Var(f.Value, f.Name, f.Usage)
	})
	flag.Parse()

	r := runner.New(log.New(os.Stderr, "", 0))
	r.Add("TestBasic", placehold.TestBasic, 1)

	l, err := runner.NewStepLoader(5, 10, 1, 1*time.Second)
	if err != nil {
		panic(err)
	}

	r.Load(nil, l, runner.FailStep)
}