-
Notifications
You must be signed in to change notification settings - Fork 5
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
Add basic E2E Cypress Tests #18
Conversation
…o ml-basic-e2e-tests
- use beforeEach() for clearing local storage between tests
With the recent commit, our E2E tests are running faster because:
So we're no longer waiting for the API to resolve, or for images to load. I updated the code with I ran into an issue with both. It just made it easier to stub out the response and take control that way
That said, this opens up a hole in our testing coverage. We now need an We could use |
so the branch build is passing, but the pr build (branch merged into master then tests ran) is failing It's for the same reason as the past few. I'm not sure |
About this bug I've been working on, clicking something with 0 width and 0 height... is a rendering related issue The solution I applied comes from here: cypress-io/cypress#695 (comment) But that thread, never-the-less, is important to follow in regards to rendering stuff that is API data dependent (since as that API resolves, it triggers a change detection which causes a new draw and possibly cypress is clicking while the draw is occurring or before) |
disabled
cypress-commands
fortext()
@cypress/webpack-preprocessor
andts-loader
Covers the main "business" logic in viewing books, adding books to cart and checking them out
http-server
withspa-http-server
for e2e tests thatvisit()
spa routes ie/checkout
Future:We should create an Integration test so we can be notified when OpenLibrary.org's API response structure changesAdded a basic integration test that checks to see if the response is JSON. In the future, the tests need to be expanded upon based on the structure of the JSON returned (make sure there is
title
,cover
, the correct structure, etc. for which this app depends on)However, as of writing this, openlibrary.org is down, so we'll have to wait.