def setUp(self): super(ComposeUI, self).setUp() self._test_name = __name__ print "[Setup]: %s" % self._test_name self._composeui = ComposeUiImpl() self.photos = get_photo_implement() self.qrcodeImpl = QRcode() self.photosImpl = get_photo_implement() self.photosImpl.rm_delete_photos() self.photosImpl.refresh_sdcard() # self.photos.clean() self.qrcode = "GIFPICTURE" config = TestConfig() cfg_file = 'tests.tablet.artifactory.conf' cfg_arti = config.read(cfg_file, 'artifactory') config_handle = ConfigHandle() cfg_arti["location"] = config_handle.read_configuration('artifactory', 'location', '/etc/oat/', 'sys.conf') cfg = config.read(cfg_file, 'qrcode_marked_image') self.qrcode = cfg.get("screenshot_imageview_qrcode") print "[Debug] qrcode:%s" % (self.qrcode) arti = Artifactory(cfg_arti.get('location')) pic_name = cfg.get("screenshot_imageview_image") file_path = arti.get(pic_name) g_common_obj.adb_cmd_common('push ' + file_path + ' /sdcard/Pictures') self.pic_path = '/sdcard/Pictures/' + os.path.basename(file_path) self.photosImpl.refresh_sdcard() special_actions.setup()
def test_Multiple_Display_UI_and_Rear_Seat_Entertainment_RSE_dispaly(self): try: multi_display.is_multi_displayed() get_photo_implement() dbsetting.set_force_resizable_activities(enabled=True) multi_display.run_activities_multidisplay( multi_display.EXTERNAL_DISPLAY_ID, "com.google.android.apps.photos", ".home.HomeActivity") multi_display.is_show_different_picture() dbsetting.set_force_resizable_activities(enabled=False) except: raise Exception("Activity not started on external display.") finally: g_common_obj.adb_cmd_capture_msg( "am force-stop com.google.android.apps.photos")
def setUp(self): print "[Setup]:%s" % self.__class__.__name__ super(HDMITest, self).setUp() self.photosImpl = get_photo_implement() self.qrcode = "bmppicture" config = TestConfig() cfg_file = 'tests.tablet.artifactory.conf' cfg_arti = config.read(cfg_file, 'artifactory') config_handle = ConfigHandle() cfg_arti["location"] = config_handle.read_configuration( 'artifactory', 'location', '/etc/oat/', 'sys.conf') self.retry_num = self.config.read( cfg_file, 'rerun_times').get("hdmi_imagedisplay_bmp") self.retry_num = int(self.retry_num) cfg = config.read(cfg_file, 'qrcode_marked_image') print self.qrcode self.qrcode = cfg.get("hdmi_bmp_qrcode") print "[Debug] qrcode:%s" % (self.qrcode) arti = Artifactory(cfg_arti.get('location')) pic_name = cfg.get("hdmi_bmp_image") file_path = arti.get(pic_name) g_common_obj.adb_cmd_common('push ' + file_path + ' /sdcard/Pictures') self.photosImpl.refresh_sdcard() self.systemui = SystemUiExtendImpl() self.HDMI_switch_card = HDMISwitchCardImpl() self.HDMI_capture_decode = HDMICaptureDecodeImpl() self.HDMI_switch_card.setup() self.HDMI_switch_card.switch_off() self.HDMI_capture_decode.setup() self.systemui.unlock_screen() self.d.screen.on() self.d.orientation = 'natural'
def setUpClass(self): """ install apk """ super(DeleteImageFolder, self).setUpClass() self.photos = get_photo_implement() self.photos.rm_delete_photos()
def setUp(self): print "[Setup]:%s" % self.__class__.__name__ super(ImageViewing, self).setUp() self.device = g_common_obj.get_device() self.photos = get_photo_implement() self.qrcodeImpl = QRcode() self.wallpaper = WallpaperImpl() self.photos.rm_delete_photos() self.photos.refresh_sdcard() self.qrcode = "GIFPICTURE" config = TestConfig() cfg_file = 'tests.tablet.artifactory.conf' cfg_arti = config.read(cfg_file, 'artifactory') config_handle = ConfigHandle() cfg_arti["location"] = config_handle.read_configuration( 'artifactory', 'location', '/etc/oat/', 'sys.conf') cfg = config.read(cfg_file, 'qrcode_marked_image') self.qrcode = cfg.get("screenshot_imageview_qrcode") print "[Debug] qrcode:%s" % (self.qrcode) arti = Artifactory(cfg_arti.get('location')) pic_name = cfg.get("screenshot_imageview_image") file_path = arti.get(pic_name) g_common_obj.adb_cmd_common('push ' + file_path + ' /sdcard/Pictures') self.photos.refresh_sdcard()
def setUpClass(self): print "[setUpClass]: %s" % self.__name__ super(HDMITest, self).setUpClass() self.photosImpl = get_photo_implement() self.d = g_common_obj.get_device() g_common_obj.root_on_device() g_common_obj.remount_device()
def setUpClass(self): """ set environment """ super(ImageEdit, self).setUpClass() self.photos = get_photo_implement() self.photos.rm_delete_photos()
def setUpClass(self): """ set environment """ super(ImageViewByWebBrowser, self).setUpClass() self.photos = get_photo_implement() self._qrcode = QRcode() self._chrome = ChromeExtendImpl() self.photos.rm_delete_photos() config = TestConfig() cfg_file = 'tests.tablet.artifactory.conf' cfg_arti = config.read(cfg_file, 'artifactory') config_handle = ConfigHandle() cfg_arti["location"] = config_handle.read_configuration( 'artifactory', 'location', '/etc/oat/', 'sys.conf') cfg = config.read(cfg_file, 'qrcode_marked_image') arti = Artifactory(cfg_arti.get('location')) pic_name = cfg.get("q_webp") self.pic_name = pic_name.split("/")[-1] self.qrcode = cfg.get("q_webp_qrcode") file_path = arti.get(pic_name) self.photos.deploy_photo_content(local_file=file_path) self._chrome.launch() self._chrome.chrome_setup()
def setUp(self): super(Render, self).setUp() self._test_name = __name__ print "[Setup]: %s" % self._test_name self._extendcamera = CameraExtendImpl() self._photos = get_photo_implement() self._photos.rm_delete_photos() self._photos.refresh_sdcard()
def setUp(self): super(DisplayHDMIout, self).setUp() self._test_name = __name__ print "[Setup]: %s" % self._test_name self.fs = FileSystem() self.photosImpl = get_photo_implement() self.photosImpl.rm_delete_photos() self.photosImpl.refresh_sdcard()
def setUp(self): super(ComposeUI, self).setUp() self._test_name = __name__ print "[Setup]: %s" % self._test_name self._composeui = ComposeUiImpl() self.photos = get_photo_implement() self.photos.rm_delete_photos() self.photos.refresh_sdcard()
def setUpClass(self): """ set environment """ super(ImageView, self).setUpClass() self.photos = get_photo_implement() self.photos.rm_delete_photos() self.photos.deploy_photo_content("content_picture", "wbmp")
def setUpClass(self): """ set up and push picture """ super(DeleteOneImage, self).setUpClass() self.photos = get_photo_implement() self.photos.rm_delete_photos() self.photos.deploy_photo_content('Pictures', 'email')
def setUpClass(self): """ set environment """ super(ImageEdit, self).setUpClass() self.photos = get_photo_implement() self._imageviewer = ImageDetails() self.photos.rm_delete_photos() self.photos.deploy_photo_content("content_picture", "bmp")
def setUpClass(self): """ install apk """ super(SetContactorPhoto, self).setUpClass() self.photos = get_photo_implement() self.photos.rm_delete_photos() self.photos.deploy_photo_content("qrcode_marked_image", "wallpaperset_jpg_image") g_common_obj.adb_cmd_capture_msg("pm disable com.android.gallery3d")
def setUp(self): super(ChromeCast, self).setUp() self._test_name = __name__ print "[Setup]: %s" % self._test_name self._chromecast = ChromeCastImpl() self._photos = get_photo_implement() self._chromecast.connect_chromecast() self._chromecast.init_local_video() self._photos.refresh_sdcard()
def setUpClass(self): """ install apk """ super(CheckImageDetails, self).setUpClass() self.photos = get_photo_implement() self.photos.rm_delete_photos() self.photos.deploy_photo_content('Pictures', 'picture_002') self.pic_path = file_sys.get_file_list("/sdcard/Pictures")[0]
def setUpClass(self): """ set environment """ super(ImageView, self).setUpClass() self.photos = get_photo_implement() self.photos.rm_delete_photos() name = ["gif3", "gif7", "gif8", "gif9", "gif10", "gif11"] for i in name: self.photos.deploy_photo_content("content_picture_gif", i)
def setUpClass(self): """ set environment """ super(ImageView, self).setUpClass() self.photos = get_photo_implement() self.photos.rm_delete_photos() push_pics = ['webp' + str(i) for i in range(1, 11)] for i in push_pics: self.photos.deploy_photo_content("content_picture_webp", i)
def setUp(self): super(HWComposer, self).setUp() self._test_name = __name__ print "[Setup]: %s" % self._test_name g_common_obj.root_on_device() self.d = g_common_obj.get_device() self._extendcamera = CameraExtendImpl() self.photoImpl = get_photo_implement() self.develop_settings = DevelopmentSettingsImpl() self.develop_settings.set_disable_hw_overlays(switch='ON')
def setUpClass(self): """ set environment """ super(ImageView, self).setUpClass() self._imageviewer = ImageDetails() self.device = g_common_obj.get_device() self.photos = get_photo_implement() self.photos.rm_delete_photos() self.photos.deploy_photo_content("content_picture", "wbmp5")
def setUp(self): print "[Setup]:%s" % self.__class__.__name__ super(VideoPlayback, self).setUp() self.photos = get_photo_implement() self.bench = Gfxbench() self._qr = QRcode() self.extend_photos = PhotosExtendImpl() self.remote_path = self.extend_photos.push_videos(count=1, like='test_video_qr', exts='.mp4')[0]
def setUp(self): super(ImageView, self).setUp() self._test_name = __name__ print "[Setup]: %s" % self._test_name g_common_obj.root_on_device() self.d = g_common_obj.get_device() self.photosImpl = get_photo_implement() self.qr = QRcode() self.photosImpl.rm_delete_photos() self.photosImpl.stop_photos_am()
def setUp(self): print "[Setup]:%s" % self.__class__.__name__ super(DPSTFunctionalityTest, self).setUp() self.photos = get_photo_implement() self.chrome = ChromeExtendImpl() self.extend_photos = PhotosExtendImpl() self.remote_path = self.extend_photos.push_videos(count=1, like='dark', exts='.mp4')[0] self.chrome.launch() self.chrome.chrome_setup()
def setUpClass(self): """ install apk """ super(PhotoGrid, self).setUpClass() self.photos = get_photo_implement() self.photos.rm_delete_photos() apk_path = get_resource_from_atifactory( 'tests.tablet.artifactory.conf', 'content_photogrid', 'name') pkgmgr.apk_install(apk_path) self.photos.deploy_photo_content('Pictures', 'email')
def setUpClass(self): """ set environment """ super(ImageView, self).setUpClass() self._imageviewer = ImageDetails() self.photos = get_photo_implement() self.photos.rm_delete_photos() push_pics = ['bmp' + str(i) for i in range(1, 7)] for i in push_pics: self.photos.deploy_photo_content("content_picture_bmp", i)
def setUp(self): super(VirtualDisplay, self).setUp() self._test_name = __name__ print "[Setup]: %s" % self._test_name self.apk = get_resource_from_atifactory(CONFIG_FILE, SECTION, 'name') self.d = g_common_obj.get_device() self.apiDemoImpl = SampleApiDemoImpl() self.photoImpl = get_photo_implement() self.photoImpl.stop_photos_am() self.photoImpl.rm_delete_photos() self.photoImpl.refresh_sdcard()
def setUp(self): super(Fit, self).setUp() self._test_name = __name__ print "[Setup]: %s" % self._test_name self.photos = get_photo_implement() self.d = g_common_obj.get_device() self.d.screen.on() self._qr = QRcode() self.extend_photos = PhotosExtendImpl() self.remote_path = self.extend_photos.push_videos(count=1, like='test_video_qr', exts='.mp4')[0] adb32.screen_rotation(0)
def setUp(self): super(ComposeUI, self).setUp() self._test_name = __name__ print "[Setup]: %s" % self._test_name self._composeui = ComposeUiImpl() self.photos = get_photo_implement() self.photos.rm_delete_photos() self.photos.refresh_sdcard() self._composeui.init_local_video() self.extend_photos = PhotosExtendImpl() self.remote_path = self.extend_photos.push_videos(like='test_video_qr', exts='.mp4')[0]
def setUpClass(self): """ set environment """ super(ImageViewThumbnailsMode, self).setUpClass() self.device = g_common_obj.get_device() self._imageviewer = ImageDetails() self.photos = get_photo_implement() self.photos.rm_delete_photos() push_pics = ['jpeg' + str(i) for i in range(1, 5)] for i in push_pics: self.photos.deploy_photo_content("content_picture_jpeg", i)