Fix TestWriteToTextfile

Signed-off-by: beorn7 <beorn@soundcloud.com>
This commit is contained in:
beorn7 2018-11-03 22:05:26 +01:00
parent abf2762ffe
commit b1974735e1
1 changed files with 9 additions and 1 deletions

View File

@ -913,6 +913,11 @@ test_summary_count{name="foo"} 2
prometheus.SummaryOpts{
Name: "test_summary",
Help: "test summary",
Objectives: map[float64]float64{
0.5: 0.05,
0.9: 0.01,
0.99: 0.001,
},
},
[]string{"name"},
)
@ -970,6 +975,9 @@ test_summary_count{name="foo"} 2
fileContents := string(fileBytes)
if fileContents != expectedOut {
t.Error("file contents didn't match unexpected")
t.Errorf(
"files don't match, got:\n%s\nwant:\n%s",
fileContents, expectedOut,
)
}
}