Beispiel #1
0
def dL_element(self):
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id(
            "com.erlinyou.worldlist:id/user_name_tv").click()
    except Exception as e:
        element_error(self.driver, e)
Beispiel #2
0
def wX_element(self):
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id(
            "com.erlinyou.worldlist:id/iv_other_login").click()
    except Exception as e:
        element_error(self=self, e=e)
Beispiel #3
0
def chat_send_file_element(self):
    """message send file element"""
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id("img_icon").click()
    except Exception as e:
        element_error(self, e)
Beispiel #4
0
def mobile_login_element(self):
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id(
            "com.erlinyou.worldlist:id/submit").click()
    except Exception as e:
        element_error(self, e)
Beispiel #5
0
def chatTitle_element(self):
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id(
            "com.erlinyou.worldlist:id/textview_tab_chat").click()
    except Exception as e:
        element_error(self=self, e=e)
Beispiel #6
0
def chat_place_on_map_GPS(self):
    """place page GPS"""
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id("rl_current").click()
    except Exception as e:
        element_error(self, e)
Beispiel #7
0
def homepage_details_go_home_element(self):
    """详情页回家"""
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id("rl_home").click()
    except Exception as e:
        element_error(self, e)
Beispiel #8
0
def dynamic_give_like_element(self):
    """动态详情页 点赞"""
    try:
        self.driver.find_element_by_id(
            "com.erlinyou.worldlist:id/layout_likes").text
    except Exception as e:
        element_error(self, e)
Beispiel #9
0
def dynamic(self):
    """ 首页 动态"""
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id("com.erlinyou.worldlist:id/iv_moments_icon").click()
    except Exception as e:
        element_error(self, e)
Beispiel #10
0
def homepage_details_go_home_add_1(self):
    """详情页未添加回家"""
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id("com.erlinyou.worldlist:id/tv_home_set")
    except Exception as e:
        element_error(self.driver, e)
Beispiel #11
0
def homepage_2d_3d(self):
    """2d 3d"""
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id("com.erlinyou.worldlist:id/ll_2d3dSwitch").click()
    except Exception as e:
        element_error(self, e)
Beispiel #12
0
def homepage_narrow_element(self):
    """首页缩小"""
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id("com.erlinyou.worldlist:id/iv_zoom_in").click()
    except Exception as e:
        element_error(self, e)
Beispiel #13
0
def homepage_location_element(self):
    """首页定位自身,和旋转"""
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id("com.erlinyou.worldlist:id/recenter_img").click()
    except Exception as e:
        element_error(self, e)
Beispiel #14
0
def homepage_input_box_details(self):
    """主页面输入框详情页输入框"""
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id("com.erlinyou.worldlist:id/search_edit").click()
    except Exception as e:
        element_error(self, e)
Beispiel #15
0
def mine_setting(self):
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_xpath("//android.support.v7.widget.RecyclerView/android.widget.LinearLayout[10]"
                                     "/android.widget.RelativeLayout").click()
    except Exception as e:
        element_error(self, e)
Beispiel #16
0
def dynamic_take_picture_taking(self):
    """摄像机拍照按钮"""
    try:
        self.driver.find_element_by_id(
            "com.erlinyou.worldlist:id/btn_shutter_camera").click()
    except Exception as e:
        element_error(self, e)
Beispiel #17
0
def chat_place_on_map_sure(self):
    """place page on map 确定"""
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id("detail_set_tv").click()
    except Exception as e:
        element_error(self, e)
Beispiel #18
0
def chat_add_photo_preview(self):
    """相册预览按钮"""
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id("preview").click()
    except Exception as e:
        element_error(self, e)
Beispiel #19
0
def wxDl_element(self):
    """微信登录页面 点击登录buttton"""
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id("com.tencent.mm:id/cqc").click()
    except Exception as e:
        element_error(self, e)
Beispiel #20
0
def homepage_roam_element(self):
    """点击主页漫游页面"""
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id("com.erlinyou.worldlist:id/iv_starthelicopter").click()
    except Exception as e:
        element_error(self, e)
Beispiel #21
0
def chat_send_all_element(self):
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id(
            "com.erlinyou.worldlist:id/btnSend").click()
    except Exception as e:
        element_error(self, e)
Beispiel #22
0
def roam_page_goto_element(self):
    """到这去"""
    try:
        self.driver.find_element_by_id(
            "com.erlinyou.worldlist:id/ll_top_map_mode_img").click()
    except Exception as e:
        element_error(self, e)
Beispiel #23
0
def chat_expression_element(self):
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id(
            "com.erlinyou.worldlist:id/img_exp").click()
    except Exception as e:
        element_error(self=self, e=e)
Beispiel #24
0
def message_back_element(self):
    """消息页面返回home_page按钮"""
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id("imageview_search").click()
    except Exception as e:
        element_error(self=self, e=e)
Beispiel #25
0
def chat_send_file_choice_folder(self, x, y, z):
    """
    文件管理:下选择具体的文件夹 , 仅支持首页
    :param self:
    :param x: 第1层第几个文件夹
    :param y: 第2层第几个文件夹
    :param z: 第3层第几个文件
    :return:
    """
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_xpath(
            "//android.widget.ListView/android.widget.FrameLayout[%s]" %
            x).click()
        self.driver.find_element_by_xpath(
            "//android.widget.ListView/android.widget.FrameLayout[%s]" %
            y).click()
        self.driver.find_element_by_xpath(
            "//android.widget.ListView/android.widget.FrameLayout[%s]" %
            z).click()
        # 点击确定按钮
        self.driver.find_element_by_xpath(
            "//android.widget.LinearLayout/android.widget.Button[1]").click()
        mylogger.info("确定发送")
    except Exception as e:
        self.driver.implicitly_wait(5)
        element_error(self, e)
Beispiel #26
0
def roam_page_look_more_element(self):
    """漫游页面查看更多"""
    try:

        self.driver.find_element_by_id(
            "com.erlinyou.worldlist:id/rl_heli_look_more").click()
    except Exception as e:
        element_error(self.driver, e)
Beispiel #27
0
def chat_location_contact_share_search(self, n):
    """联系人分享 查询button"""
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id(
            "com.erlinyou.worldlist:id/edit_search").send_keys(n)
    except Exception as e:
        element_error(self, e)
Beispiel #28
0
def chat_location_share_stop(self):
    """位置分享 结束"""
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id(
            "com.erlinyou.worldlist:id/stop").click()
    except Exception as e:
        element_error(self, e)
Beispiel #29
0
def chat_take_picture_videotape(self):
    """照片切换视频按钮"""
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id(
            "com.erlinyou.worldlist:id/btn_switch_mode").click()
    except Exception as e:
        element_error(self, e)
Beispiel #30
0
def chat_take_picture_start(self):
    """拍照启动"""
    try:
        self.driver.implicitly_wait(5)
        self.driver.find_element_by_id(
            "com.erlinyou.worldlist:id/btn_shutter_camera").click()
    except Exception as e:
        element_error(self, e)