summaryrefslogtreecommitdiffstats
path: root/scripts/automation/trex_control_plane/common/text_opts.py
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/automation/trex_control_plane/common/text_opts.py')
-rwxr-xr-xscripts/automation/trex_control_plane/common/text_opts.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/automation/trex_control_plane/common/text_opts.py b/scripts/automation/trex_control_plane/common/text_opts.py
index 6c83bc6e..29fbd69b 100755
--- a/scripts/automation/trex_control_plane/common/text_opts.py
+++ b/scripts/automation/trex_control_plane/common/text_opts.py
@@ -125,10 +125,10 @@ def format_text(text, *args):
return return_string
def format_threshold (value, red_zone, green_zone):
- if value > red_zone[0] and value < red_zone[1]:
+ if value >= red_zone[0] and value <= red_zone[1]:
return format_text("{0}".format(value), 'red')
- if value > green_zone[0] and value < green_zone[1]:
+ if value >= green_zone[0] and value <= green_zone[1]:
return format_text("{0}".format(value), 'green')
return "{0}".format(value)