// May panic - this is recovered by fmt package, but care should be taken to
// capture panics when calling String() directly
349427
func (subSchema JsonSubSchema) String() string {
	v, err := json.Marshal(subSchema)
	if err != nil {
		panic(err)
	}
	b, err := yaml.JSONToYAML(v)
	if err != nil {
		panic(err)
	}
	return string(b)
}
477943
func MustDecode(input string) []byte {
	dec, err := Decode(input)
	if err != nil {
		panic(err)
	}
	return dec
}
344319
func Panicsf(t TestingT, f PanicTestFunc, msg string, args ...interface{}) bool {
	if h, ok := t.(tHelper); ok {
		h.Helper()
	}
	return Panics(t, f, append([]interface{}{msg}, args...)...)
}
622255
func (method HarvestMode) String() string {
	if description, ok := harvestingMethodToFlag[method]; ok {
		return description
	}
	panic("Unknown harvesting method.")
}
1276906
func (g *Geometry) String() string {
	str, err := g.ToWKT()
	if err != nil {
		return "" // XXX: better to panic?
	}
	return str
}
626932
func MustStringSlice(input interface{}) []string {
	output, err := StringSlice(input)
	if err != nil {
		panic(err)
	}
	return output
}
795135
func (j *Json) MustString(args ...string) string {
	var def string

	switch len(args) {
	case 0:
	case 1:
		def = args[0]
	default:
		log.Panicf("MustString() received too many arguments %d", len(args))
	}

	s, err := j.String()
	if err == nil {
		return s
	}

	return def
}
733501
func (a *Assertion) ErrorString(expr interface{}, str string, msg ...interface{}) *Assertion {
	ErrorString(a.t, expr, str, msg...)
	return a
}
1038432
func Panicf(format string, v ...interface{}) {
	s := fmt.Sprintf(format, v...)
	_ = std.Output(FATAL, 4, s)
	panic(s)
}
549815
func (exp *FuncExpr) String() string {
	return fmt.Sprintf("FuncExpr(%s, %s)", exp.Name, exp.Args)
}
754886
func (g *Group) GoString() string {
	buf := bytes.Buffer{}
	if err := g.Render(&buf); err != nil {
		panic(err)
	}
	return buf.String()
}
1144725
func Panic(v ...interface{}) {
	s := fmt.Sprint(v...)
	Logger.Output(2, s)
	panic(s)
}
219333
func (v *KeyValue_GetValue_Args) String() string {
	if v == nil {
		return "<nil>"
	}

	var fields [1]string
	i := 0
	if v.Key != nil {
		fields[i] = fmt.Sprintf("Key: %v", *(v.Key))
		i++
	}

	return fmt.Sprintf("KeyValue_GetValue_Args{%v}", strings.Join(fields[:i], ", "))
}
1032687
func DataToString(i interface{}) string {
	switch v := i.(type) {
	case string:
		return v
	case fmt.Stringer:
		return v.String()
	case uint8, int8, uint16, int16, uint32, int32, uint64, int64, int, uint:
		return fmt.Sprintf("%d", v)
	case []byte:
		return string(v)
	default:
		panic("unknown type")
	}
}
316103
func String(i interface{}) string {
	msg := ""
	switch val := i.(type) {
	case fmt.Stringer:
		msg = val.String()
	case error:
		msg = val.Error()
	case string:
		msg = val
	default:
		panic("invalid type, must be Stringer or error")
	}
	return msg
}
719078
func Panic(t testing.TB, fn func(), args ...interface{}) {
	has, _ := HasPanic(fn)
	assert(t, has, args, []interface{}{"并未发生 panic"})
}
1325428
func Panic(err error, msgs ...string) {
	if err != nil {
		if len(msgs) > 0 {
			panic(strings.Join(msgs, ",") + err.Error())
		} else {
			panic(err)
		}
	}
}