diff --git a/01-TestCase/tsg_bfapi/dashboard_data_compare_new_case/TrafficStatistics.robot b/01-TestCase/tsg_bfapi/dashboard_data_compare_new_case/TrafficStatistics.robot new file mode 100644 index 0000000..ae5c0c2 --- /dev/null +++ b/01-TestCase/tsg_bfapi/dashboard_data_compare_new_case/TrafficStatistics.robot @@ -0,0 +1,20 @@ +*** Settings *** +Force Tags tsg-bfapi dashboard traffic +Library Collections +Resource ../../../03-Variable/BifangApiVariable.txt +Resource ../../../02-Keyword/tsg_bfapi/dashboard_keywords/TrafficStatistics.robot +Library GetTimeLibrary + +*** Test Cases *** + +Trafffics-001 + # Traffics-带宽统计 统计类型:总:bytes packets sessions bifang和report对比 + #开始时间 + ${starttime} time1 30s + #结束时间 + ${endtime} time1 s + Dashboard-Traffic-new ${startTime} ${endTime} lyf-trafffics-001 + + + + diff --git a/01-TestCase/tsg_ui/ui_accounts/Accountscase.robot b/01-TestCase/tsg_ui/ui_accounts/Accountscase.robot index b536b49..c34073a 100644 --- a/01-TestCase/tsg_ui/ui_accounts/Accountscase.robot +++ b/01-TestCase/tsg_ui/ui_accounts/Accountscase.robot @@ -109,7 +109,7 @@ create-user-010 #log ${name} #Should Be Equal As Strings ${name} * #删除对象 - #User-Delete + User-Delete create-user-011 #新建Accounts @@ -120,7 +120,7 @@ create-user-011 #log ${name} #Should Be Equal As Strings ${name} @ #删除对象 - #User-Delete + User-Delete delete-user-012 #新建Accounts diff --git a/01-TestCase/tsg_ui/ui_objects/Object-All-Case.robot b/01-TestCase/tsg_ui/ui_objects/Object-All-Case.robot deleted file mode 100644 index 0b1b932..0000000 --- a/01-TestCase/tsg_ui/ui_objects/Object-All-Case.robot +++ /dev/null @@ -1,251 +0,0 @@ -*** Settings *** -Force Tags tsg-ui objects -Resource ../../../03-Variable/bifangapivariable.txt -Resource ../../../02-Keyword/tsg_ui/objects/NewObjectPages.robot -Library OperatingSystem -Resource ../../../02-Keyword/tsg_ui/objects/NewObject.robot - -*** Test Cases *** -single-ip-ip -# 创建单个ip 子分类为ip - Open Browser http://${host}/#/login ${browserType} - Maximize Browser Window - input text xpath=//*[@id="app"]/div/div[2]/div/div[2]/div/input ${username} - input text xpath=//*[@id="app"]/div/div[2]/div/div[3]/div/input ${password} - Click button id=login - #新建user-agent - CreatePage single single-ip-ip objectform=IP ipclienttext1=192.168.1.5 post=0/0 ip_type=Ip keywordtext=Mozilla/5.0* - #验证新建是否成功 - ui-object-search-name single-ip-ip - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span - Should Be Equal As Strings ${text} single-ip-ip - object-edit-ip 我的大哥 192.168.100.100 post=0/100 - #查询修改对象 - ui-object-search-name 我的大哥 - #删除对象 - objects-delete - -single-ip-Geography -# 创建单个ip 子分类为Geography - ${Country} Create List China Hong Kong - ${City} Create List Beijing - CreatePage single create-ip-group-015 objectform=IP ip_type=Geography Country=${Country} City=${City} - #验证新建是否成功 - ui-object-search-name create-ip-group-015 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span - Should Be Equal As Strings ${text} create-ip-group-015 - object-edit-Geography 我的大哥 Country=${Country} City=${City} - #查询修改对象 - ui-object-search-name 我的大哥 - #删除对象 - objects-delete - -group-ip-ip - #新建ip,${objects_name}的赋值可以先新建ip,用刚新建ip的name赋值 - CreatePage single single-ip-ip objectform=IP ipclienttext1=192.168.1.5 post=0/0 ip_type=Ip keywordtext=Mozilla/5.0* - ${objects_name} Create List single-ip-ip - CreatePage group create-ip-group-015 objectform=IP ip_type=Ip object_name=${objects_name} - #验证新建是否成功 - ui-object-search-name create-ip-group-015 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span - Should Be Equal As Strings ${text} create-ip-group-015 - #删除对象 - objects-delete - ui-object-search-name single-ip-ip - objects-delete - - - -group-ip-Geography - ${Country} Create List China Hong Kong - ${City} Create List Beijing - CreatePage single single-ip-015 objectform=IP ip_type=Geography Country=${Country} City=${City} - ${objects_name} Create List single-ip-015 - CreatePage group create-ip-group-015 objectform=IP ip_type=Geography object_name=${objects_name} - #验证新建是否成功 - ui-object-search-name create-ip-group-015 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span - Should Be Equal As Strings ${text} create-ip-group-015 - #删除对象 - objects-delete - ui-object-search-name single-ip-015 - objects-delete -single-FQDN - #新建user-agent - CreatePage single single-FQDN objectform=FQDN keywordtext=$open.node.com - #验证新建是否成功 - ui-object-search-name single-FQDN - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span - Should Be Equal As Strings ${text} single-FQDN - object-edit-fqdn 我的大哥 keywordtext=$open.node.com - #查询修改对象 - ui-object-search-name 我的大哥 - #删除对象 - objects-delete - -group-FQDN - #新建user-agent - CreatePage single single-FQDN objectform=FQDN keywordtext=$open.node.com - ${objects_name} Create List single-FQDN - CreatePage group group-FQDN objectform=FQDN object_name=${objects_name} - #验证新建是否成功 - ui-object-search-name group-FQDN - objects-delete - ui-object-search-name single-FQDN - objects-delete -single-SubscriberID - #新建user-agent - CreatePage single single-SubscriberID objectform=SubscriberID keywordtext=$test37 - #验证新建是否成功 - ui-object-search-name single-SubscriberID - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span - Should Be Equal As Strings ${text} single-SubscriberID - object-edit-Subscriber-ID 我的大哥 keywordtext=$test37 - #查询修改对象 - ui-object-search-name 我的大哥 - #删除对象 - objects-delete - -group-SubscriberID - #新建user-agent - CreatePage single single-SubscriberID objectform=SubscriberID keywordtext=$test37 - ${objects_name} Create List single-SubscriberID - CreatePage group group-SubscriberID objectform=SubscriberID object_name=${objects_name} - #验证新建是否成功 - ui-object-search-name group-SubscriberID - objects-delete - ui-object-search-name single-SubscriberID - objects-delete - -single-HTTPSignature - #新建user-agent - CreatePage single single-HTTPSignature objectform=HTTPSignature reqrestype=req reqresheader=ua keywordtext=Mozilla/5.0* - #验证新建是否成功 - ui-object-search-name single-HTTPSignature - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span - Should Be Equal As Strings ${text} single-HTTPSignature - #修改对象 - object-edit-HTTPSignature 我的大哥 res sck 8f6c 6362 31 36 8fdb 5236 hex=open - #查询修改对象 - ui-object-search-name 我的大哥 - #删除对象 - objects-delete - -group-HTTPSignature - #新建user-agent - CreatePage single single-HTTPSignature objectform=HTTPSignature reqrestype=req reqresheader=ua keywordtext=Mozilla/5.0* - ${objects_name} Create List single-HTTPSignature - CreatePage group group-HTTPSignature objectform=HTTPSignature object_name=${objects_name} - #验证新建是否成功 - ui-object-search-name group-HTTPSignature - objects-delete - ui-object-search-name single-HTTPSignature - objects-delete - - -single-Key - #新建user-agent - CreatePage single single-Key objectform=Key keywordtext=Mozilla/5.0* - #验证新建是否成功 - ui-object-search-name single-Key - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span - Should Be Equal As Strings ${text} single-Key - #修改对象 - object-edit-keywords 我的大哥 $www.baidu.com - #查询修改对象 - ui-object-search-name 我的大哥 - #删除对象 - objects-delete - -group-Key - #新建user-agent - CreatePage single single-Key objectform=Key keywordtext=Mozilla/5.0* - ${objects_name} Create List single-Key - CreatePage group group-Key objectform=Key object_name=${objects_name} - #验证新建是否成功 - ui-object-search-name group-Key - objects-delete - ui-object-search-name single-Key - objects-delete - -single-URL - #新建user-agent - CreatePage single single-URL objectform=URL keywordtext=www.* - #验证新建是否成功 - ui-object-search-name single-URL - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span - Should Be Equal As Strings ${text} single-URL - #修改对象 - object-edit-url 我的大哥 wwsw.* - #查询修改对象 - ui-object-search-name 我的大哥 - #删除对象 - objects-delete - -group-URL - #新建user-agent - CreatePage single single-URL objectform=URL keywordtext=www.* - ${objects_name} Create List single-URL - CreatePage group group-URL objectform=URL object_name=${objects_name} - #验证新建是否成功 - ui-object-search-name group-URL - objects-delete - ui-object-search-name single-URL - objects-delete - - - -single-Category - #新建user-agent - CreatePage single single-Category objectform=Category keywordtext=$www.baidu.com - #验证新建是否成功 - ui-object-search-name single-Category - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span - Should Be Equal As Strings ${text} single-Category - #修改对象 - object-edit-fqdn 我的大哥 $www.baidu.com - #查询修改对象 - ui-object-search-name 我的大哥 - #删除对象 - objects-delete - -group-Category - #新建user-agent - CreatePage single single-Category objectform=Category keywordtext=$www.baidu.com - ${objects_name} Create List single-Category - CreatePage group group-Category objectform=Category object_name=${objects_name} - #验证新建是否成功 - ui-object-search-name group-Category - objects-delete - ui-object-search-name single-Category - objects-delete - - -single-Account - #新建user-agent - CreatePage single single-Account objectform=Account keywordtext=www.* - #验证新建是否成功 - ui-object-search-name single-Account - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span - Should Be Equal As Strings ${text} single-Account - #修改对象 - object-edit-account 我的大哥 waaww.* - #查询修改对象 - ui-object-search-name 我的大哥 - #删除对象 - objects-delete - -group-Account - #新建user-agent - CreatePage single single-Account objectform=Account keywordtext=www.* - ${objects_name} Create List single-Account - CreatePage group group-Account objectform=Account object_name=${objects_name} - #验证新建是否成功 - ui-object-search-name group-Account - objects-delete - ui-object-search-name single-Account - objects-delete - - - - diff --git a/01-TestCase/tsg_ui/ui_objects/Object-HTTPSignature-Case.robot b/01-TestCase/tsg_ui/ui_objects/Object-HTTPSignature-Case.robot index 8995e24..48cc323 100644 --- a/01-TestCase/tsg_ui/ui_objects/Object-HTTPSignature-Case.robot +++ b/01-TestCase/tsg_ui/ui_objects/Object-HTTPSignature-Case.robot @@ -10,7 +10,7 @@ create-http-signature-001 CreatePage HTTPSignature single 656e676c697368636f6e74656e74 reqrestype=res reqresheader=sck keywordtext=656e676c697368636f6e74656e74 hex=open #验证新建是否成功 ui-object-search-name 656e676c697368636f6e74656e74 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} 656e676c697368636f6e74656e74 #删除对象 objects-delete @@ -20,7 +20,7 @@ edit-http-signature-002 CreatePage HTTPSignature single text* reqrestype=res reqresheader=ct keywordtext=text* #验证新建是否成功 ui-object-search-name text* - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} text* object-edit-HTTPSignature text* req ck $mmmm ui-object-search-name text* @@ -32,7 +32,7 @@ create-http-signature-003 CreatePage HTTPSignature single *скрипцияк reqrestype=res reqresheader=ct keywordtext=*скрипцияк #验证新建是否成功 ui-object-search-name *скрипцияк - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} *скрипцияк #删除对象 objects-delete @@ -42,7 +42,7 @@ create-http-signature-004 CreatePage HTTPSignature single $支持中文 reqrestype=res reqresheader=ct keywordtext=$支持中文 #验证新建是否成功 ui-object-search-name $支持中文 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} $支持中文 #删除对象 objects-delete @@ -52,7 +52,7 @@ create-http-signature-005 CreatePage HTTPSignature single 1234@#% reqrestype=res reqresheader=ct keywordtext=1234@#% #验证新建是否成功 ui-object-search-name 1234@#% - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} 1234@#% #删除对象 objects-delete @@ -62,7 +62,7 @@ create-http-signature-006 CreatePage HTTPSignature single text* reqrestype=res reqresheader=ct keywordtext=text* #验证新建是否成功 ui-object-search-name text* - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} text* #删除对象 objects-delete @@ -72,7 +72,7 @@ create-http-signature-007 CreatePage HTTPSignature single *скрипцияк reqrestype=res reqresheader=sck keywordtext=*скрипцияк #验证新建是否成功 ui-object-search-name *скрипцияк - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} *скрипцияк #删除对象 objects-delete @@ -82,7 +82,7 @@ create-http-signature-008 CreatePage HTTPSignature single $支持中文 reqrestype=res reqresheader=sck keywordtext=$支持中文 #验证新建是否成功 ui-object-search-name $支持中文 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} $支持中文 #删除对象 objects-delete @@ -92,7 +92,7 @@ create-http-signature-009 CreatePage HTTPSignature single 1234@#% reqrestype=res reqresheader=sck keywordtext=1234@#% #验证新建是否成功 ui-object-search-name 1234@#% - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} 1234@#% #删除对象 objects-delete @@ -102,7 +102,7 @@ create-http-signature-010 CreatePage HTTPSignature single mmmm* reqrestype=res reqresheader=sck keywordtext=mmmm* #验证新建是否成功 ui-object-search-name mmmm* - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} mmmm* #删除对象 objects-delete @@ -112,7 +112,7 @@ create-http-signature-011 CreatePage HTTPSignature single *скрипцияк reqrestype=req reqresheader=ck keywordtext=*скрипцияк #验证新建是否成功 ui-object-search-name *скрипцияк - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} *скрипцияк #删除对象 objects-delete @@ -122,7 +122,7 @@ create-http-signature-012 CreatePage HTTPSignature single $支持中文 reqrestype=req reqresheader=ck keywordtext=$支持中文 #验证新建是否成功 ui-object-search-name $支持中文 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} $支持中文 #删除对象 objects-delete @@ -132,7 +132,7 @@ create-http-signature-013 CreatePage HTTPSignature single 1234@#% reqrestype=req reqresheader=ck keywordtext=1234@#% #验证新建是否成功 ui-object-search-name 1234@#% - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} 1234@#% #删除对象 objects-delete @@ -142,7 +142,7 @@ create-http-signature-014 CreatePage HTTPSignature single mmmm* reqrestype=req reqresheader=ck keywordtext=mmmm* #验证新建是否成功 ui-object-search-name mmmm* - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} mmmm* #删除对象 objects-delete @@ -152,7 +152,7 @@ create-http-signature-015 CreatePage HTTPSignature single *скрипцияк reqrestype=req reqresheader=ua keywordtext=*скрипцияк #验证新建是否成功 ui-object-search-name *скрипцияк - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} *скрипцияк #删除对象 objects-delete @@ -162,7 +162,7 @@ create-http-signature-016 CreatePage HTTPSignature single $支持中文 reqrestype=req reqresheader=ua keywordtext=$支持中文 #验证新建是否成功 ui-object-search-name $支持中文 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} $支持中文 #删除对象 objects-delete @@ -172,7 +172,7 @@ create-http-signature-017 CreatePage HTTPSignature single 1234@#% reqrestype=req reqresheader=ua keywordtext=1234@#% #验证新建是否成功 ui-object-search-name 1234@#% - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} 1234@#% #删除对象 objects-delete @@ -182,7 +182,7 @@ create-http-signature-018 CreatePage HTTPSignature single mmmm* reqrestype=req reqresheader=ua keywordtext=mmmm* #验证新建是否成功 ui-object-search-name mmmm* - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} mmmm* #删除对象 objects-delete @@ -192,7 +192,7 @@ create-http-signature-019 CreatePage HTTPSignature single w reqrestype=req reqresheader=ua keywordtext=www.* #验证新建是否成功 ui-object-search-name w - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} w #删除对象 objects-delete @@ -202,7 +202,7 @@ create-http-signature-020 CreatePage HTTPSignature single 11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111 reqrestype=req reqresheader=ua keywordtext=www.* #验证新建是否成功 ui-object-search-name 11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} 11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111 #删除对象 objects-delete diff --git a/01-TestCase/tsg_ui/ui_objects/Object_Account_Case.robot b/01-TestCase/tsg_ui/ui_objects/Object_Account_Case.robot index 7d58d43..b60e996 100644 --- a/01-TestCase/tsg_ui/ui_objects/Object_Account_Case.robot +++ b/01-TestCase/tsg_ui/ui_objects/Object_Account_Case.robot @@ -8,14 +8,15 @@ Resource ../../../02-Keyword/tsg_ui/objects/NewObject.robot *** Test Cases *** edit-account-001 #新建Account - CreatePage Account single 0000 keywordtext=0000 + CreatePage Account single 00000 keywordtext=0000 #验证新建是否成功 - ui-object-search-name 0000 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span - Should Be Equal As Strings ${text} 0000 + ui-object-search-name 00000 + sleep 2 + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span + Should Be Equal As Strings ${text} 00000 #修改Account - object-edit-account 0000 $0000 - ui-object-search-name 0000 + object-edit-account 00000 $0000 + ui-object-search-name 00000 #删除对象 objects-delete @@ -24,7 +25,7 @@ create-account-002 CreatePage Account single *скрипцияк keywordtext=*скрипцияк #验证新建是否成功 ui-object-search-name *скрипцияк - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} *скрипцияк #删除对象 objects-delete @@ -34,7 +35,7 @@ create-account-003 CreatePage Account single $支持中文 keywordtext=$支持中文 #验证新建是否成功 ui-object-search-name $支持中文 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} $支持中文 #删除对象 objects-delete @@ -44,7 +45,7 @@ create-account-004 CreatePage Account single 1234@#% keywordtext=1234@#% #验证新建是否成功 ui-object-search-name 1234@#% - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} 1234@#% #删除对象 objects-delete @@ -54,7 +55,7 @@ create-account-005 CreatePage Account single www.* keywordtext=www.* #验证新建是否成功 ui-object-search-name www.* - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} www.* #删除对象 objects-delete @@ -64,7 +65,7 @@ create-account-006 CreatePage Account single w keywordtext=www.* #验证新建是否成功 ui-object-search-name w - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} w #删除对象 objects-delete diff --git a/01-TestCase/tsg_ui/ui_objects/Object_Category_Case.robot b/01-TestCase/tsg_ui/ui_objects/Object_Category_Case.robot index a068ff4..cdddc92 100644 --- a/01-TestCase/tsg_ui/ui_objects/Object_Category_Case.robot +++ b/01-TestCase/tsg_ui/ui_objects/Object_Category_Case.robot @@ -11,7 +11,7 @@ edit-category-001 CreatePage Category single *.com keywordtext=*.com #验证新建是否成功 ui-object-search-name *.com - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} *.com #修改 object-edit-fqdn *.com $ww.jianshu.com @@ -24,7 +24,7 @@ create-category-002 CreatePage Category single *.com keywordtext=*.com #验证新建是否成功 ui-object-search-name *.com - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} *.com #删除对象 objects-delete @@ -34,7 +34,7 @@ create-category-003 CreatePage Category single $www.baidu.com keywordtext=$www.baidu.com #验证新建是否成功 ui-object-search-name $www.baidu.com - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} $www.baidu.com #删除对象 objects-delete @@ -44,7 +44,7 @@ create-category-004 CreatePage Category single *скрипцияк. keywordtext=*www.vision.net #验证新建是否成功 ui-object-search-name *скрипцияк. - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} *скрипцияк. #删除对象 objects-delete @@ -54,7 +54,7 @@ create-category-005 CreatePage Category single $支持中文. keywordtext=$www.vision.com #验证新建是否成功 ui-object-search-name $支持中文. - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} $支持中文. #删除对象 objects-delete @@ -64,7 +64,7 @@ create-category-006 CreatePage Category single w keywordtext=*6n.com #验证新建是否成功 ui-object-search-name w - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} w #删除对象 objects-delete @@ -74,7 +74,7 @@ create-category-007 CreatePage Category single 11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111 keywordtext=*.com #验证新建是否成功 ui-object-search-name 11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} 11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111 #删除对象 objects-delete diff --git a/01-TestCase/tsg_ui/ui_objects/Object_Fqdn_Case.robot b/01-TestCase/tsg_ui/ui_objects/Object_Fqdn_Case.robot index d313c95..09b7d0b 100644 --- a/01-TestCase/tsg_ui/ui_objects/Object_Fqdn_Case.robot +++ b/01-TestCase/tsg_ui/ui_objects/Object_Fqdn_Case.robot @@ -11,7 +11,7 @@ edit-fqdn-001 CreatePage FQDN single *.com keywordtext=*.com #验证新建是否成功 ui-object-search-name *.com - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} *.com #修改 object-edit-fqdn *.com $www.baidu.com @@ -24,7 +24,7 @@ create-fqdn-002 CreatePage FQDN single *.com keywordtext=*.com #验证新建是否成功 ui-object-search-name *.com - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} *.com #删除对象 objects-delete @@ -34,7 +34,7 @@ create-fqdn-003 CreatePage FQDN single *.123-456_abc keywordtext=*.123-456_abc #验证新建是否成功 ui-object-search-name *.123-456_abc - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} *.123-456_abc #删除对象 objects-delete @@ -44,7 +44,7 @@ create-fqdn-004 CreatePage FQDN single $www.baidu.com keywordtext=$www.baidu.com #验证新建是否成功 ui-object-search-name $www.baidu.com - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} $www.baidu.com #删除对象 objects-delete @@ -54,7 +54,7 @@ create-fqdn-005 CreatePage FQDN single $支持中文 keywordtext=$www.baidu.com #验证新建是否成功 ui-object-search-name $支持中文 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} $支持中文 #删除对象 objects-delete @@ -64,7 +64,7 @@ create-fqdn-006 CreatePage FQDN single w keywordtext=*www.baidu.com #验证新建是否成功 ui-object-search-name w - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} w #删除对象 objects-delete @@ -74,7 +74,7 @@ create-fqdn-007 CreatePage FQDN single 11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111 keywordtext=*www.node.cn #验证新建是否成功 ui-object-search-name 11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} 11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111 #删除对象 objects-delete diff --git a/01-TestCase/tsg_ui/ui_objects/Object_Ip_Case.robot b/01-TestCase/tsg_ui/ui_objects/Object_Ip_Case.robot index 92f04ef..c8599f8 100644 --- a/01-TestCase/tsg_ui/ui_objects/Object_Ip_Case.robot +++ b/01-TestCase/tsg_ui/ui_objects/Object_Ip_Case.robot @@ -11,7 +11,7 @@ create-address-ipv4-001 CreatePage IP single 1 ip_type=Ip ipclienttext1=192.168.100.1-192.168.200.1 post=0 #验证新建是否成功 ui-object-search-name 1 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} 1 #删除对象 objects-delete @@ -20,7 +20,7 @@ create-address-ipv4-002 CreatePage IP single create-address-ipv4-002 ip_type=Ip ipclienttext1=192.168.100.1 post=1 #验证新建是否成功 ui-object-search-name create-address-ipv4-002 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} create-address-ipv4-002 #删除对象 objects-delete @@ -29,7 +29,7 @@ create-address-ipv4-003 CreatePage IP single create-address-ipv4-003 ip_type=Ip ipclienttext1=192.168.100.1/0 post=0 #验证新建是否成功 ui-object-search-name create-address-ipv4-003 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} create-address-ipv4-003 #删除对象 objects-delete @@ -38,7 +38,7 @@ create-address-ipv4-004 CreatePage IP single create-address-ipv4-004 ip_type=Ip ipclienttext1=192.168.100.1/32 post=65535 #验证新建是否成功 ui-object-search-name create-address-ipv4-004 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} create-address-ipv4-004 #删除对象 objects-delete @@ -47,7 +47,7 @@ create-address-ipv6-005 CreatePage IP single create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-addres ip_type=Ip ipclienttext1=AAAA::AAAA-FFFF::FFFF post=65535 #验证新建是否成功 ui-object-search-name create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-addres - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-addres #删除对象 objects-delete @@ -56,7 +56,7 @@ create-address-ipv6-006 CreatePage IP single create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-addres ip_type=Ip ipclienttext1=AAAA::AAAA post=65535 #验证新建是否成功 ui-object-search-name create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-addres - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-addres #删除对象 objects-delete @@ -65,7 +65,7 @@ create-address-ipv6-007 CreatePage IP single create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-addres ip_type=Ip ipclienttext1=AAAA::AAAA/0 post=0 #验证新建是否成功 ui-object-search-name create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-addres - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-addres #删除对象 objects-delete @@ -75,7 +75,7 @@ create-address-ipv6-008 CreatePage IP single create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-addres ip_type=Ip ipclienttext1=AAAA::AAAA/128 post=65535 #验证新建是否成功 ui-object-search-name create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-addres - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-address-ipv6-001create-addres #删除对象 objects-delete @@ -86,7 +86,7 @@ create-address-geography-country-009 CreatePage IP single create-address-geography-country-008 ip_type=Geography Country=${Country} #验证新建是否成功 ui-object-search-name create-address-geography-country-008 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} create-address-geography-country-008 #删除对象 objects-delete @@ -97,7 +97,7 @@ create-address-geography-city-010 CreatePage IP single create-address-geography-city-010 ip_type=Geography City=${City} #验证新建是否成功 ui-object-search-name create-address-geography-city-010 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} create-address-geography-city-010 #删除对象 objects-delete @@ -109,7 +109,7 @@ create-address-geography-countryandcity-011 CreatePage IP single create-address-geography-countryandcity-011 ip_type=Geography Country=${Country} City=${City} #验证新建是否成功 ui-object-search-name create-address-geography-countryandcity-011 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} create-address-geography-countryandcity-011 #删除对象 objects-delete @@ -122,7 +122,7 @@ create-addressgroup-ip-012 CreatePage IP group create-addressgroup-ip-012 ip_type=Ip object_name=${objects_name} #验证新建是否成功 ui-object-search-name create-addressgroup-ip-012 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} create-addressgroup-ip-012 #删除对象 objects-delete @@ -139,7 +139,7 @@ create-addressgroup-ip-013 CreatePage IP group create-addressgroup-ip-013 ip_type=Ip object_name=${objects_name} #验证新建是否成功 ui-object-search-name create-addressgroup-ip-013 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} create-addressgroup-ip-013 #删除对象 objects-delete @@ -156,7 +156,7 @@ create-addressgroup-ip-014 CreatePage IP group L ip_type=Ip object_name=${objects_name} #验证新建是否成功 ui-object-search-name L - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} L #删除对象 objects-delete @@ -186,7 +186,7 @@ create-addressgroup-ip-016 CreatePage IP group 中abcДдБб!@#123 ip_type=Ip object_name=${objects_name} #验证新建是否成功 ui-object-search-name 中abcДдБб!@#123 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} 中abcДдБб!@#123 #删除对象 objects-delete @@ -202,7 +202,7 @@ create-addressgroup-geography-017 CreatePage IP group 中abcДдБб!@#123 ip_type=Geography object_name=${objects_name} #验证新建是否成功 ui-object-search-name 中abcДдБб!@#123 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} 中abcДдБб!@#123 #删除对象 objects-delete @@ -222,7 +222,7 @@ create-addressgroup-geography-018 CreatePage IP group 中abcДдБб!@#123 ip_type=Geography object_name=${objects_name} #验证新建是否成功 ui-object-search-name 中abcДдБб!@#123 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} 中abcДдБб!@#123 #删除对象 objects-delete @@ -235,7 +235,7 @@ edit-address-ipv4-019 CreatePage IP single create-address-ipv4-004 ip_type=Ip ipclienttext1=192.168.100.1/32 post=65535 #验证新建是否成功 ui-object-search-name create-address-ipv4-004 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} create-address-ipv4-004 #修改对象 object-edit-ip Edit 192.168.100.100 post=0/100 @@ -250,7 +250,7 @@ edit-address-geography-countryandcity-020 CreatePage IP single create-address-geography-countryandcity-011 ip_type=Geography Country=${Country} City=${City} #验证新建是否成功 ui-object-search-name create-address-geography-countryandcity-011 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} create-address-geography-countryandcity-011 #修改对象 object-edit-Geography edit-address-geography-countryandcity-020 diff --git a/01-TestCase/tsg_ui/ui_objects/Object_Keywords_Case.robot b/01-TestCase/tsg_ui/ui_objects/Object_Keywords_Case.robot index 7868190..e82b34d 100644 --- a/01-TestCase/tsg_ui/ui_objects/Object_Keywords_Case.robot +++ b/01-TestCase/tsg_ui/ui_objects/Object_Keywords_Case.robot @@ -43,7 +43,7 @@ create-keywords-004 CreatePage Key single $支持中文 keywordtext=$支持中文 #验证新建是否成功 ui-object-search-name $支持中文 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} $支持中文 #删除对象 objects-delete @@ -53,7 +53,7 @@ create-keywords-005 CreatePage Key single 1234@#% keywordtext=1234@#% #验证新建是否成功 ui-object-search-name 1234@#% - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} 1234@#% #删除对象 objects-delete @@ -63,7 +63,7 @@ create-keywords-006 CreatePage Key single www.* keywordtext=www.* #验证新建是否成功 ui-object-search-name www.* - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} www.* #删除对象 objects-delete @@ -73,7 +73,7 @@ create-keywords-007 CreatePage Key single w keywordtext=www.* #验证新建是否成功 ui-object-search-name w - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} w #删除对象 objects-delete @@ -83,7 +83,7 @@ create-keywords-008 CreatePage Key single 11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111 keywordtext=www.* #验证新建是否成功 ui-object-search-name 11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} 11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111 #删除对象 objects-delete diff --git a/01-TestCase/tsg_ui/ui_objects/Object_Subscriber_Id_Case.robot b/01-TestCase/tsg_ui/ui_objects/Object_Subscriber_Id_Case.robot index 6c97dfb..6a322ea 100644 --- a/01-TestCase/tsg_ui/ui_objects/Object_Subscriber_Id_Case.robot +++ b/01-TestCase/tsg_ui/ui_objects/Object_Subscriber_Id_Case.robot @@ -11,7 +11,7 @@ edit-subscriber-id-001 CreatePage SubscriberID single $test37 keywordtext=$test37 #验证新建是否成功 ui-object-search-name $test37 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} $test37 #修改 object-edit-Subscriber-ID $test37 $test35 @@ -24,7 +24,7 @@ create-subscriber-id-002 CreatePage SubscriberID single $abc_@%-+123中ДдБб keywordtext=$abc_@%-+123中ДдБб #验证新建是否成功 ui-object-search-name $abc_@%-+123中ДдБб - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} $abc_@%-+123中ДдБб #删除对象 objects-delete @@ -34,7 +34,7 @@ create-subscriber-id-003 CreatePage SubscriberID single $test37 keywordtext=$test37 #验证新建是否成功 ui-object-search-name $test37 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} $test37 #删除对象 objects-delete @@ -44,7 +44,7 @@ create-subscriber-id-004 CreatePage SubscriberID single $支持中文 keywordtext=$www.result.cn #验证新建是否成功 ui-object-search-name $支持中文 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} $支持中文 #删除对象 objects-delete @@ -54,7 +54,7 @@ create-subscriber-id-005 CreatePage SubscriberID single w keywordtext=$www.node.com #验证新建是否成功 ui-object-search-name w - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} w #删除对象 objects-delete @@ -64,7 +64,7 @@ create-subscriber-id-006 CreatePage SubscriberID single 11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111 keywordtext=$www.node.com #验证新建是否成功 ui-object-search-name 11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} 11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111 #删除对象 objects-delete diff --git a/01-TestCase/tsg_ui/ui_objects/Object_Url_Case.robot b/01-TestCase/tsg_ui/ui_objects/Object_Url_Case.robot index 8797fe7..2a5a71e 100644 --- a/01-TestCase/tsg_ui/ui_objects/Object_Url_Case.robot +++ b/01-TestCase/tsg_ui/ui_objects/Object_Url_Case.robot @@ -11,7 +11,7 @@ edit-url-001 CreatePage URL single *.com keywordtext=*.com #验证新建是否成功 ui-object-search-name *.com - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} *.com object-edit-url *.com www.* ui-object-search-name *.com @@ -23,7 +23,7 @@ create-url-002 CreatePage URL single *скрипцияк keywordtext=*скрипцияк #验证新建是否成功 ui-object-search-name *скрипцияк - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} *скрипцияк #删除对象 objects-delete @@ -33,7 +33,7 @@ create-url-003 CreatePage URL single $支持中文 keywordtext=$支持中文 #验证新建是否成功 ui-object-search-name $支持中文 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} $支持中文 #删除对象 objects-delete @@ -43,7 +43,7 @@ create-url-004 CreatePage URL single 1234@#% keywordtext=1234@#% #验证新建是否成功 ui-object-search-name 1234@#% - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} 1234@#% #删除对象 objects-delete @@ -53,7 +53,7 @@ create-url-005 CreatePage URL single www.* keywordtext=www.* #验证新建是否成功 ui-object-search-name www.* - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} www.* #删除对象 objects-delete @@ -63,7 +63,7 @@ create-url-006 CreatePage URL single w keywordtext=www.* #验证新建是否成功 ui-object-search-name w - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} w #删除对象 objects-delete @@ -73,7 +73,7 @@ create-url-007 CreatePage URL single 11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111 keywordtext=www.* #验证新建是否成功 ui-object-search-name 11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111 - ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/span + ${text} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[3]/div/div/div/span Should Be Equal As Strings ${text} 11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111 #删除对象 objects-delete diff --git a/01-TestCase/tsg_ui/ui_settings/Decryption_Keyrings_Case.robot b/01-TestCase/tsg_ui/ui_settings/Decryption_Keyrings_Case.robot index 47dc48b..a288b76 100644 --- a/01-TestCase/tsg_ui/ui_settings/Decryption_Keyrings_Case.robot +++ b/01-TestCase/tsg_ui/ui_settings/Decryption_Keyrings_Case.robot @@ -7,60 +7,94 @@ Library OperatingSystem *** Test Cases *** Create_Decryption_Keyrings-001 Create-Decryption Keyrings lyf-RF-test-001 ${path}keyrings//root//tango-ca-root-01-cer.pem ${path}keyrings//root//tango-ca-root-01-key.pem 23 id=certificateType_select0 id=keyringsadd_publicKeyAlgoSelet1 - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + DeleteKeyrings_del Create_Decryption_Keyrings-002 Create-Decryption Keyrings lyf-RF-test-002 ${path}keyrings//root//tango-ca-root-01-cer.pem ${path}keyrings//root//tango-ca-root-01-key.pem 23 id=certificateType_select0 id=keyringsadd_publicKeyAlgoSelet0 + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + DeleteKeyrings_del Create_Decryption_Keyrings-003 Create-Decryption Keyrings lyf-RF-test-003 ${path}keyrings//root//tango-ca-root-01-cer.pem ${path}keyrings//root//tango-ca-root-01-key.pem 23 id=certificateType_select0 id=keyringsadd_publicKeyAlgoSelet2 + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + DeleteKeyrings_del Create_Decryption_Keyrings-004 Create-Decryption Keyrings lyf-RF-test-004 ${path}keyrings//root//tango-ca-root-01-cer.pem ${path}keyrings//root//tango-ca-root-01-key.pem 23 id=certificateType_select0 id=keyringsadd_publicKeyAlgoSelet3 + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + DeleteKeyrings_del Create_Decryption_Keyrings-005 Create-Decryption Keyrings lyf-RF-test-005 ${path}keyrings//root//tango-ca-root-01-cer.pem ${path}keyrings//root//tango-ca-root-01-key.pem 23 id=certificateType_select0 id=keyringsadd_publicKeyAlgoSelet3 ... open + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + DeleteKeyrings_del Create_Decryption_Keyrings-006 Create-Decryption Keyrings lyf-RF-test-006 ${path}keyrings//Intermediate//tang-ca-v3-intermediate-01-cer.pem ${path}keyrings//Intermediate//tang-ca-v3-intermediate-01-key.pem 23 id=certificateType_select1 id=keyringsadd_publicKeyAlgoSelet3 - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + DeleteKeyrings_del + Create_Decryption_Keyrings-007 Create-Decryption Keyrings lyf-RF-test-006 ${path}keyrings//Intermediate//tang-ca-v3-intermediate-01-cer.pem ${path}keyrings//Intermediate//tang-ca-v3-intermediate-01-key.pem 1 id=certificateType_select1 id=keyringsadd_publicKeyAlgoSelet2 - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + DeleteKeyrings_del + Create_Decryption_Keyrings-008 Create-Decryption Keyrings lyf-RF-test-006 ${path}keyrings//Intermediate//tang-ca-v3-intermediate-01-cer.pem ${path}keyrings//Intermediate//tang-ca-v3-intermediate-01-key.pem 2 id=certificateType_select1 id=keyringsadd_publicKeyAlgoSelet1 - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + DeleteKeyrings_del + Create_Decryption_Keyrings-009 Create-Decryption Keyrings lyf-RF-test-006 ${path}keyrings//Intermediate//tang-ca-v3-intermediate-01-cer.pem ${path}keyrings//Intermediate//tang-ca-v3-intermediate-01-key.pem 2 id=certificateType_select1 id=keyringsadd_publicKeyAlgoSelet0 - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + DeleteKeyrings_del + Create_Decryption_Keyrings-010 Create-Decryption Keyrings lyf-RF-test-006 ${path}keyrings//Intermediate//tang-ca-v3-intermediate-01-cer.pem ${path}keyrings//Intermediate//tang-ca-v3-intermediate-01-key.pem 2 id=certificateType_select1 id=keyringsadd_publicKeyAlgoSelet0 ... open - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + DeleteKeyrings_del + Edit_Decryption_Keyrings-011 Create-Decryption Keyrings lyf-RF-test-006 ${path}keyrings//Intermediate//tang-ca-v3-intermediate-01-cer.pem ${path}keyrings//Intermediate//tang-ca-v3-intermediate-01-key.pem 2 id=certificateType_select1 id=keyringsadd_publicKeyAlgoSelet0 ${id} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[1]/div/div/div/p/span Edit-Decryption Keyrings id=input_list_li1 ${id} lyf-RF-edit-1 ${path}keyrings//root//mesalab-ca-cert.pem ${path}keyrings//root//mesalab-ca-key.pem 1 ... id=certificateType_select0 id=keyringsadd_publicKeyAlgoSelet1 - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + DeleteKeyrings_del + Edit_Decryption_Keyrings-012 Create-Decryption Keyrings lyf-RF-test-006 ${path}keyrings//Intermediate//tang-ca-v3-intermediate-01-cer.pem ${path}keyrings//Intermediate//tang-ca-v3-intermediate-01-key.pem 2 id=certificateType_select1 id=keyringsadd_publicKeyAlgoSelet0 ${name} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span Edit-Decryption Keyrings id=input_list_li2 ${name} lyf-RF-edit-1 ${path}keyrings//root//mesalab-ca-cert.pem ${path}keyrings//root//mesalab-ca-key.pem 1 ... id=certificateType_select0 id=keyringsadd_publicKeyAlgoSelet1 - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + DeleteKeyrings_del + Create_Decryption_Keyrings-013 Create-Decryption Keyrings lyf-RF-test-013 ${path}keyrings//end-entity//tang-ca-v3-www.amazon.cn-cer.pem ${path}keyrings//end-entity//tang-ca-v3-www.amazon.cn-key.pem 23 id=certificateType_select2 id=keyringsadd_publicKeyAlgoSelet0 - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + DeleteKeyrings_del + Create_Decryption_Keyrings-014 Create-Decryption Keyrings lyf-RF-test-014 ${path}keyrings//end-entity//tang-ca-v3-www.amazon.cn-cer.pem ${path}keyrings//end-entity//tang-ca-v3-www.amazon.cn-key.pem 23 id=certificateType_select2 id=keyringsadd_publicKeyAlgoSelet1 - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + DeleteKeyrings_del + Create_Decryption_Keyrings-015 Create-Decryption Keyrings lyf-RF-test-015 ${path}keyrings//end-entity//tang-ca-v3-www.amazon.cn-cer.pem ${path}keyrings//end-entity//tang-ca-v3-www.amazon.cn-key.pem 23 id=certificateType_select2 id=keyringsadd_publicKeyAlgoSelet2 - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + DeleteKeyrings_del + Create_Decryption_Keyrings-016 Create-Decryption Keyrings lyf-RF-test-016 ${path}keyrings//end-entity//tang-ca-v3-www.amazon.cn-cer.pem ${path}keyrings//end-entity//tang-ca-v3-www.amazon.cn-key.pem 23 id=certificateType_select2 id=keyringsadd_publicKeyAlgoSelet3 - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + DeleteKeyrings_del + Create_Decryption_Keyrings-017 Create-Decryption Keyrings lyf-RF-test-017 ${path}keyrings//end-entity//tang-ca-v3-www.amazon.cn-cer.pem ${path}keyrings//end-entity//tang-ca-v3-www.amazon.cn-key.pem 1 id=certificateType_select2 id=keyringsadd_publicKeyAlgoSelet3 ... open + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + DeleteKeyrings_del + \ No newline at end of file diff --git a/01-TestCase/tsg_ui/ui_settings/Decryption_Profile_Case.robot b/01-TestCase/tsg_ui/ui_settings/Decryption_Profile_Case.robot index be48072..85c023d 100644 --- a/01-TestCase/tsg_ui/ui_settings/Decryption_Profile_Case.robot +++ b/01-TestCase/tsg_ui/ui_settings/Decryption_Profile_Case.robot @@ -9,102 +9,133 @@ Create_Decryption_Profile-001 ${dict} Create Dictionary Common Name=1 Issuer=1 Self-signed=1 Expiry Date=1 EV Certificat=1 ... Certificate Transparency=1 Mutual Authentication=1 On Protocol Errors=1 Certificate Pinning=1 Certificate Not Installed=1 Mirror Client Versions=1 ... Allow HTTP/2=1 - Create-Policy_Verify1 lyf-test-1 ${dict} - + Create-Decryption_Profile lyf-test-1 ${dict} + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + Create_Decryption_Profile-002 ${dict} Create Dictionary Common Name=0 Issuer=0 Self-signed=0 Expiry Date=0 EV Certificat=0e ... Certificate Transparency=0 Mutual Authentication=0 On Protocol Errors=0 Certificate Pinning=0 Certificate Not Installed=0 Mirror Client Versions=0 ... Allow HTTP/2=0 - Create-Policy_Verify1 lyf-test-2 ${dict} - + Create-Decryption_Profile lyf-test-2 ${dict} + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + Create_Decryption_Profile-003 ${dict} Create Dictionary Common Name=1 Issuer=1 Self-signed=1 Expiry Date=1 EV Certificat=1 ... Certificate Transparency=1 Mutual Authentication=1 On Protocol Errors=1 Certificate Pinning=1 Certificate Not Installed=1 Mirror Client Versions=1 ... Allow HTTP/2=1 - Create-Policy_Verify1 lyf-test-3 ${dict} fail1=Fail-close - + Create-Decryption_Profile lyf-test-3 ${dict} fail1=Fail-close + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + Create_Decryption_Profile-004 ${dict} Create Dictionary Common Name=1 Issuer=1 Self-signed=1 Expiry Date=1 EV Certificat=1 ... Certificate Transparency=1 Mutual Authentication=1 On Protocol Errors=1 Certificate Pinning=1 Certificate Not Installed=1 Mirror Client Versions=1 ... Allow HTTP/2=1 - Create-Policy_Verify1 lyf-test-3 ${dict} fail1=Pass-through - + Create-Decryption_Profile lyf-test-3 ${dict} fail1=Pass-through + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + Create_Decryption_Profile-005 ${dict} Create Dictionary Common Name=0 Issuer=0 Self-signed=0 Expiry Date=0 EV Certificat=0 ... Certificate Transparency=0 Mutual Authentication=0 On Protocol Errors=0 Certificate Pinning=0 Certificate Not Installed=0 Mirror Client Versions=0 ... Allow HTTP/2=0 - Create-Policy_Verify1 lyf-test-5 ${dict} min1=SSLv3.0 max1=SSLv3.0 - + Create-Decryption_Profile lyf-test-5 ${dict} min1=SSLv3.0 max1=SSLv3.0 + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + Create_Decryption_Profile-006 ${dict} Create Dictionary Common Name=0 Issuer=0 Self-signed=0 Expiry Date=0 EV Certificat=0 ... Certificate Transparency=0 Mutual Authentication=0 On Protocol Errors=0 Certificate Pinning=0 Certificate Not Installed=0 Mirror Client Versions=0 ... Allow HTTP/2=0 - Create-Policy_Verify1 lyf-test-6 ${dict} min1=TLSv1.0 max1=TLSv1.0 - + Create-Decryption_Profile lyf-test-6 ${dict} min1=TLSv1.0 max1=TLSv1.0 + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + Create_Decryption_Profile-007 ${dict} Create Dictionary Common Name=0 Issuer=0 Self-signed=0 Expiry Date=0 EV Certificat=0 ... Certificate Transparency=0 Mutual Authentication=0 On Protocol Errors=0 Certificate Pinning=0 Certificate Not Installed=0 Mirror Client Versions=0 ... Allow HTTP/2=0 - Create-Policy_Verify1 lyf-test-7 ${dict} min1=TLSv1.1 max1=TLSv1.1 - + Create-Decryption_Profile lyf-test-7 ${dict} min1=TLSv1.1 max1=TLSv1.1 + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + Create_Decryption_Profile-008 ${dict} Create Dictionary Common Name=0 Issuer=0 Self-signed=0 Expiry Date=0 EV Certificat=0 ... Certificate Transparency=0 Mutual Authentication=0 On Protocol Errors=0 Certificate Pinning=0 Certificate Not Installed=0 Mirror Client Versions=0 ... Allow HTTP/2=0 - Create-Policy_Verify1 lyf-test-8 ${dict} min1=TLSv1.2 max1=TLSv1.2 - + Create-Decryption_Profile lyf-test-8 ${dict} min1=TLSv1.2 max1=TLSv1.2 + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + Create_Decryption_Profile-009 ${dict} Create Dictionary Common Name=0 Issuer=0 Self-signed=0 Expiry Date=0 EV Certificat=0 ... Certificate Transparency=0 Mutual Authentication=0 On Protocol Errors=0 Certificate Pinning=0 Certificate Not Installed=0 Mirror Client Versions=0 ... Allow HTTP/2=0 - Create-Policy_Verify1 lyf-test-9 ${dict} min1=TLSv1.3 max1=TLSv1.3 - + Create-Decryption_Profile lyf-test-9 ${dict} min1=TLSv1.3 max1=TLSv1.3 + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + Create_Decryption_Profile-010 ${dict} Create Dictionary Common Name=0 Issuer=0 Self-signed=0 Expiry Date=0 EV Certificat=0 ... Certificate Transparency=0 Mutual Authentication=1 On Protocol Errors=1 Certificate Pinning=1 Certificate Not Installed=0 Mirror Client Versions=1 ... Allow HTTP/2=1 - Create-Policy_Verify1 lyf-test-10 ${dict} - + Create-Decryption_Profile lyf-test-10 ${dict} + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + Create_Decryption_Profile-011 ${dict} Create Dictionary Common Name=1 Issuer=1 Self-signed=1 Expiry Date=1 EV Certificat=0 ... Certificate Transparency=0 Mutual Authentication=1 On Protocol Errors=1 Certificate Pinning=1 Certificate Not Installed=0 Mirror Client Versions=1 ... Allow HTTP/2=1 - Create-Policy_Verify1 lyf-test-11 ${dict} fail1=Fail-close - + Create-Decryption_Profile lyf-test-11 ${dict} fail1=Fail-close + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + Create_Decryption_Profile-012 ${dict} Create Dictionary Common Name=1 Issuer=1 Self-signed=1 Expiry Date=1 EV Certificat=0 ... Certificate Transparency=0 Mutual Authentication=1 On Protocol Errors=1 Certificate Pinning=1 Certificate Not Installed=0 Mirror Client Versions=1 ... Allow HTTP/2=1 - Create-Policy_Verify1 lyf-test-12 ${dict} fail1=Pass-through - + Create-Decryption_Profile lyf-test-12 ${dict} fail1=Pass-through + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + Create_Decryption_Profile-013 ${dict} Create Dictionary Common Name=0 Issuer=0 Self-signed=0 Expiry Date=0 EV Certificat=1 ... Certificate Transparency=1 Mutual Authentication=1 On Protocol Errors=1 Certificate Pinning=1 Certificate Not Installed=1 Mirror Client Versions=1 ... Allow HTTP/2=1 - Create-Policy_Verify1 lyf-test-13 ${dict} - + Create-Decryption_Profile lyf-test-13 ${dict} + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + Create_Decryption_Profile-014 ${dict} Create Dictionary Common Name=0 Issuer=0 Self-signed=0 Expiry Date=0 EV Certificat=0 ... Certificate Transparency=0 Mutual Authentication=0 On Protocol Errors=0 Certificate Pinning=0 Certificate Not Installed=0 Mirror Client Versions=1 ... Allow HTTP/2=1 - Create-Policy_Verify1 lyf-test-14 ${dict} - + Create-Decryption_Profile lyf-test-14 ${dict} + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + Create_Decryption_Profile-015 ${dict} Create Dictionary Common Name=0 Issuer=0 Self-signed=0 Expiry Date=0 EV Certificat=0 ... Certificate Transparency=0 Mutual Authentication=0 On Protocol Errors=0 Certificate Pinning=0 Certificate Not Installed=0 Mirror Client Versions=0 ... Allow HTTP/2=1 - Create-Policy_Verify1 lyf-test-15 ${dict} - + Create-Decryption_Profile lyf-test-15 ${dict} + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + Edit_Dercryption_Profile-16 ${dict} Create Dictionary Common Name=1 Issuer=1 Self-signed=1 Expiry Date=1 EV Certificat=1 ... Certificate Transparency=1 Mutual Authentication=1 On Protocol Errors=1 Certificate Pinning=1 Certificate Not Installed=1 Mirror Client Versions=0 ... Allow HTTP/2=0 - Create-Policy_Verify1 lyf-test-16 ${dict} fail1=Pass-through min1=SSLv3.0 max1=SSLv3.0 + Create-Decryption_Profile lyf-test-16 ${dict} fail1=Pass-through min1=SSLv3.0 max1=SSLv3.0 Sleep 1 - ${id} get text xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[2]/div/div[3]/table/tbody/tr[1]/td[1]/div/div/span + ${id} get text xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[1]/div/div/span sleep 1 ${dict1} Create Dictionary Common Name=0 Issuer=0 Self-signed=1 Expiry Date=1 EV Certificat=0 ... Certificate Transparency=0 Mutual Authentication=0 On Protocol Errors=0 Certificate Pinning=0 Certificate Not Installed=0 Mirror Client Versions=0 ... Allow HTTP/2=0 - Edit_Policy_Verify id=input_list_li1 ${id} lyf-edit-test-1 ${dict1} fail1=Fail-close min1=TLSv1.2 + Edit_Decryption Profile id=input_list_li1 ${id} lyf-edit-test-1 ${dict1} fail1=Fail-close min1=TLSv1.2 ... max1=TLSv1.2 + \ No newline at end of file diff --git a/01-TestCase/tsg_ui/ui_settings/Hijack_Files_Case.robot b/01-TestCase/tsg_ui/ui_settings/Hijack_Files_Case.robot index 24763b5..9464a93 100644 --- a/01-TestCase/tsg_ui/ui_settings/Hijack_Files_Case.robot +++ b/01-TestCase/tsg_ui/ui_settings/Hijack_Files_Case.robot @@ -7,42 +7,67 @@ Library OperatingSystem *** Test Cases *** Create_Hijack_Files-001 Create-Hijack Files lyf-test-001-apk ${path}hijack_files/Create-Hijack Files-test.apk id=application/vnd.android.package-archive0 - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[2]/div/span + DeletehijackDel + Create_Hijack_Files-002 Create-Hijack Files lyf-test-002-exe ${path}hijack_files/Create-Hijack Files-test-1.exe id=application/x-msdos-program0 - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[2]/div/span + DeletehijackDel + Create_Hijack_Files-003 Create-Hijack Files lyf-test-003-gif ${path}hijack_files/Create-Hijack Files-test-2.gif id=image/gif0 - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[2]/div/span + DeletehijackDel + Create_Hijack_Files-004 Create-Hijack Files lyf-test-004-html ${path}hijack_files/Create-Hijack Files-test-3.html id=text/html0 - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[2]/div/span + DeletehijackDel + Create_Hijack_Files-005 Create-Hijack Files lyf-test-005-jpeg ${path}hijack_files/Create-Hijack Files-test-4.jpeg id=image/jpeg1 - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[2]/div/span + DeletehijackDel + Create_Hijack_Files-006 Create-Hijack Files lyf-test-006-png ${path}hijack_files/Create-Hijack Files-test-5.png id=image/png2 - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[2]/div/span + DeletehijackDel + Create_Hijack_Files-007 Create-Hijack Files lyf-test-007-svg ${path}hijack_files/Create-Hijack Files-test-6.svg id=image/svg+xml3 - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[2]/div/span + DeletehijackDel + Edit_Hijack_Files-008 Create-Hijack Files lyf-test-001-apk ${path}hijack_files/Create-Hijack Files-test.apk id=application/vnd.android.package-archive0 ${name} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/span Edit-Hijack Files id=input_list_li2 ${name} lyf-Edit-test-001 ${path}hijack_files\\Create-Hijack Files-test.apk id=application/vnd.android.package-archive0 - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[2]/div/span + DeletehijackDel + Edit_Hijack_Files-009 Create-Hijack Files lyf-test-001-apk ${path}hijack_files/Create-Hijack Files-test.apk id=application/vnd.android.package-archive0 ${id} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[1]/div/span Edit-Hijack Files id=input_list_li1 ${id} lyf-Edit-test-002 ${path}hijack_files\\Create-Hijack Files-test.apk id=application/vnd.android.package-archive0 - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[2]/div/span + DeletehijackDel + Edit_Hijack_Files-010 Create-Hijack Files lyf-test-001-apk ${path}hijack_files/Create-Hijack Files-test.apk id=application/vnd.android.package-archive0 ${id} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[1]/div/span Edit-Hijack Files id=input_list_li1 ${id} lyf-Edit-test-003 ${path}hijack_files\\Create-Hijack Files-test.apk id=application/vnd.android.package-archive0 close - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[2]/div/span + DeletehijackDel + Create_Hijack_Files-011 Create-Hijack Files lyf-test-011-svg ${path}hijack_files/Create-Hijack Files-test-6.svg id=image/svg+xml3 close shuru - + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[2]/div/span + DeletehijackDel + Create_Hijack_Files-012 Create-Hijack Files lyf-test-011-svg ${path}hijack_files/Create-Hijack Files-test-6.svg id=image/svg+xml3 open + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1]/td[2]/div/span + DeletehijackDel + \ No newline at end of file diff --git a/01-TestCase/tsg_ui/ui_settings/Insert_Scripts_Case.robot b/01-TestCase/tsg_ui/ui_settings/Insert_Scripts_Case.robot index 14c290a..519792f 100644 --- a/01-TestCase/tsg_ui/ui_settings/Insert_Scripts_Case.robot +++ b/01-TestCase/tsg_ui/ui_settings/Insert_Scripts_Case.robot @@ -8,35 +8,52 @@ Resource ../../../02-Keyword/tsg_ui/setting/Settings.robot Create_Insert_Scripts-001 [Tags] css Create-Insert Scripts lyf-test-001-css ${path}insert_files\\Create-Insert Scripts-test.css xpath=/html/body/div/div[1]/div[1]/ul/li[1] - + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + Create_Insert_Scripts-002 [Tags] js Create-Insert Scripts lyf-test-002-js ${path}insert_files\\Create-Insert_Scripts-test.js xpath=/html/body/div/div[1]/div[1]/ul/li[2] - + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + Create_Insert_Scripts-003 [Tags] css name最小值 Create-Insert Scripts 1 ${path}insert_files\\Create-Insert Scripts-test.css xpath=/html/body/div/div[1]/div[1]/ul/li[1] - + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + Create_Insert_Scripts-004 [Tags] css name传入超过64字符 Create-Insert Scripts Create-Insert Scripts-test.cssCreate-Insert Scripts-test.cssCrea ${path}insert_files\\Create-Insert Scripts-test.css xpath=/html/body/div/div[1]/div[1]/ul/li[1] - + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + Create_Insert_Scripts-005 [Tags] js name最小值 Create-Insert Scripts 1 ${path}insert_files\\Create-Insert_Scripts-test.js xpath=/html/body/div/div[1]/div[1]/ul/li[2] - + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + Create_Insert_Scripts-006 [Tags] js name传入超过64字符 Create-Insert Scripts Create-Insert Scripts-test.cssCreate-Insert Scripts-test.cssCrea ${path}insert_files\\Create-Insert_Scripts-test.js xpath=/html/body/div/div[1]/div[1]/ul/li[2] - + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + Edit_Insert_Scripts-007 [Tags] css edit Create-Insert Scripts lyf-test-001-css ${path}insert_files\\Create-Insert Scripts-test.css xpath=/html/body/div/div[1]/div[1]/ul/li[1] - ${id} get text xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[2]/div/div[3]/table/tbody/tr/td[1]/div/div/span + ${id} get text xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr/td[1]/div/div/span Edit-Insert Scripts id=input_list_li1 ${id} lyf-Edit-test-001 ${path}insert_files\\Create-Insert Scripts-test.css xpath=/html/body/div/div[1]/div[1]/ul/li[1] - + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + Edit_Insert_Scripts-008 [Tags] edit js Create-Insert Scripts 1 ${path}insert_files\\Create-Insert Scripts-test.css xpath=/html/body/div/div[1]/div[1]/ul/li[1] - ${name} get text xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + ${name} get text xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span Edit-Insert Scripts id=input_list_li2 ${name} lyf-Edit-test-008 ${path}insert_files\\Create-Insert_Scripts-test.js xpath=/html/body/div/div[1]/div[1]/ul/li[2] + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + Delete + \ No newline at end of file diff --git a/01-TestCase/tsg_ui/ui_settings/Policy_Verify_Case.robot b/01-TestCase/tsg_ui/ui_settings/Policy_Verify_Case.robot index 376c891..def3eca 100644 --- a/01-TestCase/tsg_ui/ui_settings/Policy_Verify_Case.robot +++ b/01-TestCase/tsg_ui/ui_settings/Policy_Verify_Case.robot @@ -1,9 +1,10 @@ *** Settings *** +Force Tags tsg-ui policy-verify settings Resource ../../../03-Variable/bifangapivariable.txt Resource ../../../02-Keyword/Tsg_Ui/Setting/Settings.robot Library OperatingSystem *** Test Cases *** Policy_Verify-001 - ${dict} Create Dictionary Host=jd.com - Policy_Verify Security Policy Match Protocol-HTTP Client-IP1=192.168.50.30 dict1=${dict} + ${dict} Create Dictionary Host=jd.com + Policy_Verify Security Policy Match Protocol-HTTP Client-IP1=192.168.50.52 dict1=${dict} diff --git a/01-TestCase/tsg_ui/ui_settings/Response_Pages_Case.robot b/01-TestCase/tsg_ui/ui_settings/Response_Pages_Case.robot index 00dadcb..e7ca2f7 100644 --- a/01-TestCase/tsg_ui/ui_settings/Response_Pages_Case.robot +++ b/01-TestCase/tsg_ui/ui_settings/Response_Pages_Case.robot @@ -8,31 +8,45 @@ Resource ../../../02-Keyword/tsg_ui/setting/Settings.robot Create_Response_pages-001 [Tags] html Create-Response Pages Create-Response Pages-001 ${path}response_pages_files\\Create-Response Pages-test.html + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/span + DeleteresinseDel Create_Response_pages-002 [Tags] htm Create-Response Pages Create-Response Pages-001 ${path}response_pages_files\\Create-Response_Pages-test-2.htm + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/span + DeleteresinseDel Create_Response_pages-003 [Tags] name最小值 Create-Response Pages 1 ${path}response_pages_files\\Create-Response_Pages-test-2.htm + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/span + DeleteresinseDel Create_Response_pages-004 [Tags] name超过64字符 Create-Response Pages Create-Insert Scripts-test.cssCreate-Insert Scripts-test.cssCrea ${path}response_pages_files\\Create-Response_Pages-test-2.htm + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/span + DeleteresinseDel Create_Response_pages-005 [Tags] 中英俄特殊字符 Create-Response Pages 中文+absc+моряков+@#¥%……&* ${path}response_pages_files\\Create-Response Pages-test.html + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/span + DeleteresinseDel Edit_Response_pages-006 [Tags] 修改+以id为查找对象 Create-Response Pages Create-Response Pages-001 ${path}response_pages_files\\Create-Response Pages-test.html ${id} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[1]/div/div/span Edit-Response Pages id=input_list_li1 ${id} lyf-Edit-test-001 ${path}response_pages_files\\Create-Response Pages-test-1.html + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/span + DeleteresinseDel Edit_Response_pages-007 [Tags] 修改+以name为查找对象 Create-Response Pages Create-Response Pages-001 ${path}response_pages_files\\Create-Response Pages-test.html ${name} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/span Edit-Response Pages id=input_list_li2 ${name} lyf-Edit-test-007 ${path}response_pages_files\\Create-Response Pages-test-1.html + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/span + DeleteresinseDel diff --git a/01-TestCase/tsg_ui/ui_settings/SSL_Decryption_Exclusion_Case.robot b/01-TestCase/tsg_ui/ui_settings/SSL_Decryption_Exclusion_Case.robot index 1946b44..3d2a501 100644 --- a/01-TestCase/tsg_ui/ui_settings/SSL_Decryption_Exclusion_Case.robot +++ b/01-TestCase/tsg_ui/ui_settings/SSL_Decryption_Exclusion_Case.robot @@ -7,16 +7,24 @@ Library OperatingSystem *** Test Cases *** Create_SSL_Decryption_Exclusion-001 Create-SSL Decryption Exclusion $www.jianshu.com jianshu www.jianshu.com + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + Deletessl_del Create_SSL_Decryption_Exclusion-002 Create-SSL Decryption Exclusion *myssl.com myssl.com myssl.com + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + Deletessl_del Edit_SSL_Decryption_Exclusion-003 Create-SSL Decryption Exclusion *myssl.com myssl.com myssl.com ${id} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[1]/div/div/div/p/span - Edit-SSL Decryption Exclusion id=input_list_li1 ${id} $www.jianshu.com 简书 + Edit-SSL Decryption Exclusion id=input_list_li1 ${id} $www.jianshu.com 简书 www.jianshu.com + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + Deletessl_del Edit_SSL_Decryption_Exclusion-004 Create-SSL Decryption Exclusion *myssl.com myssl.com myssl.com ${id} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[1]/div/div/div/p/span - Edit-SSL Decryption Exclusion id=input_list_li1 ${id} $www.jianshu.com 简xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[1]/div/div/div/p/spanxpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[1]/div/div/div/p/span书 + Edit-SSL Decryption Exclusion id=input_list_li1 ${id} $www.jianshu.com 简xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[1]/div/div/div/p/spanxpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[1]/div/div/div/p/span书 www.jianshu.com + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + Deletessl_del diff --git a/01-TestCase/tsg_ui/ui_settings/Traffic_Mirror_Profiles_Case.robot b/01-TestCase/tsg_ui/ui_settings/Traffic_Mirror_Profiles_Case.robot index cf9de16..2ce51ab 100644 --- a/01-TestCase/tsg_ui/ui_settings/Traffic_Mirror_Profiles_Case.robot +++ b/01-TestCase/tsg_ui/ui_settings/Traffic_Mirror_Profiles_Case.robot @@ -8,23 +8,37 @@ Library OperatingSystem Create_Traffic_Mirror_Profiles-001 [Tags] vlan最小值 Create-Traffic Mirror Profiles lyf-test-004-vlan xpath=/html/body/div/div[1]/div[1]/ul/li[1] 1 + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr/td[2]/div/div/span + DeletetrafficMirrorDel Create_Traffic_Mirror_Profiles-002 [Tags] vlan最大值 Create-Traffic Mirror Profiles lyf-test-002-vlan xpath=/html/body/div/div[1]/div[1]/ul/li[1] 4094 + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr/td[2]/div/div/span + DeletetrafficMirrorDel + Create_Traffic_Mirror_Profiles-003 [Tags] mac Create-Traffic Mirror Profiles lyf-test-003-mac xpath=/html/body/div/div[1]/div[1]/ul/li[2] 11:11:11:11:11:11 + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr/td[2]/div/div/span + DeletetrafficMirrorDel + Edit_Traffic_Mirror_Profiles-004 [Tags] mac Create-Traffic Mirror Profiles lyf-test-003-mac xpath=/html/body/div/div[1]/div[1]/ul/li[2] 11:11:11:11:11:11 ${id} get text xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[2]/div/div[3]/table/tbody/tr/td[1]/div/div/span Edit-Traffic Mirror Profiles id=input_list_li1 ${id} lyf-Edit-test-001 xpath=/html/body/div/div[1]/div[1]/ul/li[2] 11:11:11:11:11:12 + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr/td[2]/div/div/span + DeletetrafficMirrorDel + Edit_Traffic_Mirror_Profiles-005 [Tags] vlan最大值 Create-Traffic Mirror Profiles lyf-test-002-vlan xpath=/html/body/div/div[1]/div[1]/ul/li[1] 4094 ${name} get text xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[2]/div/div[3]/table/tbody/tr/td[2]/div/div/span Edit-Traffic Mirror Profiles id=input_list_li2 ${name} lyf-Edit-test-002 xpath=/html/body/div/div[1]/div[1]/ul/li[1] 11 + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr/td[2]/div/div/span + DeletetrafficMirrorDel + diff --git a/01-TestCase/tsg_ui/ui_settings/Trusted_Certificate_Authorities_Case.robot b/01-TestCase/tsg_ui/ui_settings/Trusted_Certificate_Authorities_Case.robot index 56c6cbc..ff17e10 100644 --- a/01-TestCase/tsg_ui/ui_settings/Trusted_Certificate_Authorities_Case.robot +++ b/01-TestCase/tsg_ui/ui_settings/Trusted_Certificate_Authorities_Case.robot @@ -7,19 +7,29 @@ Library OperatingSystem *** Test Cases *** Create_Trusted_Certificate_Authorities-001 import-Trusted Certificate Authorities lyf-RF-test-001 ${path}keyrings//root//tango-ca-root-01-cer.pem + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + DeleteAuthorities_del Create_Trusted_Certificate_Authorities-002 import-Trusted Certificate Authorities test ${path}keyrings//root//tango-ca-root-01-cer.pem + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + DeleteAuthorities_del Create_Trusted_Certificate_Authorities-003 import-Trusted Certificate Authorities Create-Insert Scripts-test.cssCreate-Insert Scripts-test.cssCreaCreate-Insert Scripts-test.cssCreate-Insert Scripts-test.cssCrea ${path}keyrings//root//tango-ca-root-01-cer.pem + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + DeleteAuthorities_del Edit_Trusted_Certificate_Authorities-004 import-Trusted Certificate Authorities lyf-RF-test-001 ${path}keyrings//root//tango-ca-root-01-cer.pem ${id} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[1]/div/div/div/p/span Edit-Trusted Certificate Authorities id=input_list_li1 ${id} lyf-edit-test-001 ${path}keyrings//root//tango-ca-root-01-cer.pem + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + DeleteAuthorities_del Edit_Trusted_Certificate_Authorities-005 import-Trusted Certificate Authorities lyf-RF-test-001 ${path}keyrings//root//tango-ca-root-01-cer.pem ${name} get text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span Edit-Trusted Certificate Authorities id=input_list_li2 ${name} lyf-edit-test-001 ${path}keyrings//root//tango-ca-root-01-cer.pem + click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span + DeleteAuthorities_del diff --git a/02-Keyword/tsg_bfapi/dashboard_keywords/TrafficStatistics.robot b/02-Keyword/tsg_bfapi/dashboard_keywords/TrafficStatistics.robot new file mode 100644 index 0000000..0cec89b --- /dev/null +++ b/02-Keyword/tsg_bfapi/dashboard_keywords/TrafficStatistics.robot @@ -0,0 +1,284 @@ +*** Settings *** +Test Teardown TeardownDelete ${reportId} ${report_url} ${chartId} ${chart_url} ${datasetId} ${dataset_url} ${resultId} ${result_url} +Force Tags tsg_bf_api chartlibrary_create report +Library OperatingSystem +Resource ../../../03-Variable/BifangApiVariable.txt +Resource ../Common.robot +Resource ../offline_stat_report/ApiRequest1.robot + +Library Collections +Library RequestsLibrary +Library String +Resource ../../../03-Variable/Bifangapivariable.txt +Resource ForTwoKeywords_new.robot +*** Variables *** +${dataset_url} /${version}/report/dataset +${datasetId} ${EMPTY} +${reportId} ${EMPTY} +${report_url} /${version}/report/offlinejob +${chartId} ${EMPTY} +${chart_url} /${version}/report/chart +${result_url} /${version}/report/offlinejob/result +${resultId} ${EMPTY} + +*** Keywords *** +Time-granularity + [Arguments] ${starttime} ${endtime} + ${1} ${4} str2sec ${starttime} + ${2} ${5} str2sec ${endtime} + log ${4} + log ${5} + + ${6} evaluate (int(${5})-int(${4}))*86400 + ${7} evaluate int(${6})+int(${2}) + ${3} evaluate int(${7})-int(${1}) + log ${3} + [Return] ${3} +Dashboard-Traffic-new + # Traffics-带宽统计 统计类型:总:bytes packets sessions bifang和report对比 + [Documentation] + ... 描述:Traffic-Bytes统计 + ... 参数:starttime(必传,开始时间紧) + ... endtime(必传,结束时间 + ... 返回:对比结果 + [Arguments] ${starttime} ${endtime} ${name} + ${data} Set Variable startTime=${startTime}&endTime=${endTime} + ${url1} Set Variable report/traffic/statisticsbyunit + ${bfResponse} ForTwoKeywords_new.Traffic BF Request ${url1} ${data} + ${trafficpackets} Set Variable ${bfResponse['data']['trafficTotalPackets']} + ${trafficbytes} Set Variable ${bfResponse['data']['trafficTotalBytes']} + ${trafficsession} Set Variable ${bfResponse['data']['sessions']} + #新建DataSet + #${name} Set Variable Report_Result-001 + BasePostRequestOK ${dataset_url} {"list":{"name":"${name}","logType":"connection_record_log","filterConnector":"and","havingConnector":"and","groupColumnList":[{"name":"common_recv_time"}],"queryColumnList":[{"name":"common_recv_time","expression":"","label":"Receive Time"},{"name":"common_s2c_pkt_num,common_c2s_pkt_num","expression":"sum","label":"Packets Received+Packets Sent","expressionList":[{"label":"sum","value":"sum"},{"label":"min","value":"min"},{"label":"max","value":"max"},{"label":"avg","value":"avg"},{"label":"count","value":"count"}]},{"name":"common_s2c_byte_num,common_c2s_byte_num","expression":"sum","label":"Bytes Received+Bytes Sent","expressionList":[{"label":"sum","value":"sum"},{"label":"min","value":"min"},{"label":"max","value":"max"},{"label":"avg","value":"avg"},{"label":"count","value":"count"}]},{"name":"common_log_id","expression":"count","label":"sessions","expressionList":[]}],"filterConditionList":[],"havingConditionList":[]}} #根据name查询出该Dataset的id + ${response} BaseGetRequestOK ${dataset_url} pageSize=20&pageNo=1&id=&name=${name}&logType=&opStartTime=&opEndTime=&opUser= + ${datasetId} Set Variable ${response}[data][list][0][id] + #根据DataSet的id,新建Chart,Lien图形表 + BasePostRequestOK ${chart_url} {"list":{"id":null,"name":"${name}","description":"","datasetId":${datasetId},"chartType":"line","dataTop":0,"orderBy":"","orderDesc":0,"drilldownTop":0,"includeOther":false,"timeline":{"dataBinding":"Receive Time","label":"","format":"Time"},"line":[{"dataBinding":"Packets Received+Packets Sent","type":"Line Up","format":"Default","legend":"Packets Received+Packets Sent"},{"dataBinding":"Bytes Received+Bytes Sent","type":"Line Up","format":"Default","legend":"Bytes Received+Bytes Sent"},{"dataBinding":"sessions","type":"Line Up","format":"Default","legend":"sessions"}],"groupBy":null}} + #根据name查询出该Chart的id + ${response1} BaseGetRequestOK ${chart_url} pageSize=20&pageNo=1&id=&name=${name}&opUser= + ${chartId} Set Variable ${response1}[data][list][0][id] + #新建Report,时间计划为Today,图表引用Line。 + BasePostRequestOK ${report_url} {"reportJobList":{"rangeType":"customize","rangeInterval":1,"rangeUnit":"","jobName":"${name}","scheduleId":"","chartList":[{"chartId":${chartId},"timeGranulartiy":5,"timeUnit":"minute","disabled":false}],"isNotice":0,"noticeMethod":"","receivers":[""],"receiver":"","startTime":"${starttime}","endTime":"${endtime}","filterConnector":"and","filterCondition":[]}} + #查询Report的id + ${response1} BaseGetRequestOK ${report_url} pageSize=20&pageNo=1&jobIds=&jobName=${name}&opStartTime=&opEndTime=&opUser=&scheduleId= + ${reportId} Set Variable ${response1}[data][list][0][jobId] + #查询Report结果的状态,并判断状态结果,如果状态是执行成功,查看report结果内容 + FOR ${i} IN RANGE 50 + sleep 10 + #report执行状态查询 + ${response1} BaseGetRequestOK ${result_url} jobId=${reportId} + ${status} Set Variable ${response1}[data][list][0][status] + ${resultId} Set Variable ${response1}[data][list][0][resultId] + run keyword if "${status}"=="0" log non-execution + ... ELSE IF "${status}"=="1" log executing + ... ELSE IF "${status}"=="2" Exit For Loop + ... ELSE log Exec failure + END + #Report报表详情查询 + ${response1} BaseGetRequestOK ${result_url} resultId=${resultId}&jobId=${reportId} + ${startTime1} Set Variable ${response1}[data][list][0][startTime] + ${endTime1} Set Variable ${response1}[data][list][0][endTime] + ${response2} BaseGetRequestOK /v1/report/offlinejob/result/traffic startTime=${startTime1}&endTime=${endTime1} + ${sessions} Set Variable ${response2}[data][list][0][total_new_sessions] + ${bytes} Set Variable ${response2}[data][list][0][total_bytes_transferred] + #${Time-granularity} Time-granularity ${starttime} ${endtime} + ${packets} Set Variable ${response2}[data][list][0][total_packets_transferred] + ${number} evaluate (int(${sessions})-int(${trafficsession}))/int(${sessions}) + ${number1} evaluate (int(${bytes})-int(${trafficbytes}))/int(${bytes}) + ${number2} evaluate (int(${packets})-int(${trafficpackets}))/int(${packets}) + Should Be True ${number}<=${contrast} + Should Be True ${number1}<=${contrast} + Should Be True ${number2}<=${contrast} + [Return] OK + +SessionStatistics-NewLive-new + # dashboard界面新建和活跃连接数统计 bifang和bigData对比 + [Documentation] + ... 描述:Session-NewLive统计(新建和存活的链接数) + ... 参数:starttime(必传,开始时间紧) + ... endtime(必传,结束时间 + ... 返回:对比结果 + [Arguments] ${starttime} ${endtime} + ${data} Set Variable startTime=${startTime}&endTime=${endTime} + ${url1} Set Variable report/traffic/sessions/statisticsbytype + ${bfResponse} trafficBFRequest ${url1} ${data} + ${newCount} Set Variable ${bfResponse['data']['newCount']} + ${liveCount} Set Variable ${bfResponse['data']['liveCount']} + #新建DataSet + #${name} Set Variable Report_Result-001 + BasePostRequestOK ${dataset_url} {"list":{"name":"${name}","logType":"connection_record_log","filterConnector":"and","havingConnector":"and","groupColumnList":[{"name":"common_recv_time"}],"queryColumnList":[{"name":"common_recv_time","expression":"","label":"Receive Time"},{"name":"common_s2c_pkt_num,common_c2s_pkt_num","expression":"sum","label":"Packets Received+Packets Sent","expressionList":[{"label":"sum","value":"sum"},{"label":"min","value":"min"},{"label":"max","value":"max"},{"label":"avg","value":"avg"},{"label":"count","value":"count"}]},{"name":"common_s2c_byte_num,common_c2s_byte_num","expression":"sum","label":"Bytes Received+Bytes Sent","expressionList":[{"label":"sum","value":"sum"},{"label":"min","value":"min"},{"label":"max","value":"max"},{"label":"avg","value":"avg"},{"label":"count","value":"count"}]},{"name":"common_log_id","expression":"count","label":"sessions","expressionList":[]}],"filterConditionList":[],"havingConditionList":[]}} #根据name查询出该Dataset的id + ${response} BaseGetRequestOK ${dataset_url} pageSize=20&pageNo=1&id=&name=${name}&logType=&opStartTime=&opEndTime=&opUser= + ${datasetId} Set Variable ${response}[data][list][0][id] + #根据DataSet的id,新建Chart,Lien图形表 + BasePostRequestOK ${chart_url} {"list":{"id":null,"name":"${name}","description":"","datasetId":${datasetId},"chartType":"line","dataTop":0,"orderBy":"","orderDesc":0,"drilldownTop":0,"includeOther":false,"timeline":{"dataBinding":"Receive Time","label":"","format":"Time"},"line":[{"dataBinding":"Packets Received+Packets Sent","type":"Line Up","format":"Default","legend":"Packets Received+Packets Sent"},{"dataBinding":"Bytes Received+Bytes Sent","type":"Line Up","format":"Default","legend":"Bytes Received+Bytes Sent"},{"dataBinding":"sessions","type":"Line Up","format":"Default","legend":"sessions"}],"groupBy":null}} + #根据name查询出该Chart的id + ${response1} BaseGetRequestOK ${chart_url} pageSize=20&pageNo=1&id=&name=${name}&opUser= + ${chartId} Set Variable ${response1}[data][list][0][id] + #新建Report,时间计划为Today,图表引用Line。 + BasePostRequestOK ${report_url} {"reportJobList":{"rangeType":"customize","rangeInterval":1,"rangeUnit":"","jobName":"${name}","scheduleId":"","chartList":[{"chartId":${chartId},"timeGranulartiy":5,"timeUnit":"minute","disabled":false}],"isNotice":0,"noticeMethod":"","receivers":[""],"receiver":"","startTime":"${starttime}","endTime":"${endtime}","filterConnector":"and","filterCondition":[]}} + #查询Report的id + ${response1} BaseGetRequestOK ${report_url} pageSize=20&pageNo=1&jobIds=&jobName=${name}&opStartTime=&opEndTime=&opUser=&scheduleId= + ${reportId} Set Variable ${response1}[data][list][0][jobId] + #查询Report结果的状态,并判断状态结果,如果状态是执行成功,查看report结果内容 + FOR ${i} IN RANGE 50 + sleep 10 + #report执行状态查询 + ${response1} BaseGetRequestOK ${result_url} jobId=${reportId} + ${status} Set Variable ${response1}[data][list][0][status] + ${resultId} Set Variable ${response1}[data][list][0][resultId] + run keyword if "${status}"=="0" log non-execution + ... ELSE IF "${status}"=="1" log executing + ... ELSE IF "${status}"=="2" Exit For Loop + ... ELSE log Exec failure + END + #Report报表详情查询 + ${response1} BaseGetRequestOK ${result_url} resultId=${resultId}&jobId=${reportId} + log 11111111111111${response1}[data][list][0] + ${startTime1} Set Variable ${response1}[data][list][0][startTime] + ${endTime1} Set Variable ${response1}[data][list][0][endTime] + ${response2} BaseGetRequestOK /v1/report/offlinejob/result/traffic startTime=${startTime1}&endTime=${endTime1} + ${sessions} Set Variable ${response2}[data][list][0][total_new_sessions] + ${bytes} Set Variable ${response2}[data][list][0][average_bytes_per_second] + ${packets} Set Variable ${response2}[data][list][0][average_packets_per_second] + log ${sessions} + [Return] OK + + +Dashboard-Traffic-packets + # Traffics-带宽统计 统计类型:packets bifang和bigData对比 Traffic IN/OUT + [Documentation] + ... 描述:Traffic-packets统计 + ... 参数:starttime(必传,开始时间紧) + ... endtime(必传,结束时间 + ... 返回:对比结果 + [Arguments] ${starttime} ${endtime} + ${data} Set Variable startTime=${startTime}&endTime=${endTime}&statisticsUnit=packets + ${url1} Set Variable report/traffic/statisticsbyunit + ${bfResponse} TrafficBFRequest ${url1} ${data} + ${trafficInPackets} Set Variable ${bfResponse['data']['trafficInPackets']} + ${trafficOutPackets} Set Variable ${bfResponse['data']['trafficOutPackets']} + Create Session bdapi http://${bigDataIP}:${bigDataPort} + ${sql} Set Variable select sum(total_in_packets) as traffic_in_packets, sum(total_out_packets) as traffic_out_packets from traffic_metrics_log where __time >= '${startTime}' and __time < '${endTime}' + ${remoteResponse} Get Request bdapi ?query=${sql} + ${response} to json ${remoteResponse.content} + Should Be Equal As Strings ${remoteResponse.status_code} 200 + Should Be Equal As Strings ${response['status']} 200 + ${traffic_in_packets1} Set Variable ${response['data'][0]['traffic_in_packets']} + ${traffic_out_packets1} Set Variable ${response['data'][0]['traffic_out_packets']} + Should Be True ${trafficInPackets}==${traffic_in_packets1} + Should Be True ${trafficOutPackets}==${traffic_out_packets1} + [Return] OK + +Dashboard-Traffic-sessions + # Traffics-带宽统计 统计类型:sessions bifang和bigData对比 Traffic IN/OUT + [Documentation] + ... 描述:Traffic-sessions统计 + ... 参数:starttime(必传,开始时间紧) + ... endtime(必传,结束时间 + ... 返回:对比结果 + [Arguments] ${starttime} ${endtime} + + ${data} Set Variable startTime=${startTime}&endTime=${endTime}&statisticsUnit=sessions + ${url1} Set Variable report/traffic/statisticsbyunit + ${bfResponse} trafficBFRequest ${url1} ${data} + ${sessions} Set Variable ${bfResponse['data']['sessions']} + Create Session bdapi http://${bigDataIP}:${bigDataPort} + ${sql} Set Variable select sum(new_conn_num) as sessions from traffic_metrics_log where __time >= '${startTime}' and __time < '${endTime}' + ${remoteResponse} Get Request bdapi ?query=${sql} + ${response} to json ${remoteResponse.content} + Should Be Equal As Strings ${remoteResponse.status_code} 200 + Should Be Equal As Strings ${response['status']} 200 + ${sessions1} Set Variable ${response['data'][0]['sessions']} + Should Be True ${sessions}==${sessions1} + [Return] OK + +Dashboard-Traffic-trend-bytes + # Traffics-带宽趋势 统计类型:bytes bifang和bigData对比 Traffic IN/OUT + [Documentation] + ... 描述:Traffic-trend-bytes + ... 参数:starttime(必传,开始时间紧) + ... endtime(必传,结束时间 + ... timeGranularity(非必传,时间粒度 ) + ... limit(非必传,限制条数) + ... 返回:对比结果 + [Arguments] ${starttime} ${endtime} ${timeGranularity} ${limit} + + ${data} Set Variable startTime=${startTime}&endTime=${endTime}&statisticsUnit=bytes&timeGranularity=${timeGranularity}&limit=${limit} + ${url1} Set Variable report/traffic/statisticsbyunit + ${bfResponse} trafficBFRequest ${url1} ${data} + @{bytesOutList1} Set Variable ${bfResponse['data']['trafficOutBytesList']} + @{bytesInList1} Set Variable ${bfResponse['data']['trafficInBytesList']} + Create Session bdapi http://${bigDataIP}:${bigDataPort} + ${sql} Set Variable (select DATE_FORMAT(FROM_UNIXTIME(FLOOR(UNIX_TIMESTAMP(__time)/${timeGranularity})*${timeGranularity}),'%Y-%m-%d %H:%i:%s') as stat_time, 'traffic_in_bytes' as type, sum(total_in_bytes) as bytes from traffic_metrics_log where \ __time >= '${startTime}' \ and __time < '${endTime}' \ group by DATE_FORMAT(FROM_UNIXTIME(FLOOR(UNIX_TIMESTAMP(__time)/${timeGranularity})*${timeGranularity}),'%Y-%m-%d %H:%i:%s') limit ${limit}) union all (select DATE_FORMAT(FROM_UNIXTIME(FLOOR(UNIX_TIMESTAMP(__time)/${timeGranularity})*${timeGranularity}),'%Y-%m-%d %H:%i:%s') as stat_time, 'traffic_out_bytes' as type, sum(total_out_bytes) as bytes from traffic_metrics_log where \ __time >= '${startTime}' and __time < '${endTime}' group by DATE_FORMAT(FROM_UNIXTIME(FLOOR(UNIX_TIMESTAMP(__time)/${timeGranularity})*${timeGranularity}),'%Y-%m-%d %H:%i:%s') limit ${limit}) + ${remoteResponse} Get Request bdapi ?query=${sql} + ${response} to json ${remoteResponse.content} + Should Be Equal As Strings ${remoteResponse.status_code} 200 + Should Be Equal As Strings ${response['status']} 200 + @{bytesList2} Set Variable ${response['data']} + ${typeIn} Set Variable traffic_in_bytes + ${typeOut} Set Variable traffic_out_bytes + ${types} Set Variable bytes + Run Keyword If ${bytesOutList1}!=[] and ${bytesList2}!=[] ForToTrafficTrend ${bytesOutList1} ${typeOut} ${types} ${bytesList2} + Run Keyword If ${bytesInList1}!=[] and ${bytesList2}!=[] ForToTrafficTrend ${bytesInList1} ${typeIn} ${types} ${bytesList2} + +Dashboard-Traffic-trend-packets + # Traffics-带宽趋势 统计类型:packets bifang和bigData对比 Traffic IN/OUT + [Documentation] + ... 描述:Traffic-trend-packets + ... 参数:starttime(必传,开始时间紧) + ... endtime(必传,结束时间 + ... timeGranularity(非必传,时间粒度 ) + ... limit(非必传,限制条数) + ... 返回:对比结果 + [Arguments] ${starttime} ${endtime} ${timeGranularity} ${limit} + + ${data} Set Variable startTime=${startTime}&endTime=${endTime}&statisticsUnit=packets&timeGranularity=${timeGranularity}&limit=${limit} + ${url1} Set Variable report/traffic/statisticsbyunit + ${bfResponse} trafficBFRequest ${url1} ${data} + @{packetsOutList1} Set Variable ${bfResponse['data']['trafficOutPacketsList']} + @{packetsInList1} Set Variable ${bfResponse['data']['trafficInPacketsList']} + Create Session bdapi http://${bigDataIP}:${bigDataPort} + #${sql} Set Variable (select DATE_FORMAT(FROM_UNIXTIME(FLOOR(UNIX_TIMESTAMP(__time)/${timeGranularity})*${timeGranularity}),'%Y-%m-%d %H:%i:%s') as stat_time, 'traffic_in_packets' as type, sum(total_in_packets) as packets from traffic_metrics_log where \ __time >= '${startTime}' and __time < '${endTime}' group by DATE_FORMAT(FROM_UNIXTIME(FLOOR(UNIX_TIMESTAMP(__time)/${timeGranularity})*${timeGranularity}),'%Y-%m-%d %H:%i:%s') union all select DATE_FORMAT(FROM_UNIXTIME(FLOOR(UNIX_TIMESTAMP(__time)/${timeGranularity})*${timeGranularity}),'%Y-%m-%d %H:%i:%s') as stat_time, 'traffic_out_packets' as type, sum(total_out_packets) as packets from traffic_metrics_log where __time >= '${startTime}' and __time < '${endTime}' group by DATE_FORMAT(FROM_UNIXTIME(FLOOR(UNIX_TIMESTAMP(__time)/${timeGranularity})*${timeGranularity}),'%Y-%m-%d %H:%i:%s')) + #${remoteResponse} Get Request bdapi ?query=${sql} + ${sql} Set Variable (select DATE_FORMAT(FROM_UNIXTIME(FLOOR(UNIX_TIMESTAMP(__time)/${timeGranularity})*${timeGranularity}),'%Y-%m-%d %H:%i:%s') as stat_time, 'traffic_in_packets' as type, sum(total_in_packets) as packets from traffic_metrics_log where \ __time >= '${startTime}' and __time < '${endTime}' group by DATE_FORMAT(FROM_UNIXTIME(FLOOR(UNIX_TIMESTAMP(__time)/${timeGranularity})*${timeGranularity}),'%Y-%m-%d %H:%i:%s') limit ${limit}) union all (select DATE_FORMAT(FROM_UNIXTIME(FLOOR(UNIX_TIMESTAMP(__time)/${timeGranularity})*${timeGranularity}),'%Y-%m-%d %H:%i:%s') as stat_time, 'traffic_out_packets' as type, sum(total_out_packets) as packets from traffic_metrics_log where __time >= '${startTime}' and __time < '${endTime}' group by DATE_FORMAT(FROM_UNIXTIME(FLOOR(UNIX_TIMESTAMP(__time)/${timeGranularity})*${timeGranularity}),'%Y-%m-%d %H:%i:%s') limit ${limit}) + ${remoteResponse} Get Request bdapi ?query=${sql} + ${response} to json ${remoteResponse.content} + Should Be Equal As Strings ${remoteResponse.status_code} 200 + Should Be Equal As Strings ${response['status']} 200 + @{packetsList2} Set Variable ${response['data']} + ${typeIn} Set Variable traffic_in_packets + ${typeOut} Set Variable traffic_out_packets + ${types} Set Variable packets + Run Keyword If ${packetsOutList1}!=[] and ${packetsList2}!=[] ForToTrafficTrend ${packetsOutList1} ${typeOut} ${types} ${packetsList2} + Run Keyword If ${packetsInList1}!=[] and ${packetsList2}!=[] ForToTrafficTrend ${packetsInList1} ${typeIn} ${types} ${packetsList2} + +Dashboard-Traffic-trend-sessions + # Traffics-带宽趋势 统计类型:sessions bifang和bigData对比 Traffic IN/OUT + [Documentation] + ... 描述:Traffic-trend-sessions + ... 参数:starttime(必传,开始时间紧) + ... endtime(必传,结束时间 + ... timeGranularity(非必传,时间粒度 ) + ... limit(非必传,限制条数) + [Arguments] ${starttime} ${endtime} ${timeGranularity} ${limit} + ${data} Set Variable startTime=${startTime}&endTime=${endTime}&statisticsUnit=sessions&timeGranularity=${timeGranularity}&limit=${limit} + ${url1} Set Variable report/traffic/statisticsbyunit + ${bfResponse} trafficBFRequest ${url1} ${data} + @{sessionsList1} Set Variable ${bfResponse['data']['sessionsList']} + Create Session bdapi http://${bigDataIP}:${bigDataPort} + #${sql} Set Variable select DATE_FORMAT(FROM_UNIXTIME(FLOOR(UNIX_TIMESTAMP(__time)/${timeGranularity}) *${timeGranularity}),'%Y-%m-%d %H:%i:%s') as stat_time, 'total_conn_num' as type, \ sum(new_conn_num) as sessions from traffic_metrics_log where __time >= \ '${startTime}' and __time < '${endTime}' group by DATE_FORMAT(FROM_UNIXTIME(FLOOR (UNIX_TIMESTAMP(__time)/${timeGranularity})*${timeGranularity}),'%Y-%m-%d %H:%i: %s') + #${remoteResponse} Get Request bdapi ?query=${sql} + ${sql} Set Variable select DATE_FORMAT(FROM_UNIXTIME(FLOOR(UNIX_TIMESTAMP(__time)/${timeGranularity}) *${timeGranularity}),'%Y-%m-%d %H:%i:%s') as stat_time, 'total_conn_num' as type, \ sum(new_conn_num) as sessions from traffic_metrics_log where __time >= \ '${startTime}' and __time < '${endTime}' group by DATE_FORMAT(FROM_UNIXTIME(FLOOR (UNIX_TIMESTAMP(__time)/${timeGranularity})*${timeGranularity}),'%Y-%m-%d %H:%i: %s') limit ${limit} + ${remoteResponse} Get Request bdapi ?query=${sql} + ${response} to json ${remoteResponse.content} + Should Be Equal As Strings ${remoteResponse.status_code} 200 + Should Be Equal As Strings ${response['status']} 200 + @{sessionsList2} Set Variable ${response['data']} + ${type} Set Variable total_conn_num + ${types} Set Variable sessions + Run Keyword If ${sessionsList1}!=[] and ${sessionsList2}!=[] ForToTrafficTrend ${sessionsList1} ${type} ${types} ${sessionsList2} + + + + diff --git a/02-Keyword/tsg_ui/accounts/Accounts.robot b/02-Keyword/tsg_ui/accounts/Accounts.robot index b33cc3f..62800c0 100644 --- a/02-Keyword/tsg_ui/accounts/Accounts.robot +++ b/02-Keyword/tsg_ui/accounts/Accounts.robot @@ -78,7 +78,7 @@ User-Edit Ui-User-Search-Name [Arguments] ${name} sleep 2 - #Wait Until Page Contains Element id=one-input 10 + Wait Until Page Contains Element id=one-input 20 click element id=one-input sleep 2 click element id=input_list_li2 diff --git a/02-Keyword/tsg_ui/mail/Mail.robot b/02-Keyword/tsg_ui/mail/Mail.robot index c57aa05..b2dc451 100644 --- a/02-Keyword/tsg_ui/mail/Mail.robot +++ b/02-Keyword/tsg_ui/mail/Mail.robot @@ -18,7 +18,7 @@ Create-Port Create-Username [Arguments] ${Name} sleep 2 - input text xpath=//*[@id="app"]/div/div[3]/div/div/div/div[2]/form/div[4]/div/div/input ${Name} + input text xpath=//*[@id="app"]/div/div[3]/div/div/div/div[2]/form/div[4]/div/div/div/input ${Name} Create-Account [Arguments] ${Account} diff --git a/02-Keyword/tsg_ui/objects/NewObject.robot b/02-Keyword/tsg_ui/objects/NewObject.robot index 94212e9..f8b6cd2 100644 --- a/02-Keyword/tsg_ui/objects/NewObject.robot +++ b/02-Keyword/tsg_ui/objects/NewObject.robot @@ -8,9 +8,9 @@ CreateButton sleep 3 Click element id=objectCreate run keyword if "${buildType}"=="single" run keywords sleep 2 - ... AND Click element xpath=//*[@id="objectaddress"] + ... AND Click element id=objectaddress ... ELSE IF "${buildType}"=="group" run keywords sleep 2 - ... AND Click element xpath=//*[@id="objectaddress_group"] + ... AND Click element id=objectaddress_group ... ELSE IF log 对象类型有误 CreateButton-groupadd [Arguments] ${buildType} @@ -22,21 +22,21 @@ CreateButton-groupadd SelectObj [Arguments] ${objectform} run keyword if "${objectform}"=="HTTPSignature" run keywords sleep 2 - ... AND Click element xpath=//*[@id="app"]/div/div[3]/div/div/div[1]/div[1]/ul/li[4] + ... AND Click element xpath=//*[@id="app"]/div/div[3]/div/div/div[1]/ul/li[4] ... ELSE IF "${objectform}"=="IP" run keywords sleep 2 - ... AND Click element xpath=//*[@id="app"]/div/div[3]/div/div/div[1]/div[1]/ul/li[1] + ... AND Click element xpath=//*[@id="app"]/div/div[3]/div/div/div[1]/ul/li[1] ... ELSE IF "${objectform}"=="FQDN" run keywords sleep 2 - ... AND Click element xpath=//*[@id="app"]/div/div[3]/div/div/div[1]/div[1]/ul/li[2] + ... AND Click element xpath=//*[@id="app"]/div/div[3]/div/div/div[1]/ul/li[2] ... ELSE IF "${objectform}"=="SubscriberID" run keywords sleep 2 - ... AND Click element xpath=//*[@id="app"]/div/div[3]/div/div/div[1]/div[1]/ul/li[3] + ... AND Click element xpath=//*[@id="app"]/div/div[3]/div/div/div[1]/ul/li[3] ... ELSE IF "${objectform}"=="Key" run keywords sleep 2 - ... AND Click element xpath=//*[@id="app"]/div/div[3]/div/div/div[1]/div[1]/ul/li[5] + ... AND Click element xpath=//*[@id="app"]/div/div[3]/div/div/div[1]/ul/li[5] ... ELSE IF "${objectform}"=="URL" run keywords sleep 2 - ... AND Click element xpath=//*[@id="app"]/div/div[3]/div/div/div[1]/div[1]/ul/li[6] + ... AND Click element xpath=//*[@id="app"]/div/div[3]/div/div/div[1]/ul/li[6] ... ELSE IF "${objectform}"=="Category" run keywords sleep 2 - ... AND Click element xpath=//*[@id="app"]/div/div[3]/div/div/div[1]/div[1]/ul/li[7] + ... AND Click element xpath=//*[@id="app"]/div/div[3]/div/div/div[1]/ul/li[7] ... ELSE IF "${objectform}"=="Account" run keywords sleep 2 - ... AND Click element xpath=//*[@id="app"]/div/div[3]/div/div/div[1]/div[1]/ul/li[8] + ... AND Click element xpath=//*[@id="app"]/div/div[3]/div/div/div[1]/ul/li[8] ... ELSE IF log 对象类型有误 @@ -56,18 +56,19 @@ Create-item # Click element xpath=//*[@id="el-popover-2756"]/div[1]/div[2]/div/div[8]/div - run keyword if "${objectform}"=="IP" and "${ip_type}"=="Ip" run keywords click element xpath=//*[@id="policy_Manipulation2"]/div[2]/div[2]/div/form/div[4]/div/div[1] + run keyword if "${objectform}"=="IP" and "${ip_type}"=="Ip" run keywords click element xpath=//*[@id="policy_Manipulation2"]/div[1]/div[2]/div/form/div[4]/div/div[1] ... AND sleep 1 ... AND Create-ip-ClientIP-text ${ipclienttext1} ${post} - run keyword if "${objectform}"=="IP" and "${ip_type}"=="Geography" run keywords click element xpath=//*[@id="objectAdd_geography"] + run keyword if "${objectform}"=="IP" and "${ip_type}"=="Geography" run keywords click element id=objectAdd_ip1 ... AND sleep 1 - ... AND click element id=objectAddItemAdd + ... AND click element xpath=//*[@id="policy_Manipulation2"]/div[1]/div[2]/div/form/div[4]/div/div[1]/div[2] ... AND sleep 1 + ... AND click element xpath=//*[@id="policy_Manipulation2"]/div[1]/div[2]/div/form/div[4]/div/div[1]/div[1]/div[3] ... AND Create-Geography ${Country} ${City} ... AND sleep 1 ... AND click element id=interceptionadd_allcancelobject ... AND sleep 1 - run keyword if "${objectform}"=="FQDN" or "${objectform}"=="SubscriberID" or "${objectform}"=="URL" or "${objectform}"=="Category" or "${objectform}"=="Account" run keywords click element id=objectAddItemAdd + run keyword if "${objectform}"=="FQDN" or "${objectform}"=="URL" or "${objectform}"=="Category" or "${objectform}"=="Account" run keywords click element id=objectAddItemAdd ... AND sleep 1 ... AND Create-keyword-text ${objectform} ${keywordtext} ... AND sleep 1 @@ -196,7 +197,7 @@ Create-Description input text id=objectAdd_description ${objDesc} Create-ok - sleep 1 + sleep 2 click button id=objectAdd_ok Create-ok-groupadd sleep 1 @@ -297,8 +298,6 @@ Create-keyword-text sleep 1 run keyword if "${type}"=="FQDN" run keywords sleep 1 ... AND input text id=object_fqdn0 ${keywordtext} - ... ELSE IF "${type}"=="SubscriberID" run keywords sleep 1 - ... AND input text id=object_sub0 ${keywordtext} ... ELSE IF "${type}"=="URL" run keywords sleep 1 ... AND input text id=object_url0 ${keywordtext} ... ELSE IF "${type}"=="Category" run keywords sleep 1 @@ -348,19 +347,19 @@ Create-ReqRes-text Create-ReqRes-hexmode [Arguments] ${hex} sleep 1 - run keyword if "${hex}"=="open" click element xpath=//*[@id="policy_Manipulation2"]/div[2]/div[7]/div[1]/div[1]/form/div[4]/div/div + run keyword if "${hex}"=="open" click element xpath=//*[@id="policy_Manipulation2"]/div[1]/div[6]/div[1]/div[1]/form/div/div[4]/div/div/span sleep 1 Create-Key-text [Arguments] ${keywordtext} sleep 1 - input text id=object_key0 ${keywordtext} + input text id=object_url0 ${keywordtext} sleep 1 Create-Key-hexmode [Arguments] ${hex} sleep 1 - run keyword if "${hex}"=="open" click element xpath=//*[@id="objects_httpBodyKeywords1"]/div[1]/div[1]/form/div[2]/div/div + run keyword if "${hex}"=="open" click element xpath=//*[@id="objects_httpBodyKeywords1"]/div[1]/div[1]/form/div/div[2]/div/div/span sleep 1 objects-delete @@ -531,57 +530,58 @@ Cerate-Group run keyword if "${objectform}"=="IP" and "${groupadd}"!="open" run keywords Select-ip_type ${ip_type} ... AND sleep 1 + ... AND click element xpath=//*[@id="policy_Manipulation2"]/div[1]/div[2]/div/form/div[4]/div/div/div[2] ... AND Create-Sub-Objects ${object_name} run keyword if "${objectform}"=="IP" and "${groupadd}"=="open" run keywords Select-ip_type ${ip_type} ... AND sleep 1 ... AND click element xpath=//*[@id="objectAddSubAdd"] ... AND Create-Sub-Objects-groupadd ${buildType} ${groupaddType} ${name} ${objectform} ${groupadd} ${object_name} ${objectform} ${ip_type} ${ipclienttext1} ${keywordtext} ${hex} ${reqrestype} ${reqresheader} ${post} ${Country} ${City} - run keyword if "${objectform}"=="HTTPSignature" and "${groupadd}"!="open" run keywords click element xpath=//*[@id="objectAddSubAdd"] + run keyword if "${objectform}"=="HTTPSignature" and "${groupadd}"!="open" run keywords click element xpath=//*[@id="policy_Manipulation2"]/div[1]/div[2]/div/form/div[3]/div/div/div[2] ... AND sleep 1 ... AND Create-Sub-Objects ${object_name} - run keyword if "${objectform}"=="HTTPSignature" and "${groupadd}"=="open" run keywords click element xpath=//*[@id="objectAddSubAdd"] + run keyword if "${objectform}"=="HTTPSignature" and "${groupadd}"=="open" run keywords click element xpath=//*[@id="policy_Manipulation2"]/div[1]/div[2]/div/form/div[3]/div/div/div[2] ... AND sleep 1 ... AND Create-Sub-Objects-groupadd ${buildType} ${groupaddType} ${name} ${objectform} ${groupadd} ${object_name} ${objectform} ${ip_type} ${ipclienttext1} ${keywordtext} ${hex} ${reqrestype} ${reqresheader} ${post} ${Country} ${City} ... AND sleep 1 - run keyword if "${objectform}"=="FQDN" and "${groupadd}"=="open" run keywords click element xpath=//*[@id="objectAddSubAdd"] + run keyword if "${objectform}"=="FQDN" and "${groupadd}"=="open" run keywords click element xpath=//*[@id="policy_Manipulation2"]/div[1]/div[2]/div/form/div[3]/div/div/div[2] ... AND sleep 1 ... AND Create-Sub-Objects-groupadd ${buildType} ${groupaddType} ${name} ${objectform} ${groupadd} ${object_name} ${objectform} ${ip_type} ${ipclienttext1} ${keywordtext} ${hex} ${reqrestype} ${reqresheader} ${post} ${Country} ${City} ... AND sleep 1 - run keyword if "${objectform}"=="FQDN" and "${groupadd}"!="open" run keywords click element xpath=//*[@id="objectAddSubAdd"] + run keyword if "${objectform}"=="FQDN" and "${groupadd}"!="open" run keywords click element xpath=//*[@id="policy_Manipulation2"]/div[1]/div[2]/div/form/div[3]/div/div/div[2] ... AND sleep 1 ... AND Create-Sub-Objects ${object_name} - run keyword if "${objectform}"=="SubscriberID" and "${groupadd}"!="open" run keywords click element xpath=//*[@id="objectAddSubAdd"] + run keyword if "${objectform}"=="SubscriberID" and "${groupadd}"!="open" run keywords click element xpath=//*[@id="policy_Manipulation2"]/div[1]/div[2]/div/form/div[3]/div/div/div[2] ... AND sleep 1 ... AND Create-Sub-Objects ${object_name} - run keyword if "${objectform}"=="SubscriberID" and "${groupadd}"=="open" run keywords click element xpath=//*[@id="objectAddSubAdd"] + run keyword if "${objectform}"=="SubscriberID" and "${groupadd}"=="open" run keywords click element xpath=//*[@id="policy_Manipulation2"]/div[1]/div[2]/div/form/div[3]/div/div/div[2] ... AND sleep 1 ... AND Create-Sub-Objects-groupadd ${buildType} ${groupaddType} ${name} ${objectform} ${groupadd} ${object_name} ${objectform} ${ip_type} ${ipclienttext1} ${keywordtext} ${hex} ${reqrestype} ${reqresheader} ${post} ${Country} ${City} ... AND sleep 1 - run keyword if "${objectform}"=="Key" and "${groupadd}"!="open" run keywords click element xpath=//*[@id="objectAddSubAdd"] + run keyword if "${objectform}"=="Key" and "${groupadd}"!="open" run keywords click element xpath=//*[@id="policy_Manipulation2"]/div[1]/div[2]/div/form/div[3]/div/div/div[2] ... AND sleep 1 ... AND Create-Sub-Objects ${object_name} - run keyword if "${objectform}"=="Key" and "${groupadd}"=="open" run keywords click element xpath=//*[@id="objectAddSubAdd"] + run keyword if "${objectform}"=="Key" and "${groupadd}"=="open" run keywords click element xpath=//*[@id="policy_Manipulation2"]/div[1]/div[2]/div/form/div[3]/div/div/div[2] ... AND sleep 1 ... AND Create-Sub-Objects-groupadd ${buildType} ${groupaddType} ${name} ${objectform} ${groupadd} ${object_name} ${objectform} ${ip_type} ${ipclienttext1} ${keywordtext} ${hex} ${reqrestype} ${reqresheader} ${post} ${Country} ${City} ... AND sleep 1 - run keyword if "${objectform}"=="URL" and "${groupadd}"!="open" run keywords click element xpath=//*[@id="objectAddSubAdd"] + run keyword if "${objectform}"=="URL" and "${groupadd}"!="open" run keywords click element xpath=//*[@id="policy_Manipulation2"]/div[1]/div[2]/div/form/div[3]/div/div/div[2] ... AND sleep 1 ... AND Create-Sub-Objects ${object_name} - run keyword if "${objectform}"=="URL" and "${groupadd}"=="open" run keywords click element xpath=//*[@id="objectAddSubAdd"] + run keyword if "${objectform}"=="URL" and "${groupadd}"=="open" run keywords click element xpath=//*[@id="policy_Manipulation2"]/div[1]/div[2]/div/form/div[3]/div/div/div[2] ... AND sleep 1 ... AND Create-Sub-Objects-groupadd ${buildType} ${groupaddType} ${name} ${objectform} ${groupadd} ${object_name} ${objectform} ${ip_type} ${ipclienttext1} ${keywordtext} ${hex} ${reqrestype} ${reqresheader} ${post} ${Country} ${City} ... AND sleep 1 - run keyword if "${objectform}"=="Category" and "${groupadd}"!="open" run keywords click element xpath=//*[@id="objectAddSubAdd"] + run keyword if "${objectform}"=="Category" and "${groupadd}"!="open" run keywords click element xpath=//*[@id="policy_Manipulation2"]/div[1]/div[2]/div/form/div[3]/div/div/div[2] ... AND sleep 1 ... AND Create-Sub-Objects ${object_name} - run keyword if "${objectform}"=="Category" and "${groupadd}"=="open" run keywords click element xpath=//*[@id="objectAddSubAdd"] + run keyword if "${objectform}"=="Category" and "${groupadd}"=="open" run keywords click element xpath=//*[@id="policy_Manipulation2"]/div[1]/div[2]/div/form/div[3]/div/div/div[2] ... AND sleep 1 ... AND Create-Sub-Objects-groupadd ${buildType} ${groupaddType} ${name} ${objectform} ${groupadd} ${object_name} ${objectform} ${ip_type} ${ipclienttext1} ${keywordtext} ${hex} ${reqrestype} ${reqresheader} ${post} ${Country} ${City} ... AND sleep 1 - run keyword if "${objectform}"=="Account" and "${groupadd}"!="open" run keywords click element xpath=//*[@id="objectAddSubAdd"] + run keyword if "${objectform}"=="Account" and "${groupadd}"!="open" run keywords click element xpath=//*[@id="policy_Manipulation2"]/div[1]/div[2]/div/form/div[3]/div/div/div[2] ... AND sleep 1 ... AND Create-Sub-Objects ${object_name} - run keyword if "${objectform}"=="Account" and "${groupadd}"=="open" run keywords click element xpath=//*[@id="objectAddSubAdd"] + run keyword if "${objectform}"=="Account" and "${groupadd}"=="open" run keywords click element xpath=//*[@id="policy_Manipulation2"]/div[1]/div[2]/div/form/div[3]/div/div/div[2] ... AND sleep 1 ... AND Create-Sub-Objects-groupadd ${buildType} ${groupaddType} ${name} ${objectform} ${groupadd} ${object_name} ${objectform} ${ip_type} ${ipclienttext1} ${keywordtext} ${hex} ${reqrestype} ${reqresheader} ${post} ${Country} ${City} ... AND sleep 1 @@ -654,11 +654,10 @@ Select-ip_type run keyword if "${ip_type}"=="Ip" sleep 1 run keyword if "${ip_type}"=="Geography" run keywords sleep 1 - ... AND click element xpath=//*[@id="objectAdd_geography"] + ... AND click element id=objectAdd_ip1 ... AND sleep 1 Create-Sub-Objects [Arguments] ${object_name} - click element id=objectAddSubAdd sleep 1 FOR ${i} IN @{object_name} input text id=objectAddSubSearch ${i} @@ -731,9 +730,9 @@ Ui-Pages #sleep 2 #click element xpath=//*[@id="app"]/div/div[3]/div/div/div[10]/div/button[2] #sleep 2 - Clear Element Text xpath=//*[@id="app"]/div/div[3]/div/div/div[10]/div/span[2]/div/input + Clear Element Text xpath=//*[@id="app"]/div/div[3]/div/div/div[12]/div/span[2]/div/input sleep 2 - input text xpath=//*[@id="app"]/div/div[3]/div/div/div[10]/div/span[2]/div/input ${pages} + input text xpath=//*[@id="app"]/div/div[3]/div/div/div[12]/div/span[2]/div/input ${pages} sleep 2 - press keys xpath=//*[@id="app"]/div/div[3]/div/div/div[10]/div/span[2]/div/input ENTER + press keys xpath=//*[@id="app"]/div/div[3]/div/div/div[12]/div/span[2]/div/input ENTER sleep 2 diff --git a/02-Keyword/tsg_ui/setting/Settings.robot b/02-Keyword/tsg_ui/setting/Settings.robot index c497c4b..4698732 100644 --- a/02-Keyword/tsg_ui/setting/Settings.robot +++ b/02-Keyword/tsg_ui/setting/Settings.robot @@ -32,7 +32,7 @@ Create-Hijack Files Sleep 2 input id=hijack_profileName ${name} #输入name Sleep 2 - Choose File xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[2]/form/div[2]/div/div/div[1]/input ${file} #上传文件 + Choose File xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[1]/div[2]/form/div[2]/div/div/div[1]/input ${file} #上传文件 Sleep 2 ${dow_name} Set Variable ${shift} ${input} Set Variable ${input1} @@ -74,11 +74,11 @@ Create-Insert Scripts sleep 1 click id=insertAddOk1 #点击OK Sleep 1 - input xpath=//*[@id="one-input"] ${name} #搜索输入框输入name + input id=one-input ${name} #搜索输入框输入name Sleep 1 - click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[2]/div[2]/i #点击搜索按钮 + click id=select_new_search_btn #点击搜索按钮 Sleep 1 - ${text1} Get Text xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span #获取点击后页面文本信息 + ${text1} Get Text xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span #获取点击后页面文本信息 Should Be Equal As Strings ${text1} ${name} #断言 Create-Traffic Mirror Profiles @@ -94,19 +94,19 @@ Create-Traffic Mirror Profiles Sleep 2 input id=trafficmirror_profileName ${name} #输入name Sleep 2 - click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div/div[2]/form/div[2]/div/div/div[1]/span/span/i #点击下拉框 + click id=addrTypeChoose #点击下拉框 Sleep 2 - click ${type} #选择vlan或者mac + click ${type} #选择vlan或者mac Sleep 1 input id=trafficmirror_addrArray0 ${shuru} sleep 2 - click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[2]/button[1] #点击OK + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/button[1] #点击OK Sleep 2 input id=one-input ${name} #搜索输入框输入name Sleep 1 click id=select_new_search_btn #点击搜索按钮 Sleep 1 - ${text1} Get Text xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[2]/div/div[3]/table/tbody/tr/td[2]/div/div/span #获取点击后页面文本信息 + ${text1} Get Text xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr/td[2]/div/div/span #获取点击后页面文本信息 Should Be Equal As Strings ${text1} ${name} #断言 Edit-Insert Scripts @@ -129,9 +129,9 @@ Edit-Insert Scripts sleep 1 input id=sreach_input ${name} #输入搜索内容 sleep 1 - click xpath=//*[@id="select_new_search_btn"] #点击搜索按钮 + click id=select_new_search_btn #点击搜索按钮 sleep 1 - click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[2]/div/div[3]/table/tbody/tr[1] #点击搜素到的列表 + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1] #点击搜素到的列表 sleep 1 click id=insertEdit #点击Edit sleep 1 @@ -168,9 +168,9 @@ Create-Response Pages Sleep 2 click id=responseAddOk1 #点击OK缇交 Sleep 1 - input xpath=//*[@id="one-input"] ${name} #搜索框输入 + input id=one-input ${name} #搜索框输入 Sleep 1 - click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[2]/i #点击搜索按钮 + click id=select_new_search_btn #点击搜索按钮 Sleep 1 ${text1} Get Text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/span #获取点击后页面文本信息 Should Be Equal As Strings ${text1} ${name} #断言 @@ -203,6 +203,13 @@ Edit-Response Pages Choose File xpath=//*[@id="policy_Manipulation_create6"]/div[2]/form/div[5]/div/div/div/input ${file} sleep 1 click id=responseAddOk1 + Sleep 1 + input id=one-input ${name1} #搜索框输入 + Sleep 1 + click id=select_new_search_btn #点击搜索按钮 + Sleep 1 + ${text1} Get Text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/span #获取点击后页面文本信息 + Should Be Equal As Strings ${text1} ${name1} #断言 Edit-Hijack Files [Arguments] ${id-name} ${name} ${name1} ${file} ${type} ${shift}=1 @@ -225,7 +232,7 @@ Edit-Hijack Files sleep 1 input id=sreach_input ${name} #输入搜索内容 sleep 1 - click xpath=//*[@id="select_new_search_btn"] #点击搜索按钮 + click id=select_new_search_btn #点击搜索按钮 sleep 1 click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr[1] #点击搜素到的列表 sleep 1 @@ -235,7 +242,7 @@ Edit-Hijack Files sleep 1 input id=hijack_profileName ${name1} #输入框输入 sleep 1 - Choose File xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[2]/form/div[5]/div/div/div[1]/input ${file} #上传文件 + Choose File xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[1]/div[2]/form/div[5]/div/div/div[1]/input ${file} #上传文件 sleep 1 ${dow_name} Set Variable ${shift} ${input} Set Variable ${input1} @@ -247,9 +254,16 @@ Edit-Hijack Files sleep 3 click ${type} #选择类型 sleep 1 - click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[3]/div/p/i #关闭侧滑框 + click id=rigth-menu-button-close #关闭侧滑框 sleep 1 click id=hijackAddOk1 #点击ok提交 + Wait Until Element Is Visible id=one-input 20 + input id=one-input ${name1} #搜索输入框输入name + Sleep 1 + click id=select_new_search_btn #点击搜索按钮 + Sleep 1 + ${text1} Get Text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/span #获取点击后页面文本信息 + Should Be Equal As Strings ${text1} ${name1} #断言 Edit-Traffic Mirror Profiles [Arguments] ${id-name} ${name} ${name1} ${type} ${shuju} @@ -271,9 +285,9 @@ Edit-Traffic Mirror Profiles sleep 1 input id=sreach_input ${name} #输入搜索内容 sleep 1 - click xpath=//*[@id="select_new_search_btn"] #点击搜索按钮 + click id=select_new_search_btn #点击搜索按钮 sleep 1 - click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[2]/div/div[3]/table/tbody/tr[1] #点击搜素到的列表 + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1] #点击搜素到的列表 sleep 1 click id=trafficMirrorEdit #点击Edit sleep 1 @@ -281,7 +295,7 @@ Edit-Traffic Mirror Profiles sleep 1 input id=trafficmirror_profileName ${name1} #输入框输入 sleep 1 - click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div/div[2]/form/div[5]/div/div/div[1]/input #点击下拉框 + click id=addrTypeChoose #点击下拉框 sleep 1 click ${type} #选择vlan或者mac sleep 1 @@ -290,6 +304,13 @@ Edit-Traffic Mirror Profiles input id=trafficmirror_addrArray0 ${shuju} #输入内容 sleep 1 click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[2]/button[1] #点击ok + Sleep 2 + input id=one-input ${name1} #搜索输入框输入name + Sleep 1 + click id=select_new_search_btn #点击搜索按钮 + Sleep 1 + ${text1} Get Text xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr/td[2]/div/div/span #获取点击后页面文本信息 + Should Be Equal As Strings ${text1} ${name1} #断言 import-Trusted Certificate Authorities [Arguments] ${name} ${file} @@ -312,7 +333,7 @@ import-Trusted Certificate Authorities Sleep 2 click id=authoritiesAdd_sub #点击OK缇交 Sleep 1 - input xpath=//*[@id="one-input"] ${name} #搜索框输入 + input id=one-input ${name} #搜索框输入 Sleep 1 click id=select_new_search_btn #点击搜索按钮 Sleep 1 @@ -343,28 +364,28 @@ Create-Decryption Keyrings Sleep 2 input id=keyringsadd_name ${name} #输入name Sleep 2 - Choose File xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div/div[2]/form/div[2]/div/div/div/input ${file} #上传文件 + Choose File xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div/div[2]/form/div[2]/div/div/div/input ${file} #上传文件 Sleep 2 - Choose File xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div/div[2]/form/div[4]/div/div/div/input ${file1} #上传文件 + Choose File xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div/div[2]/form/div[4]/div/div/div/input ${file1} #上传文件 ${select} Set Variable ${1or2} Run Keyword If '${select}'=='1' click id=keyringsadd_customized Run Keyword If '${select}'=='1' input id=reissueExpiryDate 10 sleep 1 - click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div/div[2]/form/div[7]/div/div/div[1] #点击下拉框 + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div/div[2]/form/div[7]/div/div/div[1] #点击下拉框 sleep 1 click ${type} #选择证书类型 sleep 1 - click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div/div[2]/form/div[8]/div/div/div[1] #点击下拉框 + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div/div[2]/form/div[8]/div/div/div[1] #点击下拉框 sleep 1 click ${type1} #选择加密解密类型 sleep 1 ${root} Set Variable ${shift} run keyword if "${root}"=="open" run keywords sleep 1 - ... AND click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div/div[2]/form/div[10]/div/div + ... AND click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div/div[2]/form/div[10]/div/div ... ELSE IF "${root}"=="close" log "go on" click id=keyringsadd_sub #点击OK缇交 - Sleep 1 - input xpath=//*[@id="one-input"] ${name} #搜索框输入 + Sleep 2 + input id=one-input ${name} #搜索框输入 Sleep 1 click id=select_new_search_btn #点击搜索按钮 Sleep 1 @@ -393,7 +414,7 @@ Create-SSL Decryption Exclusion Sleep 2 click id=ssl_ok #点击OK缇交 Sleep 1 - input xpath=//*[@id="one-input"] ${name1} #搜索框输入 + input id=one-input ${name1} #搜索框输入 Sleep 1 click id=select_new_search_btn #点击搜索按钮 Sleep 1 @@ -483,25 +504,32 @@ Edit-Decryption Keyrings sleep 1 input id=keyringsadd_name ${name} #输入name sleep 1 - Choose File xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div/div[2]/form/div[5]/div/div/div/input ${file} #上传文件 + Choose File xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div/div[2]/form/div[5]/div/div/div/input ${file} #上传文件 Sleep 2 - Choose File xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div/div[2]/form/div[7]/div/div/div/input ${file1} #上传文件 + Choose File xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div/div[2]/form/div[7]/div/div/div/input ${file1} #上传文件 ${select} Set Variable ${1or2} Run Keyword If '${select}'=='1' click id=keyringsadd_customized Run Keyword If '${select}'=='1' input id=reissueExpiryDate 10 sleep 1 - click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div/div[2]/form/div[10]/div/div/div[1] #点击下拉框 + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div/div[2]/form/div[10]/div/div/div[1] #点击下拉框 sleep 1 click ${type} #选择证书类型 sleep 1 - click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div/div[2]/form/div[11]/div/div/div[1] #点击下拉框 + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div/div[2]/form/div[11]/div/div/div[1] #点击下拉框 sleep 1 click ${type1} #选择加密解密类型 sleep 1 click id=keyringsadd_sub #点击OK缇交 + Sleep 2 + input id=one-input ${name} #搜索框输入 + Sleep 1 + click id=select_new_search_btn #点击搜索按钮 + Sleep 1 + ${text1} Get Text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span #获取点击后页面文本信息 + Should Be Equal As Strings ${text1} ${name} #断言 Edit-SSL Decryption Exclusion - [Arguments] ${id-name} ${value} ${name} ${value1} + [Arguments] ${id-name} ${value} ${name} ${value1} ${name1} [Documentation] 引用关键字,填入必填参数 ... ${id-name}:id或者name的元素 ... ${value}:输入搜索的内容 @@ -531,6 +559,14 @@ Edit-SSL Decryption Exclusion input id=sslAdd_itemDesc ${value1} #输入内容 Sleep 2 click id=ssl_ok #点击OK缇交 + Sleep 2 + input id=one-input ${name1} #搜索框输入 + Sleep 1 + click id=select_new_search_btn #点击搜索按钮 + Sleep 1 + ${text1} Get Text xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[2]/div/div/div/p/span #获取点击后页面文本信息 + Should Be Equal As Strings ${text1} ${name} #断言 + Settings_swarch_name [Arguments] ${name} @@ -680,7 +716,7 @@ Min_max_version ... AND click id=pro_max0 ... ELSE log 错误 -Create-Policy_Verify1 +Create-Decryption_Profile [Arguments] ${name} ${dict1}=null ${fail1}=null ${min1}=null ${max1}=null Sleep 1 click id=children5 #点击一级目录Settings @@ -754,8 +790,10 @@ Create-Policy_Verify1 input id=sreach_input ${name} #输入内容 sleep 1 click id=select_new_search_btn #点击搜索按钮 - ${name1} get text xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + sleep 2 + ${name1} get text xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span Should Be Equal As Strings ${name1} ${name} + Button_Switch [Arguments] ${dict1} ${xpath1} ${xpath2} ${open} ${close} @@ -771,7 +809,7 @@ Button_Switch \ ... AND click xpath=${xpath1}${key}${xpath2}/span \ run keyword if "${class}"=="${close}" and "${dict}[${key}]"=="0" log 默认关闭,不进行操作 -Edit_Policy_Verify +Edit_Decryption Profile [Arguments] ${id-name} ${value} ${name} ${dict1}=null ${fail1}=null ${min1}=null ... ${max1}=null click id=sidebarProxy_Profiles #点击二级目录Proxy Profiles @@ -786,7 +824,7 @@ Edit_Policy_Verify sleep 1 click id=select_new_search_btn #点击搜索按钮 sleep 1 - click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[2]/div/div[3]/table/tbody/tr #点击搜索列表 + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr #点击搜索列表 Sleep 1 click id=insertEdit #点击Edit Sleep 2 @@ -854,16 +892,16 @@ Edit_Policy_Verify input id=sreach_input ${name} #输入内容 sleep 1 click id=select_new_search_btn #点击搜索按钮 - ${name1} get text xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + ${name1} get text xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span Should Be Equal As Strings ${name1} ${name} sleep 1 - click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span + click xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[2]/div/div[3]/table/tbody/tr[1]/td[2]/div/div/span Delete Delete sleep 2 click id=insertDel - sleep 2 + sleep 3 click xpath=/html/body/div/div/div[3]/button[2] sleep 2 @@ -878,240 +916,259 @@ Policy_Verify click id=Proxy_Profiles_Profile_ResponsePages #点击Policy Verify按钮 Sleep 1 ${Select-Test} Set Variable ${Select-Test1} - Run Keyword If "${Select-Test}"=="Security Policy Match" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[1]/div/div/div/span/span/i + Run Keyword If "${Select-Test}"=="Security Policy Match" Run Keywords click id=SelectPolicy ... AND sleep 1 - ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[1] - ... ELSE IF "${Select-Test}"=="Proxy Policy Match" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[1]/div/div/div/span/span/i + ... AND click id=SelectPolicytsg_security0 + ... ELSE IF "${Select-Test}"=="Proxy Policy Match" Run Keywords click id=SelectPolicy ... AND sleep 1 - ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[2] + ... AND click id=SelectPolicypxy_manipulation1 ... ELSE log 错误 ${Address-type} Set Variable ${Address-type1} - Run Keyword If "${Address-type}"=="v4" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[2]/div/div/div/span/span/i + Run Keyword If "${Address-type}"=="v4" Run Keywords click id=ip_addrType ... AND sleep 1 - ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[1] - ... ELSE IF "${Address-type}"=="v6" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[2]/div/div/div/span/span/i + ... AND click id=ip_addrType1 + ... ELSE IF "${Address-type}"=="v6" Run Keywords click id=ip_addrType ... AND sleep 1 - ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[2] + ... AND click id=ip_addrType2 ... ELSE log 错误 ${Client-IP} Set Variable ${Client-IP1} Run Keyword If "${Client-IP}"=="null" log 默认参数,不输入 - ... ELSE input xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[3]/div/div/input ${Client-IP} + ... ELSE input id=clientIp ${Client-IP} sleep 2 ${Client-Port} Set Variable ${Client-Port1} Run Keyword If "${Client-Port}"=="null" log 默认参数,不输入 - ... ELSE input xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[4]/div/div/input ${Client-Port} + ... ELSE input id=clientPort ${Client-Port} sleep 2 ${Server-IP} Set Variable ${Server-IP1} Run Keyword If "${Server-IP}"=="null" log 默认参数,不输入 - ... ELSE input xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[5]/div/div/input ${Server-IP} + ... ELSE input id=serverIp ${Server-IP} sleep 2 ${Server-Port} Set Variable ${Server-Port1} Run Keyword If "${Server-Port}"=="null" log 默认参数,不输入 - ... ELSE input xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[6]/div/div/input ${Server-Port} + ... ELSE input id=ip_serverPort ${Server-Port} sleep 2 ${Protocol} Set Variable ${Protocol1} - Run Keyword If "${Protocol}"=="Any" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[7]/div/div/div/span/span/i + Run Keyword If "${Protocol}"=="Any" Run Keywords click id=ip_protocol ... AND sleep 1 - ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[1] - ... ELSE IF "${Protocol}"=="TCP" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[7]/div/div/div/span/span/i + ... AND click id=ip_protocol0Any + ... ELSE IF "${Protocol}"=="TCP" Run Keywords click id=ip_protocol ... AND sleep 1 - ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[2] - ... ELSE IF "${Protocol}"=="UDP" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[7]/div/div/div/span/span/i + ... AND click id=ip_protocol6TCP + ... ELSE IF "${Protocol}"=="UDP" Run Keywords click id=ip_protocol ... AND sleep 1 - ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[3] + ... AND click id=ip_protocol17UDP sleep 2 ${Subscriber-ID} Set Variable ${Subscriber-ID1} Run Keyword If "${Subscriber-ID}"=="null" log 默认参数,不输入 - ... ELSE input xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[8]/div/div/input ${Subscriber-ID} + ... ELSE input id=SubscriberID ${Subscriber-ID} sleep 2 ${APP-ID} Set Variable ${APP-ID1} - Run Keyword If "${Select-Test}"=="Security Policy Match" and "${APP-ID}"=="Protocol-HTTP" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[9]/div/div/div/span/span/i - ... AND Wait Until Page Contains Element id=Protocol-HTTPhttp 10 + Run Keyword If "${Select-Test}"=="Security Policy Match" and "${APP-ID}"=="Protocol-HTTP" Run Keywords click id=protocol + ... AND sleep 2 ... AND log $$$$$$1111111 ... AND click id=Protocol-HTTPhttp ... AND sleep 2 - ... ELSE IF "${Select-Test}"=="Security Policy Match" and "${APP-ID}"=="Protocol-SSL" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[9]/div/div/div/span/span/i + ... ELSE IF "${Select-Test}"=="Security Policy Match" and "${APP-ID}"=="Protocol-SSL" Run Keywords click id=protocol ... AND sleep 2 - ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[2] - ... ELSE IF "${Select-Test}"=="Security Policy Match" and "${APP-ID}"=="Protocol-DNS" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[9]/div/div/div/span/span/i + ... AND click id=Protocol-SSLssl + ... ELSE IF "${Select-Test}"=="Security Policy Match" and "${APP-ID}"=="Protocol-DNS" Run Keywords click id=protocol ... AND sleep 2 - ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[3] - ... ELSE IF "${Select-Test}"=="Security Policy Match" and "${APP-ID}"=="Protocol-MAIL" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[9]/div/div/div/span/span/i + ... AND click id=Protocol-DNSdns + ... ELSE IF "${Select-Test}"=="Security Policy Match" and "${APP-ID}"=="Protocol-MAIL" Run Keywords click id=protocol ... AND sleep 2 - ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[4] - ... ELSE IF "${Select-Test}"=="Security Policy Match" and "${APP-ID}"=="Protocol-FTP" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[9]/div/div/div/span/span/i + ... AND click id=Protocol-MAILmail + ... ELSE IF "${Select-Test}"=="Security Policy Match" and "${APP-ID}"=="Protocol-FTP" Run Keywords click id=protocol ... AND sleep 2 - ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[5] - ... ELSE IF "${Select-Test}"=="Proxy Policy Match" and "${APP-ID}"=="Protocol-HTTP" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[9]/div/div/div/span/span/i + ... AND click id=Protocol-FTPftp + ... ELSE IF "${Select-Test}"=="Proxy Policy Match" and "${APP-ID}"=="Protocol-HTTP" Run Keywords click id=protocol ... AND sleep 2 - ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li + ... AND click id=Protocol-HTTPhttp + ... ELSE IF "${Select-Test}"=="Proxy Policy Match" and "${APP-ID}"=="Protocol-DoH" Run Keywords click id=protocol + ... AND sleep 2 + ... AND click id=Protocol-DoHDoH ... ELSE log 传入参数错误 ${dict} Set Variable ${dict1} : FOR ${list} ${key} IN ENUMERATE @{dict} - \ run keyword if "${key}"=="URL" and "${APP-ID}"=="Protocol-HTTP" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div/div + \ run keyword if "${key}"=="URL" and "${APP-ID}"=="Protocol-HTTP" Run Keywords click id=selectAppidBTN \ ... AND sleep 1 - \ ... AND click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[1]/div[1]/span/span/i - \ ... AND Wait Until Page Contains Element xpath=/html/body/div/div[1]/div[1]/ul/li[1] 10 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[1] + \ ... AND click id=attributeName + \ ... AND sleep 2 + \ ... AND click id=attributeNameurlURL \ ... AND sleep 1 - \ ... AND input xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[2]/input ${dict}[${key}] + \ ... AND input id=attributeValue_string ${dict}[${key}] \ ... AND sleep 1 - \ run keyword if "${key}"=="Host" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div/div + \ run keyword if "${key}"=="Host" and "${APP-ID}"=="Protocol-HTTP" Run Keywords click id=selectAppidBTN \ ... AND sleep 1 - \ ... AND click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[1]/div[1]/span/span/i - \ ... AND Wait Until Page Contains Element xpath=/html/body/div/div[1]/div[1]/ul/li[2] 10 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[2] + \ ... AND click id=attributeName + \ ... AND sleep 2 + \ ... AND click id=attributeNamehostHost \ ... AND sleep 1 - \ ... AND input xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[2]/input ${dict}[${key}] + \ ... AND input id=attributeValue_string ${dict}[${key}] \ ... AND sleep 1 - \ run keyword if "${key}"=="REQ Body" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div/div + \ run keyword if "${key}"=="REQ Body" Run Keywords click id=selectAppidBTN \ ... AND sleep 1 - \ ... AND click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[1]/div[1]/span/span/i + \ ... AND click id=attributeName \ ... AND sleep 1 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[3] + \ ... AND click id=attributeNamereq_bodyREQ Body \ ... AND sleep 1 - \ ... AND input xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[2]/input ${dict}[${key}] + \ ... AND input id=attributeValue_string ${dict}[${key}] \ ... AND sleep 1 - \ run keyword if "${key}"=="RES Body" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div/div + \ run keyword if "${key}"=="RES Body" Run Keywords click id=selectAppidBTN \ ... AND sleep 1 - \ ... AND click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[1]/div[1]/span/span/i + \ ... AND click id=attributeName \ ... AND sleep 1 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[4] + \ ... AND click id=attributeNameres_bodyRES Body \ ... AND sleep 1 - \ ... AND input xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[2]/input ${dict}[${key}] + \ ... AND input id=attributeValue_string ${dict}[${key}] \ ... AND sleep 1 - \ run keyword if "${key}"=="REQ HDR" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div/div + \ run keyword if "${key}"=="REQ HDR" Run Keywords click id=selectAppidBTN \ ... AND sleep 1 - \ ... AND click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[1]/div[1]/span/span/i + \ ... AND click id=attributeName \ ... AND sleep 1 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[5] + \ ... AND click id=attributeNamereq_hdrREQ HDR \ ... AND sleep 1 \ ... AND Req_Res_Body ${dict}[${key}] \ ... AND sleep 1 - \ run keyword if "${key}"=="RES HDR" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div/div + \ run keyword if "${key}"=="RES HDR" Run Keywords click id=selectAppidBTN \ ... AND sleep 1 - \ ... AND click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[1]/div[1]/span/span/i + \ ... AND click id=attributeName \ ... AND sleep 1 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[6] + \ ... AND click id=attributeNameres_hdrRES HDR \ ... AND sleep 1 \ ... AND Req_Res_Body ${dict}[${key}] \ ... AND sleep 1 - \ run keyword if "${key}"=="SNI" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div/div + \ run keyword if "${key}"=="SNI" Run Keywords click id=selectAppidBTN \ ... AND sleep 1 - \ ... AND click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[1]/div[1]/span/span/i + \ ... AND click id=attributeName \ ... AND sleep 1 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[1] + \ ... AND click id=attributeNamesniSNI \ ... AND sleep 1 - \ ... AND Req_Res_Body ${dict}[${key}] + \ ... AND input id=attributeValue_string ${dict}[${key}] \ ... AND sleep 1 - \ run keyword if "${key}"=="SAN" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div/div + \ run keyword if "${key}"=="SAN" Run Keywords click id=selectAppidBTN \ ... AND sleep 1 - \ ... AND click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[1]/div[1]/span/span/i + \ ... AND click id=attributeName \ ... AND sleep 1 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[2] + \ ... AND click id=attributeNamesanSAN \ ... AND sleep 1 - \ ... AND Req_Res_Body ${dict}[${key}] + \ ... AND input id=attributeValue_string ${dict}[${key}] \ ... AND sleep 1 - \ run keyword if "${key}"=="CN" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div/div + \ run keyword if "${key}"=="CN" Run Keywords click id=selectAppidBTN \ ... AND sleep 1 - \ ... AND click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[1]/div[1]/span/span/i + \ ... AND click id=attributeName \ ... AND sleep 1 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[3] + \ ... AND click id=attributeNamecnCN \ ... AND sleep 1 - \ ... AND Req_Res_Body ${dict}[${key}] + \ ... AND input id=attributeValue_string ${dict}[${key}] \ ... AND sleep 1 - \ run keyword if "${key}"=="QNAME" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div/div + \ run keyword if "${key}"=="QNAME" and "${APP-ID}"=="Protocol-DNS" Run Keywords click id=selectAppidBTN \ ... AND sleep 1 - \ ... AND click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[1]/div[1]/span/span/i + \ ... AND click id=attributeName \ ... AND sleep 1 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[1] + \ ... AND click id=attributeNameqnameQNAME \ ... AND sleep 1 - \ ... AND Req_Res_Body ${dict}[${key}] + \ ... AND input id=attributeValue_string ${dict}[${key}] \ ... AND sleep 1 - \ run keyword if "${key}"=="From" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div/div + \ run keyword if "${key}"=="From" Run Keywords click id=selectAppidBTN \ ... AND sleep 1 - \ ... AND click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[1]/div[1]/span/span/i + \ ... AND click id=attributeName \ ... AND sleep 1 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[1] + \ ... AND click id=attributeNamefromFrom \ ... AND sleep 1 - \ ... AND Req_Res_Body ${dict}[${key}] + \ ... AND input id=attributeValue_string ${dict}[${key}] \ ... AND sleep 1 - \ run keyword if "${key}"=="To" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div/div + \ run keyword if "${key}"=="To" Run Keywords click id=selectAppidBTN \ ... AND sleep 1 - \ ... AND click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[1]/div[1]/span/span/i + \ ... AND click id=attributeName \ ... AND sleep 1 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[2] + \ ... AND click id=attributeNametoTo \ ... AND sleep 1 - \ ... AND Req_Res_Body ${dict}[${key}] + \ ... AND input id=attributeValue_string ${dict}[${key}] \ ... AND sleep 1 - \ run keyword if "${key}"=="Account" and "${APP-ID}"=="Protocol-MAIL" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div/div + \ run keyword if "${key}"=="Account" and "${APP-ID}"=="Protocol-MAIL" Run Keywords click id=selectAppidBTN \ ... AND sleep 1 - \ ... AND click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[1]/div[1]/span/span/i + \ ... AND click id=attributeName \ ... AND sleep 1 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[3] + \ ... AND click id=attributeNameaccountAccount \ ... AND sleep 1 - \ ... AND Req_Res_Body ${dict}[${key}] + \ ... AND input id=attributeValue_string ${dict}[${key}] \ ... AND sleep 1 - \ run keyword if "${key}"=="Subject" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div/div + \ run keyword if "${key}"=="Subject" Run Keywords click id=selectAppidBTN \ ... AND sleep 1 - \ ... AND click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[1]/div[1]/span/span/i + \ ... AND click id=attributeName \ ... AND sleep 1 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[4] + \ ... AND click id=attributeNamesubjectSubject \ ... AND sleep 1 - \ ... AND Req_Res_Body ${dict}[${key}] + \ ... AND input id=attributeValue_string ${dict}[${key}] \ ... AND sleep 1 - \ run keyword if "${key}"=="Content" and "${APP-ID}"=="Protocol-MAIL" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div/div + \ run keyword if "${key}"=="Content" and "${APP-ID}"=="Protocol-MAIL" Run Keywords click id=selectAppidBTN \ ... AND sleep 1 - \ ... AND click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[1]/div[1]/span/span/i + \ ... AND click id=attributeName \ ... AND sleep 1 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[5] + \ ... AND click id=attributeNamecontentContent \ ... AND sleep 1 - \ ... AND Req_Res_Body ${dict}[${key}] + \ ... AND input id=attributeValue_string ${dict}[${key}] \ ... AND sleep 1 - \ run keyword if "${key}"=="ATT Name" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div/div + \ run keyword if "${key}"=="ATT Name" Run Keywords click id=selectAppidBTN \ ... AND sleep 1 - \ ... AND click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[1]/div[1]/span/span/i + \ ... AND click id=attributeName \ ... AND sleep 1 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[6] + \ ... AND click id=attributeNameatt_nameATT Name \ ... AND sleep 1 - \ ... AND Req_Res_Body ${dict}[${key}] + \ ... AND input id=attributeValue_string ${dict}[${key}] \ ... AND sleep 1 - \ run keyword if "${key}"=="ATT CONT" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div/div + \ run keyword if "${key}"=="ATT CONT" Run Keywords click id=selectAppidBTN \ ... AND sleep 1 - \ ... AND click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[1]/div[1]/span/span/i + \ ... AND click id=attributeName \ ... AND sleep 1 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[7] + \ ... AND click id=attributeNameatt_contentATT CONT \ ... AND sleep 1 - \ ... AND Req_Res_Body ${dict}[${key}] + \ ... AND input id=attributeValue_string ${dict}[${key}] \ ... AND sleep 1 - \ run keyword if "${key}"=="URL" and "${APP-ID}"=="Protocol-FTP" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div/div + \ run keyword if "${key}"=="URL" and "${APP-ID}"=="Protocol-FTP" Run Keywords click id=selectAppidBTN \ ... AND sleep 1 - \ ... AND click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[1]/div[1]/span/span/i + \ ... AND click id=attributeName \ ... AND sleep 1 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[1] + \ ... AND click id=attributeNameurlURL \ ... AND sleep 1 - \ ... AND Req_Res_Body ${dict}[${key}] + \ ... AND input id=attributeValue_string ${dict}[${key}] \ ... AND sleep 1 - \ run keyword if "${key}"=="Content" and "${APP-ID}"=="Protocol-FTP" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div/div + \ run keyword if "${key}"=="Content" and "${APP-ID}"=="Protocol-FTP" Run Keywords click id=selectAppidBTN \ ... AND sleep 1 - \ ... AND click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[1]/div[1]/span/span/i + \ ... AND click id=attributeName \ ... AND sleep 1 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[2] + \ ... AND click id=attributeNamecontentContent \ ... AND sleep 1 - \ ... AND Req_Res_Body ${dict}[${key}] + \ ... AND input id=attributeValue_string ${dict}[${key}] \ ... AND sleep 1 - \ run keyword if "${key}"=="Account" and "${APP-ID}"=="Protocol-FTP" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div/div + \ run keyword if "${key}"=="Account" and "${APP-ID}"=="Protocol-FTP" Run Keywords click id=selectAppidBTN \ ... AND sleep 1 - \ ... AND click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[1]/div[1]/span/span/i + \ ... AND click id=attributeName \ ... AND sleep 1 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[3] + \ ... AND click id=attributeNameaccountAccount \ ... AND sleep 1 - \ ... AND Req_Res_Body ${dict}[${key}] + \ ... AND input id=attributeValue_string ${dict}[${key}] + \ ... AND sleep 1 + \ run keyword if "${key}"=="QNAME" and "${APP-ID}"=="Protocol-DoH" Run Keywords click id=selectAppidBTN + \ ... AND sleep 1 + \ ... AND click id=attributeName + \ ... AND sleep 1 + \ ... AND click id=attributeNameqnameQNAME + \ ... AND sleep 1 + \ ... AND input id=attributeValue_string ${dict}[${key}] + \ ... AND sleep 1 + \ run keyword if "${key}"=="Host" and "${APP-ID}"=="Protocol-DoH" Run Keywords click id=selectAppidBTN + \ ... AND sleep 1 + \ ... AND click id=attributeName + \ ... AND sleep 1 + \ ... AND click id=attributeNamehostHost + \ ... AND sleep 1 + \ ... AND input id=attributeValue_string ${dict}[${key}] \ ... AND sleep 1 sleep 2 - click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[3]/button[2] + click id=verify-ok sleep 2 - ${State} get text xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[2]/div/div[2]/div[2]/ul/li[2]/span[3] + ${State} get text xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[1]/div[2]/div/div[2]/div[2]/ul/li[2]/span[3] sleep 2 Should Be Equal As Strings ${State} Execute #断言 @@ -1119,26 +1176,26 @@ Req_Res_Body [Arguments] ${dict1} ${dict} Set Variable ${dict1} : FOR ${list} ${key} IN ENUMERATE @{dict} - \ run keyword if "${key}"=="User Agent" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[2]/div/div[1]/div[1]/span/span/i + \ run keyword if "${key}"=="User Agent" Run Keywords click id=attributeValue_district \ ... AND sleep 1 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[1] + \ ... AND click id=attributeValue_districtUser-AgentUser Agent \ ... AND sleep 1 - \ ... AND input xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[2]/input ${dict}[${key}] - \ run keyword if "${key}"=="Cookie" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[2]/div/div[1]/div[1]/span/span/i + \ ... AND input id=attributeValue_string ${dict}[${key}] + \ run keyword if "${key}"=="Cookie" Run Keywords click id=attributeValue_district \ ... AND sleep 1 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[2] + \ ... AND click id=attributeValue_districtCookieCookie \ ... AND sleep 1 - \ ... AND input xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[2]/input ${dict}[${key}] - \ run keyword if "${key}"=="Set-Cookie" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[2]/div/div[1]/div[1]/span/span/i + \ ... AND input id=attributeValue_string ${dict}[${key}] + \ run keyword if "${key}"=="Set-Cookie" Run Keywords click id=attributeValue_district \ ... AND sleep 1 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[1] + \ ... AND click id=attributeValue_districtSet-CookieSet-Cookie \ ... AND sleep 1 - \ ... AND input xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[2]/input ${dict}[${key}] - \ run keyword if "${key}"=="Content-Type" Run Keywords click xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[2]/div/div[1]/div[1]/span/span/i + \ ... AND input id=attributeValue_string ${dict}[${key}] + \ run keyword if "${key}"=="Content-Type" Run Keywords click id=attributeValue_district \ ... AND sleep 1 - \ ... AND click xpath=/html/body/div/div[1]/div[1]/ul/li[2] + \ ... AND click id=attributeValue_districtContent-TypeContent-Type \ ... AND sleep 1 - \ ... AND input xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[1]/div[1]/div[1]/form/div[10]/div[1]/div/div[2]/input ${dict}[${key}] + \ ... AND input id=attributeValue_string ${dict}[${key}] Create_Ip_Libraries [Arguments] ${type} ${Continent/Country} ${GeoNameID} ${City} ${ip} ${j}=1 ${Country}=null ${Longitude}=null ${Latitude}=null @@ -1253,6 +1310,7 @@ Switch_GeoName click xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[1]/div/div/div sleep 1 Delete_IP_Libraries + [Arguments] ${GeoName} Switch_GeoName ${GeoName} sleep 2 click id=tagDel @@ -1324,15 +1382,15 @@ Pages Ui-Pages [Arguments] ${pages} - click element xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[4]/div/ul/li[1] + click element xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[4]/div/ul/li[1] sleep 2 - click element xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[4]/div/button[2]/i + click element xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[4]/div/button[2]/i sleep 2 - Clear Element Text xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[4]/div/span[2]/div/input + Clear Element Text xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[4]/div/span[2]/div/input sleep 2 - input text xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[4]/div/span[2]/div/input ${pages} + input text xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[4]/div/span[2]/div/input ${pages} sleep 2 - press keys xpath=//*[@id="app"]/div/div[3]/div/div/div[2]/div[4]/div/span[2]/div/input ENTER + press keys xpath=//*[@id="app"]/div/div[3]/div/div/div[3]/div[4]/div/span[2]/div/input ENTER sleep 2 ALL @@ -1340,4 +1398,47 @@ ALL click element xpath=//*[@id="ly-table1-listcontent"]/div/div[3]/table/tbody/tr/td[5]/div/div/div/div/div[2]/div[7] sleep 2 click element xpath=//*[@id="policy_IP_library1"]/div/p/i - sleep 2 \ No newline at end of file + sleep 2 + + +DeleteKeyrings_del + sleep 2 + click id=Keyrings_del + sleep 2 + click xpath=/html/body/div/div/div[3]/button[2] + sleep 2 + +DeletehijackDel + sleep 2 + click id=hijackDel + sleep 2 + click xpath=/html/body/div/div/div[3]/button[2] + sleep 2 + +DeleteresinseDel + sleep 2 + click id=resinseDel + sleep 2 + click xpath=/html/body/div/div/div[3]/button[2] + sleep 2 + +Deletessl_del + sleep 2 + click id=ssl_del + sleep 2 + click xpath=/html/body/div/div/div[3]/button[2] + sleep 2 + +DeletetrafficMirrorDel + sleep 2 + click id=trafficMirrorDel + sleep 2 + click xpath=/html/body/div/div/div[3]/button[2] + sleep 2 + +DeleteAuthorities_del + sleep 2 + click id=Authorities_del + sleep 2 + click xpath=/html/body/div/div/div[3]/button[2] + sleep 2 \ No newline at end of file diff --git a/02-Keyword/tsg_ui/tag/Tags.robot b/02-Keyword/tsg_ui/tag/Tags.robot index 5c9859d..104cbeb 100644 --- a/02-Keyword/tsg_ui/tag/Tags.robot +++ b/02-Keyword/tsg_ui/tag/Tags.robot @@ -84,7 +84,7 @@ ui-tags-search-id ui-tags-search-name [Arguments] ${name} - sleep 1 + sleep 3 click element id=one-input sleep 1 click element id=input_list_li2 @@ -120,7 +120,7 @@ ui-tags-edit-1 input text id=tag_tagName0 ${tag-value} #输入tag内容 sleep 1 sleep 1 - click element id=tagAddInput input text id=tag_tagName1 ${tag-value1} #输入tag内容 + sleep 1 click element id=tagAddOk1 sleep 1 diff --git a/03-Variable/BifangApiVariable.txt b/03-Variable/BifangApiVariable.txt index 896110b..b69a9dc 100644 --- a/03-Variable/BifangApiVariable.txt +++ b/03-Variable/BifangApiVariable.txt @@ -1,64 +1,65 @@ -*** Variables *** -#登录类型:api | cli | ${None}(tsg mib) | 未指定,默认为ui -${loginType} ui -#执行环境是否Widonws -${systemType} api -#API配置信息 -${host} 192.168.40.120 -${port} 8080 -${authmode} 1 -${authCode} ${EMPTY} -${ldapId} 27 -${version} v1 -${version2} v2 -${username} 57_test -${password} 111111 -${encodePassword} ${EMPTY} -${token} ${EMPTY} -#[Documentation] 测试终端IP统一配置 -${testClentIP} 192.168.50.57 -${testSubscriberID} $test57 -#自动化标签 -${userTagIds} ${EMPTY} -#Documentation] 是否添加测试终端IP到策略统一配置,0为不添加测试终端IP,1为添加测试终端IP,默认1 -${addTestClentIPFlag} 1 -#执行需要暂停时间 -#策略下发后到验证需等待时间 -${policyVerificationSleepSeconds} 20 -#策略验证后到验证策略日志需等待时间 -${policyLogVerificationSleepSeconds} 60 -${path} autotsg/05-Other -${currentpath} E:/auto_git/eclipsegit/tsg_autotest/ -${curlbatpath} ${path}/curl/ -${mailpath} ${path}/mail/ -${responsePageFiles} ${path}/response_pages_files/ -#全流程分阶段测试参数 -#[Documentation] 当前测试部分,all为一个终端全网全流程测试, -#1为添加策略和对象测试; -#2为功能端业务验证部分测试; -#3为llog日志验证测试 -${testPart} all -#UI配置的本地IP名称 -${LocahIPName} ${EMPTY} -${ipType} ipv4 -${ipMask} 255.255.255.255 -${browserType} chrome -# Cli自动化测试变量[start] -${cliHost} 192.168.40.165 -${cliUsername} tsgadmin -${cliPassword} Cli2019 -${timeout} 600s -${retryInterval} 300s -@{PolicyTypes} tsg_security pxy_manipulation -@{ObjectTypes} ip url fqdn keywords subscriberid fqdn_category account -... http_signature -# Cli自动化测试变量[end] -# SNMP服务测试变量[start] -${snmpHost} 192.168.40.165 -${snmpPort} 50161 -${snmpConnTimeout} 5 # 默认超时时间为6s,设置timeout值后超时时间为n*6s -${snmpCommunity} public -# SNMP服务测试变量[end] -#API配置信息 -${oamHost} 192.168.40.210 -${oamPort} 50080 +*** Variables *** +#登录类型:api | cli | ${None}(tsg mib) | 未指定,默认为ui +${loginType} api +#执行环境是否Widonws +${systemType} api +#API配置信息 +${host} 192.168.40.120 +${port} 8080 +${authmode} 1 +${authCode} ${EMPTY} +${ldapId} 27 +${version} v1 +${version2} v2 +${username} lyf +${password} 111111 +${encodePassword} ${EMPTY} +${token} ${EMPTY} +#[Documentation] 测试终端IP统一配置 +${testClentIP} 192.168.50.57 +${testSubscriberID} $test57 +#自动化标签 +${userTagIds} ${EMPTY} +#Documentation] 是否添加测试终端IP到策略统一配置,0为不添加测试终端IP,1为添加测试终端IP,默认1 +${addTestClentIPFlag} 0 +#执行需要暂停时间 +#策略下发后到验证需等待时间 +${policyVerificationSleepSeconds} 20 +#策略验证后到验证策略日志需等待时间 +${policyLogVerificationSleepSeconds} 60 +${path} F:/tsg-git/tsg_autotest/05-Other/ +${currentpath} E:/auto_git/eclipsegit/tsg_autotest/ +${curlbatpath} ${path}/curl/ +${mailpath} ${path}/mail/ +${responsePageFiles} ${path}/response_pages_files/ +#全流程分阶段测试参数 +#[Documentation] 当前测试部分,all为一个终端全网全流程测试, +#1为添加策略和对象测试; +#2为功能端业务验证部分测试; +#3为llog日志验证测试 +${testPart} all +#UI配置的本地IP名称 +${LocahIPName} ${EMPTY} +${ipType} ipv4 +${ipMask} 255.255.255.255 +${browserType} chrome +# Cli自动化测试变量[start] +${cliHost} 192.168.40.165 +${cliUsername} tsgadmin +${cliPassword} Cli2019 +${timeout} 600s +${retryInterval} 300s +@{PolicyTypes} tsg_security pxy_manipulation +@{ObjectTypes} ip url fqdn keywords subscriberid fqdn_category account +... http_signature +# Cli自动化测试变量[end] +# SNMP服务测试变量[start] +${snmpHost} 192.168.40.165 +${snmpPort} 50161 +${snmpConnTimeout} 5 # 默认超时时间为6s,设置timeout值后超时时间为n*6s +${snmpCommunity} public +# SNMP服务测试变量[end] +#API配置信息 +${oamHost} 192.168.40.210 +${oamPort} 50080 +${contrast} 0.01 \ No newline at end of file diff --git a/04-CustomLibrary/ExtensionPackages/GetTimeLibrary/GetTime.py b/04-CustomLibrary/ExtensionPackages/GetTimeLibrary/GetTime.py index 6e26711..9a38655 100644 --- a/04-CustomLibrary/ExtensionPackages/GetTimeLibrary/GetTime.py +++ b/04-CustomLibrary/ExtensionPackages/GetTimeLibrary/GetTime.py @@ -51,7 +51,13 @@ class GetTime(): time3 = startTime2[0:-2]+"00" print(time3) return time3 - + def str2sec(self,x): + a, b = x.strip().split(' ') + y, m, d = a.strip().split('-') + + h, m, s = b.strip().split(':') #.split()函数将其通过':'分隔开,.strip()函数用来除去空格 + + return int(h)*3600 + int(m)*60 + int(s),d #int()函数转换成整数运算 diff --git a/04-CustomLibrary/ExtensionPackages/GetTimeLibrary/__init__.py b/04-CustomLibrary/ExtensionPackages/GetTimeLibrary/__init__.py index b666bc5..623321b 100644 --- a/04-CustomLibrary/ExtensionPackages/GetTimeLibrary/__init__.py +++ b/04-CustomLibrary/ExtensionPackages/GetTimeLibrary/__init__.py @@ -1,4 +1,6 @@ #coding=utf-8 -from GetTime import GetTime +from GetTimeLibrary.GetTime import GetTime + +__version__ = '1.0' class GetTimeLibrary(GetTime): ROBOT_LIBRARY_SCOPE = 'GLOBAL' \ No newline at end of file