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: add cypress end-to-end test setup #313

Merged
merged 9 commits into from
Dec 7, 2020
Merged

test: add cypress end-to-end test setup #313

merged 9 commits into from
Dec 7, 2020

Conversation

ddehart
Copy link
Contributor

@ddehart ddehart commented Dec 6, 2020

What:

This PR relates to #7 and replaces #27 while incorporating a lot of what @JacobMGEvans learned while working on that PR.

Why:

End-to-end tests can help combat unintentional side effects and regressions.

How:

This PR adds a single end-to-end test that verifies the app's initial rendered state. It also adds some custom commands for Cypress to abstract some of the less obvious queries needed to test Testing Playground. Finally, it adds some properties to several components, some (data-testid) purely for Cypress/Testing Library queries and others (title) that improve both testability and accessibility.

Checklist:

  • Tests N/A
  • Ready to be merged

@JacobMGEvans
Copy link
Contributor

Awesome! Thanks for the credit, means a lot.

Copy link
Member

@marcosvega91 marcosvega91 left a comment

Choose a reason for hiding this comment

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

Hi @ddehart thanks for working on this, you're very awesome 😄

I don't know if this PR is finished but I have added some comments

Copy link
Member

@marcosvega91 marcosvega91 left a comment

Choose a reason for hiding this comment

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

Your work is awesome, last comments and for me is ready 🥳

@ddehart
Copy link
Contributor Author

ddehart commented Dec 7, 2020

@marcosvega91 done! Thanks for the review

@smeijer smeijer changed the title Add Cypress end-to-end test for initial app load test: add Cypress end-to-end test setup Dec 7, 2020
@ddehart ddehart requested a review from marcosvega91 December 7, 2020 14:46
Copy link
Member

@marcosvega91 marcosvega91 left a comment

Choose a reason for hiding this comment

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

fine, thanks :)

@marcosvega91 marcosvega91 requested a review from smeijer December 7, 2020 14:50
@smeijer
Copy link
Member

smeijer commented Dec 7, 2020

Thanks all!

Especially to @JacobMGEvans for all the time and energy you put into this under #27. I should have merged that one ages ago instead of delaying it because of some minor improvements. I'm truly sorry for that to have happened.

Also thanks for @ddehart for picking up that PR, and bring it to a mergeable state again. And to @marcosvega91 for the review. Much appreciated.

@smeijer smeijer changed the title test: add Cypress end-to-end test setup test: add cypress end-to-end test setup Dec 7, 2020
@smeijer smeijer merged commit 70c7c12 into testing-library:develop Dec 7, 2020
@smeijer
Copy link
Member

smeijer commented Dec 7, 2020

😱 I did it!

image

@smeijer
Copy link
Member

smeijer commented Dec 7, 2020

@all-contributors please add @ddehart for test

@allcontributors
Copy link
Contributor

@smeijer

I've put up a pull request to add @ddehart! 🎉

@smeijer
Copy link
Member

smeijer commented Dec 7, 2020

@all-contributors please add @JacobMGEvans for test

@allcontributors
Copy link
Contributor

@smeijer

I've put up a pull request to add @JacobMGEvans! 🎉

@smeijer smeijer mentioned this pull request Dec 7, 2020
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.

4 participants