-
Notifications
You must be signed in to change notification settings - Fork 740
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
new_template: cisco_ios_show_environment_temperature.template
- Loading branch information
1 parent
53f638d
commit 84519d3
Showing
4 changed files
with
75 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
Value SWITCH (\d+) | ||
Value SWITCH_TEMPERATURE (\w+) | ||
Value INLET_TEMPERATURE_VALUE (\d+) | ||
Value INLET_TEMPERATURE_STATE (\S+) | ||
Value INLET_YELLOW_THRESHOLD (\d+) | ||
Value INLET_RED_THRESHOLD (\d+) | ||
Value HOTSPOT_TEMPERATURE_VALUE (\d+) | ||
Value HOTSPOT_TEMPERATURE_STATE (\S+) | ||
Value HOTSPOT_YELLOW_THRESHOLD (\d+) | ||
Value HOTSPOT_RED_THRESHOLD (\d+) | ||
|
||
Start | ||
^Switch\s+\d -> Continue.Record | ||
^Switch\s+${SWITCH}:\s+SYSTEM\s+TEMPERATURE\s+is\s+${SWITCH_TEMPERATURE}\s*$$ -> Inlet | ||
^\s*$$ | ||
^. -> Error | ||
|
||
Inlet | ||
^Inlet\s+Temperature\s+Value:\s+${INLET_TEMPERATURE_VALUE}\s+Degree\s+Celsius\s*$$ | ||
^Temperature\s+State:\s+${INLET_TEMPERATURE_STATE}\s*$$ | ||
^Yellow\s+Threshold\s+:\s+${INLET_YELLOW_THRESHOLD}\s+Degree\s+Celsius\s*$$ | ||
^Red\s+Threshold\s+:\s+${INLET_RED_THRESHOLD}\s+Degree\s+Celsius\s*$$ -> Hotspot | ||
^\s*$$ | ||
^. -> Error | ||
|
||
Hotspot | ||
^Hotspot\s+Temperature\s+Value:\s+${HOTSPOT_TEMPERATURE_VALUE}\s+Degree\s+Celsius\s*$$ | ||
^Temperature\s+State:\s+${HOTSPOT_TEMPERATURE_STATE}\s*$$ | ||
^Yellow\s+Threshold\s+:\s+${HOTSPOT_YELLOW_THRESHOLD}\s+Degree\s+Celsius\s*$$ | ||
^Red\s+Threshold\s+:\s+${HOTSPOT_RED_THRESHOLD}\s+Degree\s+Celsius\s*$$ -> Start | ||
^\s*$$ | ||
^. -> Error |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
22 changes: 22 additions & 0 deletions
22
tests/cisco_ios/show_environment_temperature/cisco_ios_show_environment_temperature.parsed
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
--- | ||
parsed_sample: | ||
- hotspot_red_threshold: '125' | ||
hotspot_temperature_state: GREEN | ||
hotspot_temperature_value: '67' | ||
hotspot_yellow_threshold: '105' | ||
inlet_red_threshold: '56' | ||
inlet_temperature_state: GREEN | ||
inlet_temperature_value: '29' | ||
inlet_yellow_threshold: '46' | ||
switch: '1' | ||
switch_temperature: OK | ||
- hotspot_red_threshold: '125' | ||
hotspot_temperature_state: GREEN | ||
hotspot_temperature_value: '69' | ||
hotspot_yellow_threshold: '105' | ||
inlet_red_threshold: '56' | ||
inlet_temperature_state: GREEN | ||
inlet_temperature_value: '28' | ||
inlet_yellow_threshold: '46' | ||
switch: '2' | ||
switch_temperature: OK |
20 changes: 20 additions & 0 deletions
20
tests/cisco_ios/show_environment_temperature/cisco_ios_show_environment_temperature.raw
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
Switch 1: SYSTEM TEMPERATURE is OK | ||
Inlet Temperature Value: 29 Degree Celsius | ||
Temperature State: GREEN | ||
Yellow Threshold : 46 Degree Celsius | ||
Red Threshold : 56 Degree Celsius | ||
|
||
Hotspot Temperature Value: 67 Degree Celsius | ||
Temperature State: GREEN | ||
Yellow Threshold : 105 Degree Celsius | ||
Red Threshold : 125 Degree Celsius | ||
Switch 2: SYSTEM TEMPERATURE is OK | ||
Inlet Temperature Value: 28 Degree Celsius | ||
Temperature State: GREEN | ||
Yellow Threshold : 46 Degree Celsius | ||
Red Threshold : 56 Degree Celsius | ||
|
||
Hotspot Temperature Value: 69 Degree Celsius | ||
Temperature State: GREEN | ||
Yellow Threshold : 105 Degree Celsius | ||
Red Threshold : 125 Degree Celsius |