Fail CPU test if temps reach THERMAL_FAIL
* The test is allowed to finish as long as temps < THERMAL_LIMIT * Addresses issue #111
This commit is contained in:
parent
d1b37eddc1
commit
c3500ee324
2 changed files with 13 additions and 2 deletions
|
|
@ -1598,9 +1598,7 @@ def run_mprime_test(state, test):
|
||||||
if isinstance(err, KeyboardInterrupt):
|
if isinstance(err, KeyboardInterrupt):
|
||||||
test.update_status('Aborted')
|
test.update_status('Aborted')
|
||||||
elif isinstance(err, ThermalLimitReachedError):
|
elif isinstance(err, ThermalLimitReachedError):
|
||||||
test.failed = True
|
|
||||||
test.thermal_abort = True
|
test.thermal_abort = True
|
||||||
test.update_status('FAIL')
|
|
||||||
update_progress_pane(state)
|
update_progress_pane(state)
|
||||||
|
|
||||||
# Restart live monitor
|
# Restart live monitor
|
||||||
|
|
@ -1614,6 +1612,13 @@ def run_mprime_test(state, test):
|
||||||
tmux_kill_pane(state.panes.pop('Prime95', None))
|
tmux_kill_pane(state.panes.pop('Prime95', None))
|
||||||
countdown_proc.kill()
|
countdown_proc.kill()
|
||||||
|
|
||||||
|
# Check max temp
|
||||||
|
cpu_max_temp = get_cpu_max_temp(test.sensor_data)
|
||||||
|
if cpu_max_temp >= THERMAL_FAIL:
|
||||||
|
test.failed = True
|
||||||
|
test.update_status('FAIL')
|
||||||
|
update_progress_pane(state)
|
||||||
|
|
||||||
# Get cooldown temp
|
# Get cooldown temp
|
||||||
run_program(['apple-fans', 'auto'], check=False)
|
run_program(['apple-fans', 'auto'], check=False)
|
||||||
clear_screen()
|
clear_screen()
|
||||||
|
|
@ -1711,6 +1716,11 @@ def run_mprime_test(state, test):
|
||||||
' {RED}CPU reached temperature limit of {temp}°C{CLEAR}'.format(
|
' {RED}CPU reached temperature limit of {temp}°C{CLEAR}'.format(
|
||||||
temp=THERMAL_LIMIT,
|
temp=THERMAL_LIMIT,
|
||||||
**COLORS))
|
**COLORS))
|
||||||
|
elif cpu_max_temp >= THERMAL_FAIL:
|
||||||
|
test.report.append(
|
||||||
|
' {RED}CPU reached failing temperature of {temp}°C{CLEAR}'.format(
|
||||||
|
temp=THERMAL_FAIL,
|
||||||
|
**COLORS))
|
||||||
|
|
||||||
# Done
|
# Done
|
||||||
update_progress_pane(state)
|
update_progress_pane(state)
|
||||||
|
|
|
||||||
|
|
@ -104,6 +104,7 @@ KEY_SMART = 'ata_smart_attributes'
|
||||||
|
|
||||||
# Tests: Prime95
|
# Tests: Prime95
|
||||||
MPRIME_LIMIT = 7 # of minutes to run Prime95
|
MPRIME_LIMIT = 7 # of minutes to run Prime95
|
||||||
|
THERMAL_FAIL = 90 # Fail temperature in Celsius
|
||||||
THERMAL_LIMIT = 99 # Abort temperature in Celsius
|
THERMAL_LIMIT = 99 # Abort temperature in Celsius
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue