Cleanup tests.

This commit is contained in:
Orne Brocaar 2015-07-09 20:46:42 +02:00
parent d799011039
commit 986b89f5ed
1 changed files with 15 additions and 34 deletions

View File

@ -51,41 +51,22 @@ func TestElasticsearch(t *testing.T) {
"node_host": "test", "node_host": "test",
} }
for key, val := range indicesExpected { testTables := []map[string]float64{
assert.NoError(t, acc.ValidateTaggedValue(key, val, tags)) indicesExpected,
osExpected,
processExpected,
jvmExpected,
threadPoolExpected,
networkExpected,
fsExpected,
transportExpected,
httpExpected,
breakersExpected,
} }
for key, val := range osExpected { for _, testTable := range testTables {
assert.NoError(t, acc.ValidateTaggedValue(key, val, tags)) for k, v := range testTable {
} assert.NoError(t, acc.ValidateTaggedValue(k, v, tags))
}
for key, val := range processExpected {
assert.NoError(t, acc.ValidateTaggedValue(key, val, tags))
}
for key, val := range jvmExpected {
assert.NoError(t, acc.ValidateTaggedValue(key, val, tags))
}
for key, val := range threadPoolExpected {
assert.NoError(t, acc.ValidateTaggedValue(key, val, tags))
}
for key, val := range networkExpected {
assert.NoError(t, acc.ValidateTaggedValue(key, val, tags))
}
for key, val := range fsExpected {
assert.NoError(t, acc.ValidateTaggedValue(key, val, tags))
}
for key, val := range transportExpected {
assert.NoError(t, acc.ValidateTaggedValue(key, val, tags))
}
for key, val := range httpExpected {
assert.NoError(t, acc.ValidateTaggedValue(key, val, tags))
}
for key, val := range breakersExpected {
assert.NoError(t, acc.ValidateTaggedValue(key, val, tags))
} }
} }