From 5d76b28a5c9e3c8b866188de8a9c023d5fd51237 Mon Sep 17 00:00:00 2001 From: Mia ZHOU Date: Tue, 7 Aug 2018 10:32:23 +0800 Subject: [PATCH] Fix e2e test after project creation moved to system config (#5536) Fix test project creation for e2e. --- tests/resources/Harbor-Pages/Configuration.robot | 7 +++---- tests/resources/Harbor-Pages/Configuration_Elements.robot | 3 ++- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/tests/resources/Harbor-Pages/Configuration.robot b/tests/resources/Harbor-Pages/Configuration.robot index eb38d65a2..432e03976 100644 --- a/tests/resources/Harbor-Pages/Configuration.robot +++ b/tests/resources/Harbor-Pages/Configuration.robot @@ -93,7 +93,7 @@ Ldap Verify Cert Checkbox Should Be Disabled Set Pro Create Admin Only #set limit to admin only Sleep 2 - Click Element xpath=${configuration_xpath} + Click Element xpath=${system_config_xpath} Sleep 1 Click Element xpath=//select[@id="proCreation"] Click Element xpath=//select[@id="proCreation"]//option[@value="adminonly"] @@ -103,7 +103,7 @@ Set Pro Create Admin Only Set Pro Create Every One #set limit to Every One - Click Element xpath=${configuration_xpath} + Click Element xpath=${system_config_xpath} Sleep 1 Click Element xpath=//select[@id="proCreation"] Click Element xpath=//select[@id="proCreation"]//option[@value="everyone"] @@ -147,8 +147,7 @@ Project Creation Should Not Display Switch To System Settings Sleep 1 Click Element xpath=${configuration_xpath} - Click Element xpath=//*[@id="config-system"] - + Click Element xpath=${system_config_xpath} Modify Token Expiration [Arguments] ${minutes} Input Text xpath=//*[@id="tokenExpiration"] ${minutes} diff --git a/tests/resources/Harbor-Pages/Configuration_Elements.robot b/tests/resources/Harbor-Pages/Configuration_Elements.robot index 8cb6649b5..f702aa421 100644 --- a/tests/resources/Harbor-Pages/Configuration_Elements.robot +++ b/tests/resources/Harbor-Pages/Configuration_Elements.robot @@ -20,4 +20,5 @@ ${project_create_xpath} //clr-dg-action-bar//button[contains(.,'New')] ${self_reg_xpath} //input[@id="clr-checkbox-selfReg"] ${test_ldap_xpath} /html/body/harbor-app/harbor-shell/clr-main-container/div/div/config/div/div/div/button[3] ${config_save_button_xpath} //config//div/button[contains(.,'SAVE')] -${configuration_xpath} //clr-vertical-nav-group-children/a[contains(.,'Configuration')] \ No newline at end of file +${configuration_xpath} //clr-vertical-nav-group-children/a[contains(.,'Configuration')] +${system_config_xpath} //*[@id="config-system"] \ No newline at end of file