Bogus sleep in platform_ServoPowerStateController
Reported by
jrbarnette@chromium.org,
Jun 15 2016
|
||||
Issue description
In platform_ServoPowerStateController, the test for
"start in recovery mode, then turn off" includes an
unnecessary and unexplained call to sleep:
logging.info('Power DUT off in recovery mode without booting.')
self.host.servo.switch_usbkey('off')
self.controller.power_on(self.controller.REC_ON)
time.sleep(10)
self.controller.power_off()
self.assert_dut_off('power_state:off failed at recovery screen ')
The call was allowing some Braswell-based boards to pass when
they really shouldn't have, at least occasionally.
There's no reason for the sleep() call; 'power_state:rec power_state:off'
is expected to work without requiring an intermediate delay.
Additionally, the test lines above are only run in the case where
a USB stick is present, but that test case can reasonably run when
the stick is absent.
The code should be updated to move the code to the "test_with_usb_unplugged()"
section of the code, and should test these two assertions:
* power_state:rec followed by power_state:off without a delay leaves the
DUT off.
* After power_state:rec the DUT stays offline for the test's standard
interval (30 seconds), and the DUT stays off after applying
power_state:off.
,
Jul 1 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromiumos/third_party/autotest/+/1d4fbea1868629e10db266f4110499f194c0f70d commit 1d4fbea1868629e10db266f4110499f194c0f70d Author: Richard Barnette <jrbarnette@chromium.org> Date: Wed Jun 15 17:57:19 2016 [autotest] Further restrict test cases in servo power_state test. The platform_ServoPowerStateController test included a sleep(10) call that was allowing some boards to pass that shouldn't have, and generally causing confusion and trouble. This removes the offending call. BUG= chromium:620378 TEST=run using test_that on selected boards. Change-Id: Id263016f3180821b8198e443a0ae8d57e8c85bf2 Reviewed-on: https://chromium-review.googlesource.com/353031 Commit-Ready: Richard Barnette <jrbarnette@chromium.org> Tested-by: Richard Barnette <jrbarnette@chromium.org> Reviewed-by: Kevin Cheng <kevcheng@chromium.org> [modify] https://crrev.com/1d4fbea1868629e10db266f4110499f194c0f70d/server/site_tests/platform_ServoPowerStateController/platform_ServoPowerStateController.py
,
Jul 18 2016
,
Aug 29 2016
,
Aug 29 2016
bulk verified |
||||
►
Sign in to add a comment |
||||
Comment 1 by jrbarnette@chromium.org
, Jun 15 2016