grlogs/log_test.go
2020-04-28 14:32:56 +08:00

16 lines
323 B
Go

package grlogs
import (
_ "golib.gaore.com/GaoreGo/grlogs/logs/es"
"testing"
"time"
)
func TestGetLogger(t *testing.T) {
l := Get("nds", 128).SetAdapter(LevelAll, AdapterElasticSearch)
l.Debug("我正在调试")
l.Critical("出错了")
Get("nds").Warning("hadoee %s", time.Now().Format(time.RFC1123))
l.Flush()
}