File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -101,7 +101,7 @@ def runTest(self):
101101 initialResetCount = self .get_fast_reset_count (c )
102102 print ""
103103 print "INITIAL reset count: %d" % initialResetCount
104- for i in range (1 , self .number_reboots_to_do ()):
104+ for i in range (0 , self .number_reboots_to_do ()):
105105 loopResetCount = self .get_fast_reset_count (c )
106106 # We do some funny things with the raw console here, as
107107 # 'reboot' isn't meant to return, so we want the raw
@@ -128,8 +128,12 @@ def runTest(self):
128128 print "Completed Fast reboot cycle %d" % i
129129
130130 c .run_command (BMC_CONST .NVRAM_DISABLE_FAST_RESET_MODE )
131- res = c .run_command (BMC_CONST .NVRAM_PRINT_FAST_RESET_VALUE )
132- self .assertNotIn ("feeling-lucky" , res , "Failed to set the fast-reset mode" )
131+ try :
132+ res = c .run_command (BMC_CONST .NVRAM_PRINT_FAST_RESET_VALUE )
133+ except CommandFailed as cf :
134+ self .assertEqual (cf .exitcode , 255 , "getting unset fast-reboot is meant to fail!" )
135+ else :
136+ self .assertTrue (False , "We expected to fail at getting cleared fast-reset nvram variable" )
133137
134138class FastRebootHost (OpTestFastReboot ):
135139 def boot_to_os (self ):
You can’t perform that action at this time.
0 commit comments