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

Cypress Setup #3082

Merged
merged 7 commits into from
Apr 6, 2021
Merged

Cypress Setup #3082

merged 7 commits into from
Apr 6, 2021

Conversation

revanth0212
Copy link
Contributor

@revanth0212 revanth0212 commented Mar 23, 2021

Description

Initial cypress setup.

Related Issue

Closes PWA-1569

Verification Stakeholders

@dpatil-magento

Specification

Verification Steps

  1. Checkout the branch. Navigate to pwa-automation-tests.
  2. Run yarn install if its your first time.
  3. Run yarn test to open up the cypress UI. You should see 2 dummy tests but they won't run. They are just provided as examples.

Screenshots / Screen Captures (if appropriate)

image

Checklist

  • I have added tests to cover my changes, if necessary.
  • I have added translations for new strings, if necessary.
  • I have updated the documentation accordingly, if necessary.

@revanth0212 revanth0212 added the version: Minor This changeset includes functionality added in a backwards compatible manner. label Mar 23, 2021
@PWAStudioBot
Copy link
Contributor

PWAStudioBot commented Mar 23, 2021

Messages
📖

Associated JIRA tickets: PWA-1569.

📖 DangerCI Failures related to missing labels/description/linked issues/etc will persist until the next push or next nightly build run (assuming they are fixed).
📖

Access a deployed version of this PR here. Make sure to wait for the "pwa-pull-request-deploy" job to complete.

Generated by 🚫 dangerJS against 8065737

@revanth0212 revanth0212 marked this pull request as ready for review March 24, 2021 18:52
Copy link
Contributor

@dpatil-magento dpatil-magento left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking for examples on how to manage

  • css element declaration in one place and call them as needed in tests.
  • where to add common actions like login, place order and call them in tests as needed.
  • where to mock data

@@ -0,0 +1,7 @@
# Running Venia Functional Tests
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good to rename the folder name something specific to Venia and Integration/E2E tests. venia-integrestion-tests, venia-e2e-tests. words pwa and automation are very generic/higher level.

it('test', () => {
cy.visit('/');

cy.wait(5000);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add comment if its needed else remove this.

@revanth0212
Copy link
Contributor Author

Addressed the PR comments. Created a new folder structure. But unfortunately, the sample tests I left in the PR are dummy ones. Anyways we will add new tests once this is merged.

dpatil-magento
dpatil-magento previously approved these changes Mar 31, 2021
Copy link
Contributor

@supernova-at supernova-at left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome! Left some considerations for you.

Also, I think I am missing a commit? I don't see the new data-id attribute added to any components, so the tests are failing:

Screen Shot 2021-04-01 at 1 27 17 PM

@revanth0212
Copy link
Contributor Author

Also, I think I am missing a commit? I don't see the new data-id attribute added to any components, so the tests are failing:

You are right @supernova-at there are no data-ids yet. This is a sample folder structure with sample tests that don't run 😅 like mentioned in this comment: #3082 (comment)

Should have added this in the description. My bad.

@dpatil-magento dpatil-magento merged commit 26eaada into develop Apr 6, 2021
@dpatil-magento dpatil-magento deleted the revanth/cypress_setup branch April 6, 2021 17:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Progress: done version: Minor This changeset includes functionality added in a backwards compatible manner.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants