Module: check_mk
Branch: master
Commit: 7435d681af04876d5eb0a5d2c3df0ba35a6a4abf
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=7435d681af0487…
Author: Florian Kromer <fk(a)mathias-kettner.de>
Date: Fri Jan 11 17:04:31 2019 +0100
lnx_thermal: Add generic data regression test
CMK-1506
Change-Id: I224739a5cf3519e26124538a843150d4072ce5a0
---
.../checks/generictests/datasets/lnx_thermal.py | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)
diff --git a/tests/unit/checks/generictests/datasets/lnx_thermal.py
b/tests/unit/checks/generictests/datasets/lnx_thermal.py
new file mode 100644
index 0000000..a8838ce
--- /dev/null
+++ b/tests/unit/checks/generictests/datasets/lnx_thermal.py
@@ -0,0 +1,22 @@
+checkname = 'lnx_thermal'
+
+info = [['thermal_zone0', 'enabled', 'acpitz', '57000',
'127000', 'critical'],
+ ['thermal_zone1', 'enabled', 'acpitz', '65000',
'100000', 'critical', '95500', 'passive'],
+ ['thermal_zone2', 'pkg-temp-0', '44000', '0',
'passive', '0', 'passive']]
+
+discovery = {'': [('Zone 0', {}), ('Zone 1', {}), ('Zone
2', {})]}
+
+checks = {
+ '': [('Zone 0', {
+ 'device_levels_handling': 'devdefault',
+ 'levels': (70.0, 80.0)
+ }, [(0, u'57.0 \xb0C', [('temp', 57.0, 127.0, 127.0, None,
None)])]),
+ ('Zone 1', {
+ 'device_levels_handling': 'devdefault',
+ 'levels': (70.0, 80.0)
+ }, [(0, u'65.0 \xb0C', [('temp', 65.0, 95.5, 100.0, None,
None)])]),
+ ('Zone 2', {
+ 'device_levels_handling': 'devdefault',
+ 'levels': (70.0, 80.0)
+ }, [(0, u'44.0 \xb0C', [('temp', 44.0, 70.0, 80.0, None,
None)])])]
+}