예제 #1
0
 def test_system_resume_press_power(self):
     print "[RunTest]: %s" % self.__str__()
     from testlib.em.power import get_power_obj
     self.s0ix.set_screen_status("off")
     time.sleep(10)
     get_power_obj().press_power_key(1)
     time.sleep(2)
     self.s0ix.verify_screen_status("on")
     self.s0ix.unlock_screen()
예제 #2
0
 def setUp(self):
     self._test_name = __name__
     print "[Setup]: %s" % self._test_name
     self.power = get_power_obj()
     self.power.adb_root()
     self.display = DisplaySetting()
     self.display.set_screen_status("on")
     self.display.unlock_screen()
     self.display.set_sleep_mode("30 minutes")
     self.power.testDevice.close_background_apps()
     super(PowerOnOff, self).setUp()
 def setUp(self):
     self._test_name = __name__
     print
     print "[Setup]: %s" % self._test_name
     self.thermal = Thermal()
     self.power = get_power_obj()
     #self.csv_path = gen_tmp_file_path_by_time("temps.csv")
     self.csv_name = ("Thermal_data_%s.csv" %
                      time.strftime("%y-%m-%d-%H-%M-%S"))
     self.csv_file = open(self.csv_name, "wb")
     self.csv_writer = csv.writer(self.csv_file)
     #self.reboot_temps = [0, 20, 30, 40, 55, 75]
     self.reboot_temps = [0, 10, 20, 30, 40, 50, 55, 70, 75, 80]
     self.thermal.adb_root()
     self.csv_writer.writerow(
         ["tcpu", "tskn", "tamb", "fan", "power", "reboot"])
예제 #4
0
 def test_ivi_thermal_adb_reboot(self):
     print "[RunTest]: %s" % self.__str__()
     from testlib.em.power import get_power_obj
     power = get_power_obj()
     self.thermal_file_host = gen_tmp_file_path_by_time("adb_reboot.txt")
     self.thermal_data_result = gen_tmp_file_path_by_time("adb_reboot.xls")
     write_to_file("cpu_temp board_temp cpu_freq power gpu_freq\n",
                   self.thermal_file_host, "w")
     data_list = self.ivi_capture_thermal_data()
     write_to_file(data_list, self.thermal_file_host, "a")
     times = 10
     for i in range(1, 1 + times):
         print "Cycle: %d/%d" % (i, times)
         power.adb_reboot()
         self.thermal.adb_root()
         data_list = self.ivi_capture_thermal_data()
         write_to_file(data_list, self.thermal_file_host, "a")
     self.thermal.ivi_gen_temp_result(self.thermal_data_result,
                                      self.thermal_file_host,
                                      self.score_list)
예제 #5
0
 def __init__(self):
     self.power = get_power_obj()
     self.charger_type = None
예제 #6
0
 def setUp(self):
     self._test_name = __name__
     print "[Setup]: %s" % self._test_name
     self.power = get_power_obj()
예제 #7
0
 def test_automotive_vehicle_in_s5(self):
     get_power_obj().reboot()
     self.s0i3.adb_root()
     s3 = self.s0i3.get_s0i3_suspend_stat()
     assert s3 == 0
예제 #8
0
 def test_automotive_power_on_display_on(self):
     get_power_obj().reboot()
     self.s0i3.adb_root()
     s3 = self.s0i3.get_s0i3_suspend_stat()
     assert s3 == 0
     assert self.s0i3.get_screen_status()
예제 #9
0
 def test_boot_up_from_s5_by_ignition(self):
     from testlib.em.power import get_power_obj
     get_power_obj().reboot()
     self.s0i3.adb_root()
     s3 = self.s0i3.get_s0i3_suspend_stat()
     assert s3 == 0
예제 #10
0
 def setUp(self):
     self._test_name = __name__
     print "[Setup]: %s" % self._test_name
     self.power = get_power_obj()
     self.power.adb_root()
     super(COS, self).setUp()