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

initial cypress setup #2230

Merged
merged 2 commits into from
Dec 8, 2023
Merged

Conversation

christianvogt
Copy link
Contributor

@christianvogt christianvogt commented Nov 24, 2023

Closes: #2071

Description

Initial setup for cypress.

  • adds scripts to run cypress
  • adds sample experimental snapshot test
  • adds initial concept for organizing page objects for selectors
  • migrates storybook tests to cypress

This PR does not run cypress alongside existing tests.

How Has This Been Tested?

Manually.

Test Impact

None.

Request review criteria:

Self checklist (all need to be checked):

  • The developer has manually tested the changes and verified that the changes work
  • Commits have been squashed into descriptive, self-contained units of work (e.g. 'WIP' and 'Implements feedback' style messages have been removed)
  • Testing instructions have been added in the PR body (for PRs involving changes that are not immediately obvious).
  • The developer has added tests or explained why testing cannot be added (unit tests & storybook for related changes)

If you have UI changes:

  • Included any necessary screenshots or gifs if it was a UI change.
  • Included tags to the UX team if it was a UI/UX change (find relevant UX in the SMEs section).

After the PR is posted & before it merges:

  • The developer has tested their solution on a cluster by using the image produced by the PR to main

Copy link
Contributor

@dpanshug dpanshug left a comment

Choose a reason for hiding this comment

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

Git ignore cypress temporary files.

/src/__tests__/cypress/cypress/downloads
/src/__tests__/cypress/cypress/screenshots

frontend/package.json Outdated Show resolved Hide resolved
frontend/package.json Outdated Show resolved Hide resolved
frontend/.env.cypress.mock Show resolved Hide resolved
frontend/src/__tests__/cypress/cypress.config.ts Outdated Show resolved Hide resolved
@dpanshug
Copy link
Contributor

dpanshug commented Dec 5, 2023

@christianvogt Some more suggestions.

  1. Can you pls update the architecture of e2e testing here

  2. In the /src/__tests__/e2e folder, there is currently a test named CreateEditDeleteProject.spec.ts written in Playwright. Could we consider removing this folder, because that is already migrated to cypress in this PR?

@christianvogt
Copy link
Contributor Author

@dpanshug I'm going to update docs in another PR. This was just an initial delivery to get started. I even have more work right now that builds on this PR and changes up more things.

I am not removing playwright tests as part of this PR either because there's more work to be done to get parity. That will come later.

@christianvogt
Copy link
Contributor Author

added a 2nd commit that builds on the first and migrates the playwright tests to cypress

Copy link
Contributor

openshift-ci bot commented Dec 8, 2023

[APPROVALNOTIFIER] This PR is APPROVED

Approval requirements bypassed by manually added approval.

This pull-request has been approved by:

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@christianvogt christianvogt dismissed dpanshug’s stale review December 8, 2023 22:25

changes were addressed

@openshift-merge-bot openshift-merge-bot bot merged commit 27f0e3b into opendatahub-io:main Dec 8, 2023
6 checks passed
@christianvogt christianvogt linked an issue Dec 8, 2023 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Tech Debt]: migrate playwright tests to cypress [Story]: setup cypress
3 participants