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

test(unify): Specs Page Workflows - E2E/Component #19780

Merged
merged 18 commits into from
Jan 25, 2022

Conversation

tbiethman
Copy link
Contributor

@tbiethman tbiethman commented Jan 20, 2022

This PR adds coverage for the Specs page for both E2E and component testing projects. Some existing tests were modified to align with new tests to reduce duplication, and a few were removed if they have coverage elsewhere. Existing TODOs were cleaned up as much as possible.

User facing changelog

N/A

Additional details

The following reqs are accounted for here: TODO

How has the user experience changed?

PR Tasks

  • Have tests been added/updated?
  • Has the original issue (or this PR, if no issue exists) been tagged with a release in ZenHub? (user-facing changes only)
  • [n/a] Has a PR for user-facing changes been opened in cypress-documentation?
  • [n/a] Have API changes been updated in the type definitions?
  • [n/a] Have new configuration options been added to the cypress.schema.json?

@cypress-bot
Copy link
Contributor

cypress-bot bot commented Jan 20, 2022

Thanks for taking the time to open a PR!

@cypress
Copy link

cypress bot commented Jan 20, 2022



Test summary

17913 0 216 0Flakiness 5


Run details

Project cypress
Status Passed
Commit 6db03f1
Started Jan 24, 2022 7:12 PM
Ended Jan 24, 2022 7:23 PM
Duration 11:43 💡
OS Linux Debian - 10.10
Browser Multiple

View run in Cypress Dashboard ➡️


Flakiness

commands/net_stubbing.cy.ts Flakiness
1 network stubbing > waiting and aliasing > can timeout waiting on a single request using "alias.request"
2 network stubbing > waiting and aliasing > can timeout waiting on a single request using "alias.request"
cypress/proxy-logging.cy.ts Flakiness
1 ... > works with forceNetworkError
2 Proxy Logging > request logging > xhr log has response body/status code
3 ... > works with forceNetworkError

This comment has been generated by cypress-bot as a result of this project's GitHub integration settings. You can manage this integration in this project's settings in the Cypress Dashboard

@@ -0,0 +1,12 @@
module.exports = {
Copy link
Contributor Author

@tbiethman tbiethman Jan 20, 2022

Choose a reason for hiding this comment

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

Three new system-test projects were added in this PR. Lots of files, some duplication, but utilizing these gives us as much e2e coverage as possible (as compared to config interceptions).

@tbiethman tbiethman self-assigned this Jan 20, 2022
Copy link
Contributor

@marktnoonan marktnoonan left a comment

Choose a reason for hiding this comment

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

Just one change request on the button that was removed, I think we should come at that a different way. Overall this is super.

…into issue-19207-specs-page-ct

# Conflicts:
#	packages/app/cypress/e2e/index.cy.ts
cy.findByRole('link', { name: defaultMessages.createSpec.viewSpecPatternButton })
.should('be.visible')
.and('not.be.disabled')
.and('have.attr', 'href', '#/settings?section=project&setting=specPattern')
Copy link
Member

Choose a reason for hiding this comment

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

is this href at risk of changing?

Copy link
Contributor

Choose a reason for hiding this comment

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

Not in the short term. Medium term, this type of deeplink to the spec pattern will be replaced with a modal the opens and displays the spec pattern directly. But for now, the settings page is explicitly looking for this query param to decide where to scroll, so it's a pretty stable situation and we'd only want to change this URL if that implementation changed.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@marktnoonan is there an issue logged to update to the modal pattern? I wasn't able to find one.

Copy link
Contributor

Choose a reason for hiding this comment

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

@tbiethman there was an issue, but recently closed as we believe this change has been dropped from 10.0. But it is still in Figma and I expect it will come around soon enough even if not present during release. It's probably a nicer experience to just peek at the spec pattern instead of leaving the current page.

Copy link
Contributor

Choose a reason for hiding this comment

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

@tbiethman I stand corrected, @ZachJW34 has this change completed as part of other spec pattern work in this PR, so whichever merges last can align the test with the new behavior.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@marktnoonan I'll keep an eye on that PR. It doesn't change the specs page implementation, at least as it stands. But if the component work is done, it might make sense to re-open that issue and hook this up prior to release.

cy.get('@EmptySpecCard').click()
cy.contains('button', defaultMessages.components.button.cancel).click()
cy.get('[data-cy="create-spec-modal"]').within(() => {
cy.get('[data-cy="card"]').contains(defaultMessages.createSpec.e2e.importEmptySpec.header).click()
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
cy.get('[data-cy="card"]').contains(defaultMessages.createSpec.e2e.importEmptySpec.header).click()
cy.get('[data-cy="card"]')
.contains(defaultMessages.createSpec.e2e.importEmptySpec.header)
.click()

emilyrohrbough
emilyrohrbough previously approved these changes Jan 21, 2022
@tbiethman tbiethman merged commit 3bc529b into 10.0-release Jan 25, 2022
@tbiethman tbiethman deleted the issue-19207-specs-page-ct branch January 25, 2022 15:50
tgriesser added a commit that referenced this pull request Jan 26, 2022
* 10.0-release:
  test: add "cypress-in-cypress" tests for navigating in and out of spec runner (#19845)
  chore: add test cases for migration (#19905)
  test: fix launchpad flake caused by unoptimized deps (#19903)
  feat: launchpad browser select (#19830)
  fix: increase timeout in cy.contains to avoid flake
  refactor: Remove connection on specs, increase pagination limits elsewhere (#19881)
  fix(unify): Fixing launchpad project setup tests (#19886)
  test(unify): Specs Page Workflows - E2E/Component (#19780)
  feat: migration rename files (#19807)
  chore: remove design system warnings (#19851)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Unification App: Write E2E tests around "Specs Page" - New e2e testing project
3 participants