Merge in go-hclog

This commit is contained in:
Jeff Mitchell 2018-04-02 16:14:46 -04:00
parent 95d9e83bc3
commit 5590cb63c1
2 changed files with 48 additions and 3 deletions

45
vendor/github.com/hashicorp/go-hclog/nulllogger.go generated vendored Normal file
View File

@ -0,0 +1,45 @@
package hclog
import (
"log"
"io/ioutil"
)
// NewNullLogger instantiates a Logger for which all calls
// will succeed without doing anything.
// Useful for testing purposes.
func NewNullLogger() Logger {
return &nullLogger{}
}
type nullLogger struct{}
func (l *nullLogger) Trace(msg string, args ...interface{}) {}
func (l *nullLogger) Debug(msg string, args ...interface{}) {}
func (l *nullLogger) Info(msg string, args ...interface{}) {}
func (l *nullLogger) Warn(msg string, args ...interface{}) {}
func (l *nullLogger) Error(msg string, args ...interface{}) {}
func (l *nullLogger) IsTrace() bool { return false }
func (l *nullLogger) IsDebug() bool { return false }
func (l *nullLogger) IsInfo() bool { return false }
func (l *nullLogger) IsWarn() bool { return false }
func (l *nullLogger) IsError() bool { return false }
func (l *nullLogger) With(args ...interface{}) Logger { return l }
func (l *nullLogger) Named(name string) Logger { return l }
func (l *nullLogger) ResetNamed(name string) Logger { return l }
func (l *nullLogger) StandardLogger(opts *StandardLoggerOptions) *log.Logger {
return log.New(ioutil.Discard, "", log.LstdFlags)
}

6
vendor/vendor.json vendored
View File

@ -1087,10 +1087,10 @@
"revisionTime": "2018-02-23T19:15:17Z" "revisionTime": "2018-02-23T19:15:17Z"
}, },
{ {
"checksumSHA1": "OEBNuHhYGJwXWNyZ2i+sAiOLtDs=", "checksumSHA1": "qhjAx0nMYBeQqRTaf7sQYpfUIq0=",
"path": "github.com/hashicorp/go-hclog", "path": "github.com/hashicorp/go-hclog",
"revision": "ad26ae78d4726a0d9fd16afcdff629babc1fc661", "revision": "69ff559dc25f3b435631604f573a5fa1efdb6433",
"revisionTime": "2018-04-02T19:56:19Z" "revisionTime": "2018-04-02T20:04:05Z"
}, },
{ {
"checksumSHA1": "y+AeKVZoX0gB+DZW4Arzkb3tTVc=", "checksumSHA1": "y+AeKVZoX0gB+DZW4Arzkb3tTVc=",