PageAccueil.resource 1.1 KB

1234567891011121314151617181920212223242526272829
  1. *** Settings ***
  2. Library SeleniumLibrary
  3. Library XML
  4. *** Variables ***
  5. ${LOGIN_BUTTON_LOCATOR_ACCUEIL}= xpath=//*[@id="root"]/div/div/div/div[1]/div[1]/a[1]
  6. ${CREATE_ACCOUNT_BUTTON_LOCATOR}= xpath=//*[@id="root"]/div/div/div/div[1]/div[1]/a[2]
  7. ${LOGOUT_BUTTON_LOCATOR}= xpath=//*[@id="navbarSupportedContent"]/ul/li[2]/button
  8. *** Keywords ***
  9. Valider l'affichage de la page "Accueil" - non connecté
  10. ${page_url} = Get Location
  11. Should Be Equal As Strings ${page_url} https://practice.expandtesting.com/notes/app/
  12. Wait Until Element Is Visible ${LOGIN_BUTTON_LOCATOR_ACCUEIL}
  13. #Element Should Exist ${LOGIN_BUTTON_LOCATOR}
  14. #Element Should Exist ${CREATE_ACCOUNT_BUTTON_LOCATOR}
  15. Valider l'affichage de la page "Accueil" - connecté
  16. Wait Until Element Is Visible ${LOGOUT_BUTTON_LOCATOR}
  17. ${page_url} = Get Location
  18. Should Be Equal As Strings ${page_url} https://practice.expandtesting.com/notes/app
  19. Cliquer sur "Login"
  20. Click Element ${LOGIN_BUTTON_LOCATOR_ACCUEIL}
  21. Cliquer sur "Create an account"
  22. Click Element ${CREATE_ACCOUNT_BUTTON_LOCATOR}