Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Provide browser tests #4

Open
kettanaito opened this issue Sep 18, 2017 · 6 comments
Open

Provide browser tests #4

kettanaito opened this issue Sep 18, 2017 · 6 comments
Assignees
Milestone

Comments

@kettanaito
Copy link
Owner

kettanaito commented Sep 18, 2017

What

I need to provide tests for Tracker inside the browser.

How

Testing of the library would look as follows:

  1. Each test inserts a DOM element into the virtual DOM
  2. Scrolling is simulated, expecting certain action from the callback
  3. After each test the scroll position is reset to 0, 0
@kettanaito kettanaito added this to the Tests milestone Sep 18, 2017
@kettanaito kettanaito changed the title Provide tests with js-dom Provide tests with js-dom Sep 18, 2017
@kettanaito kettanaito changed the title Provide tests with js-dom Provide browser tests Sep 26, 2017
@kettanaito
Copy link
Owner Author

Update

  • Proceeding on a dedicated test branch.
  • The following functionality is currently covered:
    • Absolute tracking
      • Basics
      • Edges options

@kettanaito
Copy link
Owner Author

Update

  • Tests are now organized into separate files which are dynamically included
  • Added "threshold" tests
  • Added "once" tests

@kettanaito kettanaito self-assigned this Oct 7, 2017
@kettanaito
Copy link
Owner Author

Opened a dedicated pull request: #6.

@kettanaito
Copy link
Owner Author

Update

  • Basic tests are added
  • Absolute tracking tests are added

In progress

  • Relative tracking tests

@kettanaito
Copy link
Owner Author

Update

  • Each test is going to be split so it's possible to run individual scenarios in the browser
  • Started with relative thresholdX

@kettanaito
Copy link
Owner Author

Update

Due to unstable results from mocha (might have been related to the amount of tests running simultaneously) the decision was made to switch to Cypress.

The following tests were re-written for Cypress:

Absolute tracking

  • edges
    • edgeX
    • edgeX + offsetX
    • edgeY
    • edgeY + offsetY
    • edgeX/Y
    • edgeX/Y + offsetX/Y

@kettanaito kettanaito modified the milestones: Tests, Release 1.0 Nov 20, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant