1
0
mirror of https://github.com/labstack/echo.git synced 2025-03-17 21:08:05 +02:00

reusing variables to retry travis due to failure of coveralls from a travis bug

This commit is contained in:
Chase Hutchins 2016-01-29 04:34:40 -08:00
parent be8a2212d8
commit 857fb3761d

View File

@ -44,16 +44,21 @@ func TestEcho(t *testing.T) {
func TestLogger(t *testing.T) {
prefix := "extremely-long-prefix-string-that-wont-exist"
logmsg := "test-log-message"
e := New()
var b bytes.Buffer
out := bufio.NewWriter(&b)
writer := bufio.NewWriter(&b)
e.logger.SetPrefix(prefix)
e.logger.SetOutput(out)
e.logger.Print("test")
e.logger.SetOutput(writer)
e.logger.Print(logmsg)
assert.Contains(t, "extremely-long-prefix-string", b.String())
output := b.String()
assert.Contains(t, prefix, output)
assert.Contains(t, logmsg, output)
}
func TestEchoIndex(t *testing.T) {