コード例 #1
0
    def select_complaint_type(self, complaint_type, complaint_filter=None):
        if complaint_filter is None:
            complaint_filter = complaint_type

        set(self.ID.txtComplaintTypeSearch, complaint_filter)
        click(self.ID.prmLblComplaintType.format(complaint_type))
        return self
コード例 #2
0
 def profile_upload_image(self, image):
     elem = find(self.ID.profileImagePlaceHolder)
     try:
         set(elem, image)
     except InvalidElementStateException:
         unhide(elem)
         set(elem, image)
     CommonComponent().wait_for_busy()
コード例 #3
0
 def set_location_by_address(self, address, result_index=0):
     set(self.ID.txtSearchAddress, address)
     elems = finds(self.ID.lblSearchAddressResults, condition=count_non_zero_and_clickable)
     assert len(elems) != 0, "No search results found"
     elems[result_index].click()
     text = get(self.ID.txtSearchAddress)
     click(self.ID.btnPickAddress)
     return text
コード例 #4
0
    def upload_images(self, *images):
        if type(images) is tuple and len(images) > 0 and type(images[0]) is list:
            images = images[0]

        assert 0 <= len(images) <= 3, "Maximum 3 photos can be uploaded"
        if not images:
            return

        for image in images:
            elem = find(self.ID.fileImageUploadPlaceHolder)
            try:
                set(elem, image)
            except InvalidElementStateException:
                unhide(elem)
                set(elem, image)
コード例 #5
0
ファイル: common.py プロジェクト: egovernments/egov-qa
 def password(self, password):
     set(self.ID.txtPassword, password)
     return self
コード例 #6
0
ファイル: common.py プロジェクト: egovernments/egov-qa
 def employee_id(self, employee_id):
     set(self.ID.txtEmployeeID, employee_id)
     return self
コード例 #7
0
 def set_city(self, city):
     set(self.ID.txtSearch, city)
     click(self.ID.prmLblCity.format(city))
     return self
コード例 #8
0
 def set(self, phone_number, name, city):
     set(self.ID.txtPhoneNumber, phone_number)
     set(self.ID.txtName, name)
     self.set_city(city)
     return self
コード例 #9
0
 def set(self, otp):
     set(self.ID.txtOTP, otp)
     return self
コード例 #10
0
 def set(self, mobile_number):
     set(self.ID.txtMobileNumber, mobile_number)
     return self