From f6fdc047cf60c78561a73a6310e3f380457439ec Mon Sep 17 00:00:00 2001 From: 2Shirt <2xShirt@gmail.com> Date: Thu, 25 Apr 2019 19:28:34 -0700 Subject: [PATCH] Post quick SMART results if run from menu * --quick argument still disables osTicket integration * Fixes issue #81 --- .bin/Scripts/functions/hw_diags.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.bin/Scripts/functions/hw_diags.py b/.bin/Scripts/functions/hw_diags.py index ce14b120..ea2775fa 100644 --- a/.bin/Scripts/functions/hw_diags.py +++ b/.bin/Scripts/functions/hw_diags.py @@ -474,6 +474,7 @@ class DiskObj(): class State(): """Object to track device objects and overall state.""" def __init__(self): + self.args = None self.cpu = None self.disks = [] self.ost = osTicket(TESTS_CPU, TESTS_DISK) @@ -760,6 +761,7 @@ def get_read_rate(s): def menu_diags(state, args): """Main menu to select and run HW tests.""" args = [a.lower() for a in args] + state.args = args checkmark = '*' if 'DISPLAY' in global_vars['Env']: checkmark = '✓' @@ -987,8 +989,8 @@ def run_hw_tests(state): state.init() tests_enabled = False - # Disable osTicket Integration if in quick mode - state.ost.disabled |= state.quick_mode + # Disable osTicket Integration if necessary + state.ost.disabled |= '--quick' in state.args # Build Panes update_progress_pane(state)