fix
This commit is contained in:
22
pkg/test/logger.go
Normal file
22
pkg/test/logger.go
Normal file
@@ -0,0 +1,22 @@
|
||||
package test
|
||||
|
||||
type Logger interface {
|
||||
Output(maxdepth int, s string) error
|
||||
}
|
||||
|
||||
type tbLog interface {
|
||||
Log(...interface{})
|
||||
}
|
||||
|
||||
type testLogger struct {
|
||||
tbLog
|
||||
}
|
||||
|
||||
func (tl *testLogger) Output(maxdepth int, s string) error {
|
||||
tl.Log(s)
|
||||
return nil
|
||||
}
|
||||
|
||||
func NewTestLogger(tbl tbLog) Logger {
|
||||
return &testLogger{tbl}
|
||||
}
|
||||
Reference in New Issue
Block a user