vendor: consul v1.7.7

Signed-off-by: Yoan Blanc <yoan@dosimple.ch>
This commit is contained in:
Yoan Blanc
2020-08-23 09:41:27 +02:00
parent 0d6b02b099
commit 5f7a8a0b7a
147 changed files with 5314 additions and 13446 deletions

View File

@@ -22,6 +22,7 @@ type T interface {
Log(args ...interface{})
Logf(format string, args ...interface{})
Name() string
Parallel()
Skip(args ...interface{})
SkipNow()
Skipf(format string, args ...interface{})
@@ -31,10 +32,12 @@ type T interface {
// RuntimeT implements T and can be instantiated and run at runtime to
// mimic *testing.T behavior. Unlike *testing.T, this will simply panic
// for calls to Fatal. For calls to Error, you'll have to check the errors
// list to determine whether to exit yourself. Name and Skip methods are
// unimplemented noops.
// list to determine whether to exit yourself.
//
// Parallel does not do anything.
type RuntimeT struct {
failed bool
failed bool
skipped bool
}
func (t *RuntimeT) Error(args ...interface{}) {
@@ -77,8 +80,26 @@ func (t *RuntimeT) Logf(format string, args ...interface{}) {
log.Println(fmt.Sprintf(format, args...))
}
func (t *RuntimeT) Name() string { return "" }
func (t *RuntimeT) Skip(args ...interface{}) {}
func (t *RuntimeT) SkipNow() {}
func (t *RuntimeT) Skipf(format string, args ...interface{}) {}
func (t *RuntimeT) Skipped() bool { return false }
func (t *RuntimeT) Name() string {
return ""
}
func (t *RuntimeT) Parallel() {}
func (t *RuntimeT) Skip(args ...interface{}) {
log.Print(args...)
t.SkipNow()
}
func (t *RuntimeT) SkipNow() {
t.skipped = true
}
func (t *RuntimeT) Skipf(format string, args ...interface{}) {
log.Printf(format, args...)
t.SkipNow()
}
func (t *RuntimeT) Skipped() bool {
return t.skipped
}