spriteCloud / lapis-lazuli

Cucumber helper functions and scaffolding for easier test automation suite development.
Other
7 stars 7 forks source link

Problems with test suite template of 2.1.3 pull request #96

Open barzilay opened 6 years ago

barzilay commented 6 years ago

I see a few failures (unintended as far as I can see?) with the new template. Can you reproduce? Some scenarios fail deliberately for training purposes, but as I understand it the account and todo scenarios should work right?

Lets fix them before releasing 2.3.1:

  1. Deprecation warning

    @basic_01
    Scenario: example01 - Spritecloud search                       # features/1_basic.feature:8
    Given the user navigates to "blog"                           # features/step_definitions/basic_steps.rb:12
    When the user searches for "lapis lazuli"                    # features/step_definitions/basic_steps.rb:17
    2018-02-06 09:58:59 WARN Watir [DEPRECATION] :text locator with RegExp values to find elements based on only visible text is deprecated. Use :visible_text instead.
    Then text "Open Source" should display somewhere on the page # features/step_definitions/basic_steps.rb:29
  2. Error in the @account_01 scenario

    @account_01 @log_in # @pause # You can add @pause to have a break between every step.
    Scenario: account_01 - Logging in                 # features/2_account.feature:11
    Given the user is logged out                    # features/step_definitions/account_steps.rb:17
    When "test-user" logs in                        # features/step_definitions/account_steps.rb:7
      timed out after 30 seconds, waiting for #<Watir::Input: located: false; {:xpath=>"//div[contains(concat('', normalize-space(@class), ''), 'container')]", :tag_name=>"div", :index=>0} --> {:id=>"login-password", :tag_name=>"input"}> to be located (Watir::Exception::UnknownObjectException)
      ./features/helpers/authentication_helper.rb:108:in `log_in'
      ./features/step_definitions/account_steps.rb:10:in `/^"?(.*?)"? logs in$/'
      features/2_account.feature:13:in `When "test-user" logs in'
    Then the page should display as logged in state # features/step_definitions/account_steps.rb:26
  3. Error in account_02 scenario

    @account_02 @log_out
    Scenario: account_02 - Logging out                 # features/2_account.feature:17
    Given "test-user" is logged in                   # features/step_definitions/account_steps.rb:21
      timed out after 30 seconds, waiting for #<Watir::Input: located: false; {:xpath=>"//div[contains(concat('', normalize-space(@class), ''), 'container')]", :tag_name=>"div", :index=>0} --> {:id=>"login-password", :tag_name=>"input"}> to be located (Watir::Exception::UnknownObjectException)
      ./features/helpers/authentication_helper.rb:108:in `log_in'
      ./features/helpers/authentication_helper.rb:56:in `ensure_log_in'
      ./features/step_definitions/account_steps.rb:22:in `/^"(.*?)" is logged in$/'
      features/2_account.feature:18:in `Given "test-user" is logged in'
    When the user clicks on the logout button        # features/step_definitions/account_steps.rb:13
    Then the page should display as logged out state # features/step_definitions/account_steps.rb:26
  4. Error in account_05

    @account_05
    Scenario: account_05 - Logging in a new registration # features/2_account.feature:35
    Given "default-user" has registered a new account  # features/step_definitions/account_steps.rb:49
    When the user logs in                              # features/step_definitions/account_steps.rb:7
      timed out after 30 seconds, waiting for #<Watir::Input: located: false; {:xpath=>"//div[contains(concat('', normalize-space(@class), ''), 'container')]", :tag_name=>"div", :index=>0} --> {:id=>"login-password", :tag_name=>"input"}> to be located (Watir::Exception::UnknownObjectException)
      ./features/helpers/authentication_helper.rb:108:in `log_in'
      ./features/step_definitions/account_steps.rb:10:in `/^"?(.*?)"? logs in$/'
      features/2_account.feature:37:in `When the user logs in'
    Then the page should display as logged in state    # features/step_definitions/account_steps.rb:26
  5. Error in the todo_01 scenario

    @todo_01
    Scenario: todo_01 - adding a todo item                       # features/3_todo_list.feature:7
    Given "test-user" is logged in                             # features/step_definitions/account_steps.rb:21
      timed out after 30 seconds, waiting for #<Watir::Input: located: false; {:xpath=>"//div[contains(concat('', normalize-space(@class), ''), 'container')]", :tag_name=>"div", :index=>0} --> {:id=>"login-password", :tag_name=>"input"}> to be located (Watir::Exception::UnknownObjectException)
      ./features/helpers/authentication_helper.rb:108:in `log_in'
      ./features/helpers/authentication_helper.rb:56:in `ensure_log_in'
      ./features/step_definitions/account_steps.rb:22:in `/^"(.*?)" is logged in$/'
      features/3_todo_list.feature:8:in `Given "test-user" is logged in'
    When a todo item with text "Hello world" is added          # features/step_definitions/todo_steps.rb:1
    Then a todo item with text "Hello world" should be present # features/step_definitions/todo_steps.rb:5
sjieg commented 6 years ago

@basic_01 was fixed in https://github.com/spriteCloud/lapis-lazuli/commit/072450e1efed3148cb7482b7fe43b48112c1bd80

I cannot reproduce the other timeout errors. Please confirm and close.