Skip to content
Snippets Groups Projects

Add feature specs for note polling

Merged Grzegorz Bizon requested to merge tests/note-polling into master

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Grzegorz Bizon Added 1 commit:

    Added 1 commit:

    • d1d2048a - Add spinach test for note polling
  • Author Maintainer

    @rspeicher Added spinach test -- instead of adding this ugly waiting implementation, increased Capybara timeout to 15 seconds. have_content matcher will make Capybara try to find new note until driver timeouts.

  • Grzegorz Bizon Added 1 commit:

    Added 1 commit:

    • ae93cb7f - Add minor fixes in note polling specs
  • Author Maintainer

    Will rebase when gitlab-org/gitlab-ce!2084 is merged.

  • Author Maintainer

    @stanhu, @rspeicher: After deeper investigation, unfortunately Timecop will not help here. Timecop mocks Ruby date objects, and what we actually need here is to scale time or travel into the future in javascripts consumed by WebKit driver that is being used by PhantomJS.

    So, we need to mock javascript's time here -- maybe using Sinon.js is a good idea (Sinon has some javascript time-based mocking capabilities), but this would require injecting sinon.js into application (maybe only in test env), I'm not sure if it is a good idea and I wonder if it is worth giving a try. What do you think ?

  • Grzegorz Bizon Added 2 commits:

    Added 2 commits:

    • 42a9fb64 - Assign notes object to a variable
    • 39d5baa7 - Trigger notes refresh in specs instead of waiting for ajax
  • Author Maintainer

    @rspeicher Please review changes. Is it ok now ?

  • Grzegorz Bizon Added 86 commits:

    Added 86 commits:

    • 39d5baa7...9451db38 - 81 commits from branch master
    • 7c14541d - Add feature specs for note polling
    • 9470d05c - Add spinach test for note polling
    • 3e789eab - Add minor fixes in note polling specs
    • 6fb120d1 - Assign notes object to a variable
    • 8fe821cf - Trigger notes refresh in specs instead of waiting for ajax
  • Grzegorz Bizon Title changed from WIP: Add feature specs for note polling to Add feature specs for note polling

    Title changed from WIP: Add feature specs for note polling to Add feature specs for note polling

  • Grzegorz Bizon Status changed to merged

    Status changed to merged

  • Grzegorz Bizon mentioned in commit 4493d3fd

    mentioned in commit 4493d3fd

  • Please register or sign in to reply
    Loading