Check fields in testutil AssertDoesNotContainsTaggedFields (#5365)
This commit is contained in:
parent
a98483cc11
commit
15c65b08e5
|
@ -340,9 +340,10 @@ func (a *Accumulator) AssertDoesNotContainsTaggedFields(
|
|||
continue
|
||||
}
|
||||
|
||||
if p.Measurement == measurement {
|
||||
assert.Equal(t, fields, p.Fields)
|
||||
msg := fmt.Sprintf("found measurement %s with tags %v which should not be there", measurement, tags)
|
||||
if p.Measurement == measurement && reflect.DeepEqual(fields, p.Fields) {
|
||||
msg := fmt.Sprintf(
|
||||
"found measurement %s with tagged fields (tags %v) which should not be there",
|
||||
measurement, tags)
|
||||
assert.Fail(t, msg)
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue