mirror of
https://github.com/goharbor/harbor.git
synced 2024-11-22 18:25:56 +01:00
Nightly test case <List Helm Charts> is not stable, due to keyword <Go Back To Versions And Delete> failed at delete button click on a rare occasion, so I wrap 2 related action into one transaction, it does help. (#7050)
Signed-off-by: danfengliu <danfengl@vmware.com>
This commit is contained in:
parent
321874c815
commit
62bb10d2e4
@ -46,5 +46,12 @@ Go Back To Versions And Delete
|
||||
Retry Element Click xpath=${version_bread_crumbs}
|
||||
Retry Element Click xpath=${version_checkbox}
|
||||
Retry Element Click xpath=${version_delete}
|
||||
Retry Element Click xpath=${version_confirm_delete}
|
||||
Retry Wait Until Page Contains Element xpath=${helmchart_content}
|
||||
:For ${n} IN RANGE 1 6
|
||||
\ Log To Console Trying Go Back To Versions And Delete ${n} times ...
|
||||
\ Retry Element Click xpath=${version_confirm_delete}
|
||||
\ Capture Page Screenshot
|
||||
\ ${out} Run Keyword And Ignore Error Retry Wait Until Page Contains Element xpath=${helmchart_content}
|
||||
\ Capture Page Screenshot
|
||||
\ Log To Console Return value is ${out[0]}
|
||||
\ Exit For Loop If '${out[0]}'=='PASS'
|
||||
\ Sleep 1
|
||||
|
@ -23,23 +23,21 @@ ${HARBOR_VERSION} v1.1.1
|
||||
Delete Success
|
||||
[Arguments] @{obj}
|
||||
:For ${obj} in @{obj}
|
||||
\ Wait Until Page Contains Element //clr-tab-content//div[contains(.,'${obj}')]/../div/clr-icon[@shape='success-standard']
|
||||
\ Retry Wait Until Page Contains Element //clr-tab-content//div[contains(.,'${obj}')]/../div/clr-icon[@shape='success-standard']
|
||||
Sleep 1
|
||||
Capture Page Screenshot
|
||||
|
||||
Delete Fail
|
||||
[Arguments] @{obj}
|
||||
:For ${obj} in @{obj}
|
||||
\ Wait Until Page Contains Element //clr-tab-content//div[contains(.,'${obj}')]/../div/clr-icon[@shape='error-standard']
|
||||
\ Retry Wait Until Page Contains Element //clr-tab-content//div[contains(.,'${obj}')]/../div/clr-icon[@shape='error-standard']
|
||||
Sleep 1
|
||||
Capture Page Screenshot
|
||||
|
||||
Filter Object
|
||||
#Filter project repo user tag.
|
||||
[Arguments] ${kw}
|
||||
${element}= Set Variable xpath=//hbr-filter//clr-icon
|
||||
Wait Until Element Is Visible And Enabled ${element}
|
||||
Click Element ${element}
|
||||
Retry Element Click xpath=//hbr-filter//clr-icon
|
||||
${element}= Set Variable xpath=//hbr-filter//input
|
||||
Wait Until Element Is Visible And Enabled ${element}
|
||||
Input Text ${element} ${kw}
|
||||
@ -48,9 +46,7 @@ Filter Object
|
||||
Select Object
|
||||
#select single element such as user project repo tag
|
||||
[Arguments] ${obj}
|
||||
${element}= Set Variable xpath=//clr-dg-row[contains(.,'${obj}')]//label
|
||||
Wait Until Element Is Visible And Enabled ${element}
|
||||
Click Element ${element}
|
||||
Retry Element Click xpath=//clr-dg-row[contains(.,'${obj}')]//label
|
||||
|
||||
# This func cannot support as the delete user flow changed.
|
||||
Multi-delete Object
|
||||
@ -58,10 +54,13 @@ Multi-delete Object
|
||||
:For ${obj} in @{obj}
|
||||
\ ${element}= Set Variable xpath=//clr-dg-row[contains(.,'${obj}')]//label
|
||||
\ Retry Element Click ${element}
|
||||
Sleep 1
|
||||
Capture Page Screenshot
|
||||
Retry Element Click ${repo_delete_btn}
|
||||
Sleep 1
|
||||
Capture Page Screenshot
|
||||
Retry Element Click ${repo_delete_on_card_view_btn}
|
||||
Sleep 1
|
||||
Capture Page Screenshot
|
||||
Sleep 1
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user