diff options
| author | youzhijiang <[email protected]> | 2024-10-22 19:06:25 +0800 |
|---|---|---|
| committer | youzhijiang <[email protected]> | 2024-10-22 19:06:25 +0800 |
| commit | 6155efa9504b7484bb7b8137fc47bc031a0f88ba (patch) | |
| tree | c71d1f5b8405c9a130115ec28b74c7618ba87390 | |
| parent | 9b24c7fdacbe51376714440e743d822e090a425c (diff) | |
修改元素定位
| -rw-r--r-- | cases/object/test_ip_address.py | 26 | ||||
| -rw-r--r-- | common/ui_common/objects/accounts.py | 29 | ||||
| -rw-r--r-- | common/ui_common/objects/fqdns.py | 13 | ||||
| -rw-r--r-- | common/ui_common/objects/ip_address.py | 26 | ||||
| -rw-r--r-- | common/ui_common/objects/keywords.py | 8 | ||||
| -rw-r--r-- | common/ui_common/objects/objects_public_operations.py | 5 | ||||
| -rw-r--r-- | common/ui_common/objects/urls.py | 17 | ||||
| -rw-r--r-- | page_element/objects_element_position.py | 27 |
8 files changed, 71 insertions, 80 deletions
diff --git a/cases/object/test_ip_address.py b/cases/object/test_ip_address.py index 407b6458..f24416a4 100644 --- a/cases/object/test_ip_address.py +++ b/cases/object/test_ip_address.py @@ -35,7 +35,7 @@ class Test_ip_address: }, "Createtype": "IP", "Subtype": "not_delete", - "Search_type": "ID" + "Search_type": "Name" },{ "ids": "用例13、IP的嵌套五层", "Name": "test--2", @@ -46,7 +46,7 @@ class Test_ip_address: }, "Createtype": "IP", "Subtype": "not_delete", - "Search_type": "ID" + "Search_type": "Name" },{ "ids": "用例13、IP的嵌套五层", "Name": "test--3", @@ -57,7 +57,7 @@ class Test_ip_address: }, "Createtype": "IP", "Subtype": "not_delete", - "Search_type": "ID" + "Search_type": "Name" },{ "ids": "用例13、IP的嵌套五层", "Name": "test--", @@ -95,7 +95,7 @@ class Test_ip_address: }, "Createtype": "IP", "Subtype": "", - "Search_type": "ID" + "Search_type": "Name" },{ "ids": "用例1、IP_Object的统计查看", "Name": "test-1", @@ -109,7 +109,7 @@ class Test_ip_address: }, "Createtype": "IP", "Subtype": "", - "Search_type": "ID" + "Search_type": "Name" } ]) def test_View_statistics_case(self,demo_fixture,data): @@ -163,7 +163,7 @@ class Test_ip_address: }, "Createtype": "IP", "Subtype": "export_files", - "Search_type": "ID" + "Search_type": "IP" } ] ) #ip address 导出文件 def test_ip_address_export_files_case(self, data): @@ -209,7 +209,7 @@ class Test_ip_address: }, "Createtype": "IP", "Subtype": "", - "Search_type": "ID" + "Search_type": "Name" },{ "ids": "用例13、IP的嵌套五层", "Name": "test--2->edit-name-test", @@ -223,7 +223,7 @@ class Test_ip_address: }, "Createtype": "IP", "Subtype": "", - "Search_type": "ID" + "Search_type": "Name" } ]) def test_audit_log_case(self,demo_fixture,data): @@ -335,7 +335,7 @@ class Test_ip_address: }, "Createtype": "IP", "Subtype": "3", - "Search_type": "ID" + "Search_type": "Name" } ]) def test_group_include(self,demo_fixture,data): @@ -353,7 +353,7 @@ class Test_ip_address: }, "Createtype": "IP", "Subtype": "", - "Search_type": "ID", + "Search_type": "Name", "item_search": "IP" }, { "ids": "用例13、IP的嵌套五层", @@ -368,7 +368,7 @@ class Test_ip_address: }, "Createtype": "IP", "Subtype": "", - "Search_type": "ID" + "Search_type": "Name" } ]) def test_item_search(self, demo_fixture, data): @@ -405,7 +405,7 @@ class Test_ip_address: }, "Createtype": "IP", "Subtype": "", - "Search_type": "ID" + "Search_type": "Name" } ]) def test_sub_objects_drawer_search(self, demo_fixture, data): @@ -426,7 +426,7 @@ class Test_ip_address: }, "Createtype": "IP", "Subtype": "", - "Search_type": "ID" + "Search_type": "Name" } ]) def test_audit_log_all_operation(self,data): diff --git a/common/ui_common/objects/accounts.py b/common/ui_common/objects/accounts.py index 5350d68d..ebf6af68 100644 --- a/common/ui_common/objects/accounts.py +++ b/common/ui_common/objects/accounts.py @@ -565,7 +565,7 @@ class Accounts: self.driver.isElementExist('//div[@class="EditDraw"]//div[@class="el-loading-mask"]') if not self.driver.Exist: break - self.driver.find_element(By.XPATH, '//div[@data-desc="subObject"]/label').click() + self.driver.find_element(By.XPATH, "//div[@class='MuiBox-root css-nfknh2']//label[text()='Subordinate Objects']").click() # 判断是否存在Subordinate Objects 下的"+"按钮 if self.objects_po.is_element_clickable(acc_ObjectGroupDetailPage_subObjects_addButton_normalAdd_posXpath, "XPATH"): @@ -892,10 +892,10 @@ class Accounts: self.driver.find_element(By.XPATH, acc_ObjectGroupDetailPage_subObjects_subCreateAccountDrawer_okButton_posXpath).click() # 点击“OK”按钮 # 点击侧滑子Create Account页面确认弹窗的“Yes”按钮 - subCreateAccountDrawer_okButton_yes = self.driver.find_element(By.XPATH, - acc_ObjectGroupDetailPage_subObjects_subCreateAccountDrawer_okButton_yes_posXpath) - if subCreateAccountDrawer_okButton_yes.is_displayed(): - subCreateAccountDrawer_okButton_yes.click() + # subCreateAccountDrawer_okButton_yes = self.driver.find_element(By.XPATH, + # acc_ObjectGroupDetailPage_subObjects_subCreateAccountDrawer_okButton_yes_posXpath) + # if subCreateAccountDrawer_okButton_yes.is_displayed(): + # subCreateAccountDrawer_okButton_yes.click() def _operate_exclude_objects(self, data, data_index=0): """ @@ -2836,7 +2836,7 @@ class Accounts: # 页面选项操作 if data["Model"] == "modify": self.driver.find_element(By.XPATH, listPage_first_row_checkBox_posXpath).click() - self.driver.find_element(By.XPATH, listPage_editButton_posXpath).click() + self.driver.find_element(By.XPATH, listpage_edit_button_posXpath).click() self._operate_page(data, operation_type="modify") else: # 选择创建模式,single or group @@ -3301,27 +3301,22 @@ class Accounts: ##勾选 self.driver.find_element(By.XPATH, acc_listPage_first_row_checkBox_posXpath).click() ##点击编辑按钮 - self.driver.find_element(By.XPATH, listPage_editButton_posXpath).click() + self.driver.find_element(By.XPATH, listpage_edit_button_posXpath).click() ##点击 add button展开drawer_search - self.driver.find_element(By.XPATH, - acc_ObjectGroupDetailPage_subObjects_addButton_normalAdd_posXpath).click() + self.driver.find_element(By.XPATH,acc_ObjectGroupDetailPage_subObjects_addButton_normalAdd_posXpath).click() # drawer_search 校验 try: # 首先进行错误搜索校验 - self.driver.find_element(By.XPATH, groupObjectDetailPage_addSubObjecDrawer_searchInput_posXpath).send_keys( - self.my_random.random_number() + Keys.ENTER) - assert self.driver.find_element(By.XPATH, - groupObjectDetailPage_addSubObjecDrawer_totalText_posXpath).text == "Total:0" + self.driver.find_element(By.XPATH, groupObjectDetailPage_addSubObjecDrawer_searchInput_posXpath).send_keys(self.my_random.random_number() + Keys.ENTER) + assert self.driver.find_element(By.XPATH,groupObjectDetailPage_addSubObjecDrawer_totalText_posXpath).get_attribute("innerHTML") == "Total:0" # 正确校验 self.driver.find_element(By.XPATH, groupObjectDetailPage_addSubObjecDrawer_searchInput_posXpath).clear() - self.driver.find_element(By.XPATH, groupObjectDetailPage_addSubObjecDrawer_searchInput_posXpath).send_keys( - search_value + Keys.ENTER) + self.driver.find_element(By.XPATH, groupObjectDetailPage_addSubObjecDrawer_searchInput_posXpath).send_keys(search_value + Keys.ENTER) # resulte_text = self.driver.find_element(By.XPATH,"//div[@class='IpItems list-box']//ul[@class='row-container tableList']/li[1]/div").text # 等待查询结果加载 item_result_pos = groupObjectDetailPage_addSubObjecDrawer_firstSubObject_posXpath self.wait.until(EC.visibility_of_element_located((By.XPATH, item_result_pos))) - total_text = self.driver.find_element(By.XPATH, - groupObjectDetailPage_addSubObjecDrawer_totalText_posXpath).text + total_text = self.driver.find_element(By.XPATH,groupObjectDetailPage_addSubObjecDrawer_totalText_posXpath).get_attribute("innerHTML") assert total_text == "Total:1", "搜索结果错误,此时获取到的文本为{}".format(total_text) # self.driver.find_element(By.XPATH,"//div[@class='IpItems list-box']//span[normalize-space(text())='Close']").click() except Exception as e: diff --git a/common/ui_common/objects/fqdns.py b/common/ui_common/objects/fqdns.py index b8999598..6a818b50 100644 --- a/common/ui_common/objects/fqdns.py +++ b/common/ui_common/objects/fqdns.py @@ -1379,7 +1379,7 @@ class FQDNs: elif data["Subtype"] == "1": self.loading_parameter(data) self.driver.find_element(By.XPATH, FQDNs_Group_sub_Object_group_exclude_open_posXpath).click() - self.driver.find_element(By.XPATH,listPage_object_group_exclude_add_button_posXpath).click() + self.driver.find_element(By.XPATH,FQDNs_group_exclude_add_button_posXpath).click() # self.driver.find_element(By.XPATH,listPage_object_group_subobject_fist_posXpath).click() self.driver.find_element(By.XPATH,FQDNs_Group_sub_Object_add_new_Button_posXpath).click() # add new sub_object self.driver.find_element(By.XPATH,FQDNs_Group_sub_Object_add_new_Select_one_Button_posXpath).click() # new mobile_Identities @@ -1508,15 +1508,14 @@ class FQDNs: ##勾选 self.driver.find_element(By.XPATH, acc_listPage_first_row_checkBox_posXpath).click() ##点击编辑按钮 - self.driver.find_element(By.XPATH, listPage_editButton_posXpath).click() + self.driver.find_element(By.XPATH, listpage_edit_button_posXpath).click() ##点击 add button展开drawer_search - self.driver.find_element(By.XPATH,acc_ObjectGroupDetailPage_subObjects_addButton_normalAdd_posXpath).click() + self.driver.find_element(By.XPATH,FQDNs_ObjectGroupDetailPage_subObjects_addButton_normalAdd_posXpath).click() # drawer_search 校验 try: # 首先进行错误搜索校验 - self.driver.find_element(By.XPATH, groupObjectDetailPage_addSubObjecDrawer_searchInput_posXpath).send_keys( - self.my_random.random_number() + Keys.ENTER) - assert self.driver.find_element(By.XPATH,groupObjectDetailPage_addSubObjecDrawer_totalText_posXpath).text == "Total:0" + self.driver.find_element(By.XPATH, groupObjectDetailPage_addSubObjecDrawer_searchInput_posXpath).send_keys(self.my_random.random_number() + Keys.ENTER) + assert self.driver.find_element(By.XPATH,groupObjectDetailPage_addSubObjecDrawer_totalText_posXpath).get_attribute("innerHTML") == "Total:0" # 正确校验 self.driver.find_element(By.XPATH, groupObjectDetailPage_addSubObjecDrawer_searchInput_posXpath).clear() self.driver.find_element(By.XPATH, groupObjectDetailPage_addSubObjecDrawer_searchInput_posXpath).send_keys( @@ -1525,7 +1524,7 @@ class FQDNs: # 等待查询结果加载 item_result_pos = groupObjectDetailPage_addSubObjecDrawer_firstSubObject_posXpath self.wait.until(EC.visibility_of_element_located((By.XPATH, item_result_pos))) - total_text = self.driver.find_element(By.XPATH,groupObjectDetailPage_addSubObjecDrawer_totalText_posXpath).text + total_text = self.driver.find_element(By.XPATH,groupObjectDetailPage_addSubObjecDrawer_totalText_posXpath).get_attribute("innerHTML") assert total_text == "Total:1", "搜索结果错误,此时获取到的文本为{}".format(total_text) # self.driver.find_element(By.XPATH,"//div[@class='IpItems list-box']//span[normalize-space(text())='Close']").click() except Exception as e: diff --git a/common/ui_common/objects/ip_address.py b/common/ui_common/objects/ip_address.py index b08c5305..a7a108b6 100644 --- a/common/ui_common/objects/ip_address.py +++ b/common/ui_common/objects/ip_address.py @@ -308,12 +308,12 @@ class IPAddress: # self.driver.find_element(By.XPATH,ip_address_Group_sub_Object_add_new_one_OK1_Warning_Yes_Button_posXpath).click() # 确认新建保存按钮 # 确认创建 self.driver.find_element(By.XPATH, ip_addressObjectPage_button_OK_posXpath).click() - try: - self.driver.isElementExist(Element=ip_addressObjectPage_button_warningSaveYes_posXpath) - if self.driver.Exist: - self.driver.find_element(By.XPATH,ip_addressObjectPage_button_warningSaveYes_posXpath).click() - except: - pass + # try: + # self.driver.isElementExist(Element=ip_addressObjectPage_button_warningSaveYes_posXpath) + # if self.driver.Exist: + # self.driver.find_element(By.XPATH,ip_addressObjectPage_button_warningSaveYes_posXpath).click() + # except: + # pass time.sleep(3) self.objects_po.extract_ele() elif self.modify_status =="1": @@ -1714,17 +1714,14 @@ class IPAddress: ##勾选 self.driver.find_element(By.XPATH, acc_listPage_first_row_checkBox_posXpath).click() ##点击编辑按钮 - self.driver.find_element(By.XPATH, listPage_editButton_posXpath).click() + self.driver.find_element(By.XPATH, listpage_edit_button_posXpath).click() ##点击 add button展开drawer_search - self.driver.find_element(By.XPATH, - acc_ObjectGroupDetailPage_subObjects_addButton_normalAdd_posXpath).click() + self.driver.find_element(By.XPATH, ip_ObjectGroupDetailPage_subObjects_addButton_normalAdd_posXpath).click() # drawer_search 校验 try: # 首先进行错误搜索校验 - self.driver.find_element(By.XPATH, groupObjectDetailPage_addSubObjecDrawer_searchInput_posXpath).send_keys( - self.my_random.random_number() + Keys.ENTER) - assert self.driver.find_element(By.XPATH, - groupObjectDetailPage_addSubObjecDrawer_totalText_posXpath).text == "Total:0" + self.driver.find_element(By.XPATH, groupObjectDetailPage_addSubObjecDrawer_searchInput_posXpath).send_keys(self.my_random.random_number() + Keys.ENTER) + assert self.driver.find_element(By.XPATH,groupObjectDetailPage_addSubObjecDrawer_totalText_posXpath).get_attribute("innerHTML") == "Total:0" # 正确校验 self.driver.find_element(By.XPATH, groupObjectDetailPage_addSubObjecDrawer_searchInput_posXpath).clear() self.driver.find_element(By.XPATH, groupObjectDetailPage_addSubObjecDrawer_searchInput_posXpath).send_keys( @@ -1733,8 +1730,7 @@ class IPAddress: # 等待查询结果加载 item_result_pos = groupObjectDetailPage_addSubObjecDrawer_firstSubObject_posXpath self.wait.until(EC.visibility_of_element_located((By.XPATH, item_result_pos))) - total_text = self.driver.find_element(By.XPATH, - groupObjectDetailPage_addSubObjecDrawer_totalText_posXpath).text + total_text = self.driver.find_element(By.XPATH,groupObjectDetailPage_addSubObjecDrawer_totalText_posXpath).get_attribute("innerHTML") assert total_text == "Total:1", "搜索结果错误,此时获取到的文本为{}".format(total_text) # self.driver.find_element(By.XPATH,"//div[@class='IpItems list-box']//span[normalize-space(text())='Close']").click() except Exception as e: diff --git a/common/ui_common/objects/keywords.py b/common/ui_common/objects/keywords.py index af495cb9..5e019a9f 100644 --- a/common/ui_common/objects/keywords.py +++ b/common/ui_common/objects/keywords.py @@ -1130,7 +1130,7 @@ class Keywords: self.loading_parameter(data) self.Keywords_create_object_group(data) self.driver.find_element(By.XPATH, Keywords_Group_sub_Object_add_new_one_OK1_Button_posXpath).click() - self.driver.find_element(By.XPATH,Keywords_Group_sub_Object_add_new_one_OK1_Warning_Yes_Button_posXpath).click() + # self.driver.find_element(By.XPATH,Keywords_Group_sub_Object_add_new_one_OK1_Warning_Yes_Button_posXpath).click() self.driver.find_element(By.XPATH,ip_object_group_subobject_close_posXpath).click() self.driver.find_element(By.XPATH,Keywords_Group_sub_Object_exclude_open_posXpath).click() time.sleep(2) @@ -1141,7 +1141,7 @@ class Keywords: self._delete_sub(data) elif data["Subtype"] == "1": self.driver.find_element(By.XPATH, Keywords_Group_sub_Object_exclude_open_posXpath).click() - self.driver.find_element(By.XPATH,listPage_object_group_exclude_add_button_posXpath).click() + self.driver.find_element(By.XPATH,Keywords_Group_sub_object_group_exclude_add_button_posXpath).click() self.driver.find_element(By.XPATH,listPage_object_group_subobject_fist_posXpath).click() self.driver.find_element(By.XPATH,ip_object_group_subobject_close_posXpath).click() self.driver.find_element(By.XPATH, KeywordsObjectPage_button_SaveYes_posXpath).click() @@ -1692,9 +1692,9 @@ class Keywords: ##勾选 self.driver.find_element(By.XPATH, acc_listPage_first_row_checkBox_posXpath).click() ##点击编辑按钮 - self.driver.find_element(By.XPATH, listPage_editButton_posXpath).click() + self.driver.find_element(By.XPATH, listpage_edit_button_posXpath).click() ##点击 add button展开drawer_search - self.driver.find_element(By.XPATH, acc_ObjectGroupDetailPage_subObjects_addButton_normalAdd_posXpath).click() + self.driver.find_element(By.XPATH, Keywords_ObjectGroupDetailPage_subObjects_addButton_normalAdd_posXpath).click() # drawer_search 校验 try: # 首先进行错误搜索校验 diff --git a/common/ui_common/objects/objects_public_operations.py b/common/ui_common/objects/objects_public_operations.py index 514c34a4..40e7fbe0 100644 --- a/common/ui_common/objects/objects_public_operations.py +++ b/common/ui_common/objects/objects_public_operations.py @@ -494,8 +494,7 @@ class ObjectsPublicOperations: if data["repetition_type"] == "0": # 侧滑部分校验 self.driver.find_element(By.XPATH, listPage_object_reprtition_check_postXpath).click() - self.total_count = self.driver.find_element(By.XPATH, - "//div[@class='tab-content floatleft height100 width100']/p").text + self.total_count = self.driver.find_element(By.XPATH,listPage_object_reprtition_total_postXpath).text self.count = self.total_count.split("Total:") print(self.count[1]) assert self.count[1] == '1' @@ -528,7 +527,7 @@ class ObjectsPublicOperations: # 侧滑部分校验 self.driver.find_element(By.XPATH, listPage_object_reprtition_check_postXpath).click() total_count = self.driver.find_element(By.XPATH, - "//div[@class='tab-content floatleft height100 width100']/p").text + listPage_object_reprtition_total_postXpath).text count = total_count.split("Total:") assert int(count[1]) >= 1, "校验失败!" # 悬浮框内容校验 diff --git a/common/ui_common/objects/urls.py b/common/ui_common/objects/urls.py index 099ce0c7..d207e66d 100644 --- a/common/ui_common/objects/urls.py +++ b/common/ui_common/objects/urls.py @@ -3518,27 +3518,22 @@ class URLs: ##勾选 self.driver.find_element(By.XPATH, acc_listPage_first_row_checkBox_posXpath).click() ##点击编辑按钮 - self.driver.find_element(By.XPATH, listPage_editButton_posXpath).click() + self.driver.find_element(By.XPATH, listpage_edit_button_posXpath).click() ##点击 add button展开drawer_search - self.driver.find_element(By.XPATH, - acc_ObjectGroupDetailPage_subObjects_addButton_normalAdd_posXpath).click() + self.driver.find_element(By.XPATH,acc_ObjectGroupDetailPage_subObjects_addButton_normalAdd_posXpath).click() # drawer_search 校验 try: # 首先进行错误搜索校验 - self.driver.find_element(By.XPATH, groupObjectDetailPage_addSubObjecDrawer_searchInput_posXpath).send_keys( - self.my_random.random_number() + Keys.ENTER) - assert self.driver.find_element(By.XPATH, - groupObjectDetailPage_addSubObjecDrawer_totalText_posXpath).text == "Total:0" + self.driver.find_element(By.XPATH, groupObjectDetailPage_addSubObjecDrawer_searchInput_posXpath).send_keys(self.my_random.random_number() + Keys.ENTER) + assert self.driver.find_element(By.XPATH,groupObjectDetailPage_addSubObjecDrawer_totalText_posXpath).get_attribute("innerHTML") == "Total:0" # 正确校验 self.driver.find_element(By.XPATH, groupObjectDetailPage_addSubObjecDrawer_searchInput_posXpath).clear() - self.driver.find_element(By.XPATH, groupObjectDetailPage_addSubObjecDrawer_searchInput_posXpath).send_keys( - search_value + Keys.ENTER) + self.driver.find_element(By.XPATH, groupObjectDetailPage_addSubObjecDrawer_searchInput_posXpath).send_keys(search_value + Keys.ENTER) # resulte_text = self.driver.find_element(By.XPATH,"//div[@class='IpItems list-box']//ul[@class='row-container tableList']/li[1]/div").text # 等待查询结果加载 item_result_pos = groupObjectDetailPage_addSubObjecDrawer_firstSubObject_posXpath self.wait.until(EC.visibility_of_element_located((By.XPATH, item_result_pos))) - total_text = self.driver.find_element(By.XPATH, - groupObjectDetailPage_addSubObjecDrawer_totalText_posXpath).text + total_text = self.driver.find_element(By.XPATH,groupObjectDetailPage_addSubObjecDrawer_totalText_posXpath).get_attribute("innerHTML") assert total_text == "Total:2", "搜索结果错误,此时获取到的文本为{}".format(total_text) # self.driver.find_element(By.XPATH,"//div[@class='IpItems list-box']//span[normalize-space(text())='Close']").click() except Exception as e: diff --git a/page_element/objects_element_position.py b/page_element/objects_element_position.py index 554b202b..b0a94dc5 100644 --- a/page_element/objects_element_position.py +++ b/page_element/objects_element_position.py @@ -122,7 +122,7 @@ mainPage_ObjectSearch_buttonClear_posId = "searchClear" # 清空查询按钮id mainPage_ObjectSearch_buttonClear_posXpath = "//button[@class='MuiAutocomplete-clearIndicator css-25qtv2']" # 清空查询按钮xpath mainPage_ObjectSearch_buttonSearch_Item_posId = "object_ip_search" # 查询item输入框id mainPage_ObjectSearch_buttonSearch_Item_first_content_posXpath = "//div[@class='view-row']//span[@class='el-tooltip content-show']" # item搜索框第一个元素 -mainPage_ObjectSearch_buttonSearch_Item_posXpath = "//input[@placeholder='Search For']" # 查询item输入框Xpath +mainPage_ObjectSearch_buttonSearch_Item_posXpath = "//div[@class='css-dob60y']//input[@class='MuiInput-input css-za5rna']" # 查询item输入框Xpath mainPage_ObjectSearch_buttonAddItem_posId = "temporary_form" # 添加item_id mainPage_ObjectSearch_buttonAddItem_posXpath = "//i[@class='iconfont icon-Create1 font-[700]']" mainPage_ObjectSearch_input_Item_posId = "onlyMarvel" # 输入item_id @@ -140,7 +140,7 @@ main_ObjectPage_No_data_text_posXpath = "//DIV[@class='MuiDataGrid-overlay css-1 # 列表中元素 main_listPage_object_select_First_object_posXpath = '//div[@data-rowindex="0"]' -main_listPage_object_select_Second_object_posXpath = '//table/tbody/tr[2]/td[1]/div/div/div[1]/div/label/span[1]/span' # 选择列表中第二个对象 +main_listPage_object_select_Second_object_posXpath = "//div[@class='MuiDataGrid-virtualScrollerRenderZone css-1inm7gi']/div[2]//span[@class='MuiCheckbox-action css-kit57i']" # 选择列表中第二个对象 main_listPage_object_total_value_posXpath = '(//div[@class="flex-1 flex items-center justify-center undefined"]/span)[1]' # 列表页total值 ##Object模块列设置 mainPage_ObjectSearch_Column_settings_posXpath = "//i[@class='iconfont icon-SetNormal text-[14px] text-[var(--color-text-disabled)]']" @@ -237,9 +237,9 @@ ObjectDetailPage_audit_log_compare_time_posXpath = "//div[@class='compare-code-b ObjectDetailPage_audit_log_compare_user_posXpath = '//div[contains(text(),"User")]/following-sibling::div' ObjectDetailPage_audit_log_cancel_posXpath = "//div[@class='paper-right-content']//span[normalize-space(text())='Close']" # Group Object详情页通用元素 -groupObjectDetailPage_addSubObjecDrawer_searchInput_posXpath = '//div[@class="right-menu-content"]//div[contains(@class,"list-box")]//*[@id="object_ip_search"]' # Group 详情页添加sub Object的侧滑页面中的搜索框 -groupObjectDetailPage_addSubObjecDrawer_totalText_posXpath = '//div[@class="right-menu-content"]//div[contains(@class,"list-box")]//*[contains(@class,"total positionAbsolute")]' # Group 详情页添加sub Object的侧滑页面中的Total文本 -groupObjectDetailPage_addSubObjecDrawer_firstSubObject_posXpath = '(//div[@class="right-menu-content"]//div[contains(@class,"list-box")]//ul[@class="row-container tableList"]/li)[1]' # Group 详情页添加sub Object的侧滑页面中第一个sub object +groupObjectDetailPage_addSubObjecDrawer_searchInput_posXpath = "//div[@class='css-dob60y']//input[@class='MuiInput-input css-za5rna']" # Group 详情页添加sub Object的侧滑页面中的搜索框 +groupObjectDetailPage_addSubObjecDrawer_totalText_posXpath = "//div[@class='px-[12px] pb-[4px] pt-[2px] text-[--color-text-disabled]']" # Group 详情页添加sub Object的侧滑页面中的Total文本 +groupObjectDetailPage_addSubObjecDrawer_firstSubObject_posXpath = "//div[@class='pt-[2px] overflow-hidden flex-1']//ul/li[1]" # Group 详情页添加sub Object的侧滑页面中第一个sub object groupObjectDetailPage_subordinateObjects_search_posXpath = '//div[@class="apn-object-included_sub_object_uuids"]//input' groupObjectDetailPage_excludeObjects_search_posXpath = '//div[@class="apn-object-excluded_sub_object_uuids"]//input' @@ -271,6 +271,7 @@ listPage_object_mobileIdentities_reference_close_posXpath = "//button[@id='inter listPage_object_reprtition_check_postXpath = '//i[@class="iconfont icon-jinggao1 text-[var(--color-btn-warning)] px-[4px] text-[18px]"]' listPage_current_object_reprtition_tips_posXpath = '//*[@id="router-view-container"]//div[@title="There are duplicates in the current object"]' listPage_other_object_reprtition_tips_posXpath = '//*[@id="router-view-container"]//div[@title="Duplicate data exists"]' +listPage_object_reprtition_total_postXpath = "//div[@class='css-dob60y']//div[@class='text-[--color-text-disabled]']" # '//table/tbody/tr[1]/td[4]/div/div/div/div/div/div[1]/span' # IMSI提取Details listPage_object_group_exclude_open_posXpath = "//div[@class='ip-object-']" listPage_object_group_subobject_fist_posXpath = '//ul[@class="MuiList-root MuiList-vertical MuiList-variantPlain MuiList-colorNeutral MuiList-sizeMd css-1cklc3"]/li[1]//span[@class="truncate"]' @@ -280,6 +281,7 @@ fqdn_object_group_subobject_close_posXpath = "//div[@class='FqdnList list-box']/ http_signature_object_group_close_posXpath = "//div[@class='HttpSignatureList list-box']//span[normalize-space(text())='Close']" subscriber_id_object_group_close_posXpath = "//div[@class='SubscriberidList list-box']//span[normalize-space(text())='Close']" listPage_object_group_exclude_add_button_posXpath = "//div[@class='ip-object-excluded_sub_object_uuids']//i[@class='iconfont icon-Create1 font-[700]']" +ip_ObjectGroupDetailPage_subObjects_addButton_normalAdd_posXpath = "//div[@class='ip-object-included_sub_object_uuids']//i[@class='iconfont icon-Create1 text-[18px] font-[700] text-[--color-primary] cursor-pointer']" listPage_object_group_include_add_button_posXpath = "//div[@class='ip-object-included_sub_object_uuids']//i[@class='iconfont icon-Create1 font-[700]']" # Object Mobile Identities===================Object Mobile Identities====================Object Mobile Identities=================Object Mobile Identities=======================Object Mobile Identities=================Object Mobile Identities @@ -685,15 +687,14 @@ ip_addressObjectPage_button_Input_Vote_Clients_Number_posXpath = "//div[@class=' ip_addressObjectPage_button_Input_Learned_IP_Limits_posXpath = "//div[@class='ip-object-goal_upper_limit']/div/input" # Learned IP Limits 输入框 ip_addressObjectPage_textArea_Description_posXpath = "//div[@class='ip-object-description']//textarea[1]" # description文本输入区Xpath -ip_addressObjectPage_button_OK_posXpath = "//button[@class='MuiButtonBase-root MuiButton-root MuiLoadingButton-root MuiButton-text MuiButton-textPrimary MuiButton-sizeSmall MuiButton-textSizeSmall \ -MuiButton-colorPrimary MuiButton-root MuiLoadingButton-root MuiButton-text MuiButton-textPrimary MuiButton-sizeSmall MuiButton-textSizeSmall MuiButton-colorPrimary form-action-submit css-1djnbgz']" # Group保存主页面OK按钮 +ip_addressObjectPage_button_OK_posXpath = "//div[@class=' ip-object-page MuiBox-root css-o7xelj']//button[text()='OK']" # Group保存主页面OK按钮 ip_addressObjectPage_button_SaveYes_posXpath = '//button[@id="OK-_IpDetail_VDraswer_EditDraw_IpDetail_Home_App_anonymousComponent"]/span' # Group引用创建OK按钮 ip_addressObjectPage_button_warningSaveYes_posXpath = "//div[@class='el-message-box__wrapper']/div/div[3]/button[2]/span" # 提示保存ok按钮警告框 ip_addressObjectPage_button_warningSaveCancel_posCss = '//div[@class="el-message-box__wrapper"]/div/div[3]/button[1]/span' # 提示保存取消按钮警告框 ip_addressObjectPage_button_cancel_posCss = "//button[@id='Cancel-_IpDetail_Home_App_anonymousComponent']/span" # Cancel按钮 # Create IP Address Group Object 和 Edit Create IP Address Group 新增和编辑页 -ip_address_Group_sub_Object_addButton_posXpath = "//div[@class='ip-object-included_sub_object_uuids']" # ip_address_Group添加sub Object按钮 +ip_address_Group_sub_Object_addButton_posXpath = "//div[@class='ip-object-included_sub_object_uuids']//i[@class='iconfont icon-Create1 font-[700]']" # ip_address_Group添加sub Object按钮 ip_address_Group_sub_Object_add_new_Button_posXpath = "//i[@class='iconfont icon-Create1']" # 新建sub_ip_address按钮 ip_address_Group_sub_Object_add_new_Select_one_Button_posXpath = "//ul[@class='base-Popper-root MuiMenu-root Mui-expanded MuiMenu-variantOutlined MuiMenu-colorNeutral MuiMenu-sizeMd css-131n2dh']//li[1]" # 新建选择ip_address按钮 ip_address_Group_sub_Object_edit_subObject_Button_posXpath = "//i[@class='row-edit iconfont icon-Edit cursor fontsize18']" # 编辑group 下的object 按钮 @@ -783,6 +784,9 @@ FQDNs_Group_sub_Object_add_new_one_OK1_Warning_Yes_Button_posXpath = "//div[@cla FQDNs_Group_sub_Object_add_new_one_OK1_Warning_Cancel_Button_posXpath = "//div[@class='el-message-box__btns']//span[normalize-space(text())='Cancel']" # 再次确认取消new FQDNs FQDNs_Group_sub_Object_add_new_one_Cancel2_Button_posXpath = '//div/div/div[2]/div/div/div[1]/div/div/div[1]/div[3]/button[2]/span' # new FQDNs CreateCancel2 FQDNs_Group_sub_Object_group_exclude_open_posXpath = "//div[@class='fqdn-object-']" +FQDNs_group_include_add_button_posXpath = "//div[@class='fqdn-object-included_sub_object_uuids']//i[@class='iconfont icon-Create1 font-[700]']" +FQDNs_group_exclude_add_button_posXpath = "//div[@class='fqdn-object-excluded_sub_object_uuids']//i[@class='iconfont icon-Create1 font-[700]']" +FQDNs_ObjectGroupDetailPage_subObjects_addButton_normalAdd_posXpath = "//div[@class='fqdn-object-included_sub_object_uuids']//i[@class='iconfont icon-Create1 text-[18px] font-[700] text-[--color-primary] cursor-pointer']" # link页 FQDNs_listpage_linkButton_posId = "btnCopy-_OperateBtns_ElRow_Objects_fqdn_Home_App_anonymousComponent" # link按钮ID FQDNs_listpage_linkSave_posXpath = '//*[@id="clusterSave-_ClusterTable_ElDialog_copyComponents_Objects_fqdn_Home_App_anonymousComponent"]' # Cluster和Vsys保存按钮ID @@ -897,7 +901,7 @@ listPage_object_HTTP_Signatures_editButton_posXpath = listPage_object_ip_address listPage_object_HTTP_Signatures_delButton_posXpath = listPage_object_ip_address_delButton_posId # del按钮id listPage_object_HTTP_Signatures_viewButton_posId = "//button[@id='appEdit-_OperateBtns_ElRow_Objects_http_signature_Home_App_anonymousComponent']//p[normalize-space(text()) = 'View']" listPage_object_HTTP_Signatures_delButton_display_posXpath = '//button[@id="appDel-_OperateBtns_ElRow_Objects_http_signature_Home_App_anonymousComponent"][@disabled="disabled"]' # del按钮置灰状态 -list_quote_content_object_HTTP_Signatures_posXpath = '//table/tbody/tr[2]/td[7]/div/div/div/div' # quote计数 +list_quote_content_object_HTTP_Signatures_posXpath = "//div[@class='MuiDataGrid-virtualScrollerContent css-0']/div/div[2]//div[@data-field='reference_count']/button" # quote计数 list_Column_settings_HTTP_Signatures_Description_posXpath = "//div[@class='MuiDataGrid-columnsManagement css-1v3xuhs']//span[text()='Description']" # 列设置选择Description list_HTTP_Signatures_Export_files_button_posXpath = '//div/button[contains(@class,"Export")]/i' # 导出文件按钮 list_HTTP_Signatures_Export_files_yes_button_posXpath = '//div/div[3]/span/button[1]/span[contains(text(),"Yes")]' # 导出文件Yes按钮 @@ -1076,6 +1080,9 @@ Keywords_Group_sub_Object_add_new_one_OK1_Warning_Cancel_Button_posXpath = '//di Keywords_Group_sub_Object_add_new_one_Cancel2_Button_posXpath = '//div/div/div[2]/div/div/div[1]/div/div/div[1]/div[3]/button[2]/span' # new Keywords CreateCancel2 keywords_ObjectPage_button_OK_posXpath = "//*[@id='OK-_keywordsDetail_Home_App_anonymousComponent']" # 详情页ok按钮Xpath Keywords_Group_sub_Object_exclude_open_posXpath = "//div[@class='keyword-object-']" +Keywords_Group_sub_object_group_include_add_button_posXpath = "//div[@class='keyword-object-included_sub_object_uuids']//i[@class='iconfont icon-Create1 font-[700]']" +Keywords_Group_sub_object_group_exclude_add_button_posXpath = "//div[@class='keyword-object-excluded_sub_object_uuids']//i[@class='iconfont icon-Create1 font-[700]']" +Keywords_ObjectGroupDetailPage_subObjects_addButton_normalAdd_posXpath = "//div[@class='keyword-object-included_sub_object_uuids']//i[@class='iconfont icon-Create1 text-[18px] font-[700] text-[--color-primary] cursor-pointer']" # link页 keywords_listpage_linkButton_posId = "btnCopy-_OperateBtns_ElRow_Objects_keywords_Home_App_anonymousComponent" # link按钮ID keywords_listpage_linkSave_posXpath = '//*[@id="clusterSave-_ClusterTable_ElDialog_copyComponents_Objects_keywords_Home_App_anonymousComponent"]' # Cluster和Vsys保存按钮ID @@ -1254,7 +1261,7 @@ acc_ObjectDetailPage_importUrlOk_posXpath = url_ObjectDetailPage_importUrlOk_pos acc_ObjectDetailPage_importDrawer_importTipsValue_posXpath_template = '//div[@class="drawer-box"]//div[@class="importTips"]//td[count(//div[@class="drawer-box"]//div[@class="importTips"]//th[@title="{}"]/preceding-sibling::th)+1]' # Import 页面下的Tips Value值 # 对象组详情页 -acc_ObjectGroupDetailPage_subObjects_addButton_normalAdd_posXpath = "//button[@class='MuiButtonBase-root MuiButton-root MuiLoadingButton-root MuiButton-outlined MuiButton-outlinedPrimary MuiButton-sizeSmall MuiButton-outlinedSizeSmall MuiButton-colorPrimary MuiButton-root MuiLoadingButton-root MuiButton-outlined MuiButton-outlinedPrimary MuiButton-sizeSmall MuiButton-outlinedSizeSmall MuiButton-colorPrimary css-1d67a6h']" # Subordinate Objects 下有数据新增时"+"按钮Xpath +acc_ObjectGroupDetailPage_subObjects_addButton_normalAdd_posXpath = "//div[@class='account-object-included_sub_object_uuids']// i[@class='iconfont icon-Create1 text-[18px] font-[700] text-[--color-primary] cursor-pointer']" # Subordinate Objects 下有数据新增时"+"按钮Xpath acc_ObjectGroupDetailPage_excludeObjects_addButton_normalAdd_posXpath = "//div[@class='account-object-excluded_sub_object_uuids']//i[@class='iconfont icon-Create1 text-[18px] text-weight-700] text-[--color-primary] cursor-pointer']" # Exclude Objects 下有数据新增时"+"按钮Xpath acc_ObjectGroupDetailPage_subObjects_addButton_newAdd_posXpath = "//div[@class='account-object-included_sub_object_uuids']" # Subordinate Objects 下无数据新增时"+"按钮Xpath acc_ObjectGroupDetailPage_excludeObjects_addButton_newAdd_posXpath = "//div[@class='account-object-excluded_sub_object_uuids']" # Exclude Objects 下无数据新增时"+"按钮Xpath |
