import time
from lxml import etree
from appium import webdriver
from selenium.webdriver.common.by import By
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support import expected_conditions as EC
PLATFROM = "Android"
DEVIE_NAME = "0815F8612D924005"
APP_PACKAGE = "com.tencent.mm"
APP_ACTIVITY = ".ui.LauncherUI"
DEIVER_SERVER = "http://localhost:4723/wd/hub"
TIMROUT = 15 # 单位秒
FLICK_START_X = 300
FLICK_START_Y = 300
FLICK_DISTANCE = 700
class WX(object):
def __init__(self):
"""
初始化操作
"""
# 驱动配置操作 self.desired_caps = {
"platformName": PLATFROM,
"deviceName": DEVIE_NAME,
"appPackage": A