aboutsummaryrefslogtreecommitdiff
path: root/collector/diskstats_linux_test.go
diff options
context:
space:
mode:
authorHolger Hoffstätte <holger@applied-asynchrony.com>2019-11-25 20:16:15 +0100
committerBen Kochie <superq@gmail.com>2019-11-25 13:16:15 -0600
commit3c2c4e7b3c473777b13e79cc84cc04e519fd3a9a (patch)
tree1174fc56c8e856787b71e23636b06fdb8b56a6a4 /collector/diskstats_linux_test.go
parent67d3010a7974b5b255d8a61211a3dcce36ed6410 (diff)
downloadprometheus_node_collector-3c2c4e7b3c473777b13e79cc84cc04e519fd3a9a.tar.bz2
prometheus_node_collector-3c2c4e7b3c473777b13e79cc84cc04e519fd3a9a.tar.xz
prometheus_node_collector-3c2c4e7b3c473777b13e79cc84cc04e519fd3a9a.zip
Add new counters for flush requests in Linux 5.5 (#1548)
* Add diskstat flush request counters for Linux 5.5+ * Update tests for diskstat flush request counters with Linux 5.5+ Signed-off-by: Holger Hoffstätte <holger@applied-asynchrony.com>
Diffstat (limited to 'collector/diskstats_linux_test.go')
-rw-r--r--collector/diskstats_linux_test.go8
1 files changed, 8 insertions, 0 deletions
diff --git a/collector/diskstats_linux_test.go b/collector/diskstats_linux_test.go
index 84a7de4..9bfecc5 100644
--- a/collector/diskstats_linux_test.go
+++ b/collector/diskstats_linux_test.go
@@ -41,4 +41,12 @@ func TestDiskStats(t *testing.T) {
41 if want, got := "11130", diskStats["sdb"][14]; want != got { 41 if want, got := "11130", diskStats["sdb"][14]; want != got {
42 t.Errorf("want diskstats sdb %s, got %s", want, got) 42 t.Errorf("want diskstats sdb %s, got %s", want, got)
43 } 43 }
44
45 if want, got := "1555", diskStats["sdc"][15]; want != got {
46 t.Errorf("want diskstats sdc %s, got %s", want, got)
47 }
48
49 if want, got := "1944", diskStats["sdc"][16]; want != got {
50 t.Errorf("want diskstats sdc %s, got %s", want, got)
51 }
44} 52}