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

Ensure unit, integration, and e2e testing best practices #688

Open
9 of 14 tasks
zainfathoni opened this issue Aug 13, 2021 · 8 comments
Open
9 of 14 tasks

Ensure unit, integration, and e2e testing best practices #688

zainfathoni opened this issue Aug 13, 2021 · 8 comments
Assignees
Labels
epic A master issue thread which contains other smaller issues hacktoberfest Issues for Hacktoberfest high-priority Issue with high priority testing Automated testing

Comments

@zainfathoni
Copy link
Member

zainfathoni commented Aug 13, 2021

Overview

There are a lot of non-recommended practices in our unit & integration tests, such as (not limited to):

  • Non-accessible queries
  • Irrelevant assertions
  • Too large snapshot testings which make them hard to read and rendered them useless
  • etc.

All those practices potentially lead to regressions in the future by introducing false positives due to passing tests on breaking changes.

Testing Guidelines

In general, these are three guidelines that we need to pay attention to:

  1. Query priorities
  2. Testing appearance and disappearance
  3. Opting in for interactions instead of events

Current Tasks

General

Unit Testing / Integration Testing

E2E Testing

@zainfathoni zainfathoni added epic A master issue thread which contains other smaller issues testing Automated testing labels Aug 13, 2021
@zainfathoni zainfathoni added this to the Further Optimizations milestone Aug 13, 2021
@zainfathoni zainfathoni self-assigned this Aug 13, 2021
@rubiagatra rubiagatra changed the title Ensure unit & integration testing best practices Ensure unit, integration, and e2e testing best practices Aug 14, 2021
@rubiagatra
Copy link
Collaborator

@zainfathoni I updated the title and put all the lists about testing and e2e testing. Is that okay?

I will be focusing on that for this project. But, I little bit busy for 2 weeks until August 22. Can only visit the project on Sunday.

Maybe after that, I can have more time to help

@zainfathoni
Copy link
Member Author

Okay, no problem.
In the meantime, I'm working on #195 at #727 so that we can use it in our GitHub Actions CI.

@rubiagatra
Copy link
Collaborator

I think we will need to wait for #697 to be done before we can continue.

For #459 and #468 is that e2e testing? or still on unit/integration testing

@zainfathoni

@zainfathoni
Copy link
Member Author

zainfathoni commented Aug 15, 2021

I think we will need to wait for #697 to be done before we can continue.

For the unit & integration tests, yes. I'll try to review it later tonight to unblock the rest of the issues.
However, I think nothing blocks the e2e issues at the moment.

For #459 and #468 is that e2e testing? or still on unit/integration testing

Based on my classifications at #374, they are parts of integration testing. Do you think we need another label to segregate unit & integration tests from e2e tests, Mas @rubiagatra?

@rubiagatra rubiagatra self-assigned this Aug 15, 2021
@rubiagatra
Copy link
Collaborator

I think yes mas @zainfathoni, RTL, and Cypress are in different categories.
Even though they are closely related maybe testing for unit/integration test and e2e test for cypress related?.

I will update the description based on #374

@zainfathoni
Copy link
Member Author

I think yes mas @zainfathoni, RTL, and Cypress are in different categories.

Even though they are closely related maybe testing for unit/integration test and e2e test for cypress related?.

Let's rename the label for unit & integration into unit & integration test to make them more specific and obvious for the contributors.

I will update the description based on #374

Thanks! 🙏

@zainfathoni
Copy link
Member Author

zainfathoni commented Aug 30, 2021

Mas @rubiagatra, this epic becomes more important due to the upcoming migration here #783.

@zainfathoni zainfathoni added the high-priority Issue with high priority label Aug 30, 2021
@rubiagatra
Copy link
Collaborator

Thank you for remind me mas @zainfathoni , will checkout this soon

@zainfathoni zainfathoni added the hacktoberfest Issues for Hacktoberfest label Oct 13, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
epic A master issue thread which contains other smaller issues hacktoberfest Issues for Hacktoberfest high-priority Issue with high priority testing Automated testing
Projects
None yet
Development

No branches or pull requests

2 participants