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

feat: e2e test using POM pattern #33

Merged
merged 5 commits into from
Oct 14, 2022

Conversation

depapp
Copy link
Contributor

@depapp depapp commented Oct 13, 2022

Closes #24 (comment)

Description

refactor e2e test to use Page-Object-Model pattern.

Current Tasks

  • homepage test

@vercel
Copy link

vercel bot commented Oct 13, 2022

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated
senarai ✅ Ready (Inspect) Visit Preview Oct 14, 2022 at 0:31AM (UTC)

@codecov
Copy link

codecov bot commented Oct 14, 2022

Codecov Report

Merging #33 (335f0c1) into main (7e3dd9e) will not change coverage.
The diff coverage is n/a.

❗ Current head 335f0c1 differs from pull request most recent head f590396. Consider uploading reports for the commit f590396 to get more accurate results

@@           Coverage Diff           @@
##             main      #33   +/-   ##
=======================================
  Coverage   41.49%   41.49%           
=======================================
  Files          39       39           
  Lines        2270     2270           
  Branches       80       80           
=======================================
  Hits          942      942           
  Misses       1300     1300           
  Partials       28       28           

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

Copy link
Owner

@zainfathoni zainfathoni left a comment

Choose a reason for hiding this comment

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

Thanks for refactoring it. I like the way it's organized now. 💯
However, I have some objections in the way we query the elements. 😅

Quoting from Testing Library slogan,

The more your tests resemble the way your software is used,
the more confidence they can give you.

So please update the queries to use my initial queries from playwright-testing-library, or you can also experiment with Playwright's new APIs inspired by Testing Library. But first, you need to upgrade the Playwright version to 1.27.0 to use it.

playwright.config.ts Show resolved Hide resolved
e2e/pages/home.page.ts Outdated Show resolved Hide resolved
e2e/pages/home.page.ts Outdated Show resolved Hide resolved
@depapp
Copy link
Contributor Author

depapp commented Oct 14, 2022

could you please help to recheck @zainfathoni , thanks!
image

Copy link
Owner

@zainfathoni zainfathoni left a comment

Choose a reason for hiding this comment

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

LGTM 💯
Thanks for making the changes accordingly, @depapp! 🙏

@zainfathoni zainfathoni added the automerge To be merged automatically once all the requirements are fulfilled label Oct 14, 2022
@zainfathoni
Copy link
Owner

@all-contributors add @depapp for test

@allcontributors
Copy link
Contributor

@zainfathoni

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

@zainfathoni zainfathoni added the hacktoberfest-accepted Accepted for Hacktoberfest participation label Oct 14, 2022
@depapp depapp deleted the page-object-model branch October 14, 2022 13:46
@zainfathoni
Copy link
Owner

@all-contributors add @depapp for test

@allcontributors
Copy link
Contributor

@zainfathoni

@depapp already contributed before to test

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
automerge To be merged automatically once all the requirements are fulfilled hacktoberfest-accepted Accepted for Hacktoberfest participation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Write unit & integration tests for contributions form
2 participants