Testing strategy #1130
stalniy
started this conversation in
Contribution RFC
Replies: 1 comment
-
Makes total sense to me! Thanks for the clear outline! |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Summary
This proposal outlines when to write and run different types of tests.
The main goal is to establish a testing strategy that:
Motivation
Currently, in the console-api project, most tests are end-to-end (E2E) and are executed during PR-level checks. While E2E tests validate the entire flow, they are difficult to debug and maintain, especially for developers unfamiliar with the project context. Running E2E tests at the PR level is not ideal because failures in external services (which we do not own and cannot fix) can block development or lead to ignoring CI failures, which is also problematic.
Testing Strategy
Unit Tests for the UI
When to use:
Why:
When to run:
Soft requirements:
Additional notes
Works well with Testing Library, which facilitates user-centric testing.
Unit Tests for the Service Layer
When to use:
Why:
When to run:
Soft requirements:
Additional notes
Integration Tests for the Service Layer and Repository Pattern
When to use:
Repository
services).Why:
When to run:
Soft requirements:
Functional or API Tests
When to use:
Why:
When to run:
Soft requirements:
Additional notes:
These tests should only fail if functional requirements change, not due to internal refactoring.
End-to-End (E2E) Tests
When to use:
Why:
When to run:
Soft requirements:
Beta Was this translation helpful? Give feedback.
All reactions