prometheusmetricshost-metricsmachine-metricsnode-metricsprocfsprometheus-exportersystem-informationsystem-metrics
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
24 lines
494 B
24 lines
494 B
10 years ago
|
package collector
|
||
|
|
||
|
import (
|
||
|
"testing"
|
||
|
)
|
||
|
|
||
|
func TestBonding(t *testing.T) {
|
||
|
bondingStats, err := readBondingStats("fixtures/bonding")
|
||
|
if err != nil {
|
||
|
t.Fatal(err)
|
||
|
}
|
||
|
if bondingStats["bond0"][0] != 0 || bondingStats["bond0"][1] != 0 {
|
||
|
t.Fatal("bond0 in unexpected state")
|
||
|
}
|
||
|
|
||
|
if bondingStats["int"][0] != 2 || bondingStats["int"][1] != 1 {
|
||
|
t.Fatal("int in unexpected state")
|
||
|
}
|
||
10 years ago
|
|
||
10 years ago
|
if bondingStats["dmz"][0] != 2 || bondingStats["dmz"][1] != 2 {
|
||
|
t.Fatal("dmz in unexpected state")
|
||
|
}
|
||
|
}
|