Apache plugin unit tests and README

This commit is contained in:
Cameron Sparr
2015-11-13 12:51:37 -07:00
parent 0f036d6bec
commit b975419bc7
7 changed files with 165 additions and 34 deletions

View File

@@ -393,7 +393,7 @@ func assertContainsTaggedFloat(
for _, pt := range acc.Points {
if pt.Measurement == measurement {
if (tags == nil) || reflect.DeepEqual(pt.Tags, tags) {
if value, ok := pt.Values["value"].(float64); ok {
if value, ok := pt.Fields["value"].(float64); ok {
actualValue = value
if (value >= expectedValue-delta) && (value <= expectedValue+delta) {
// Found the point, return without failing