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

Add testing-guide.md to document testing best practices #3031

Open
victor-yanev opened this issue Sep 26, 2024 · 0 comments
Open

Add testing-guide.md to document testing best practices #3031

victor-yanev opened this issue Sep 26, 2024 · 0 comments
Assignees
Labels
documentation Improvements or additions to documentation enhancement New feature or request

Comments

@victor-yanev
Copy link
Contributor

victor-yanev commented Sep 26, 2024

Problem

To ensure consistency and quality in our testing approach, we need to create a comprehensive testing-guide.md document. This guide will serve as a reference for all contributors to understand and implement best practices in writing tests for our project.

Benefits

  • Consistency: Ensures all contributors follow the same testing practices, leading to more consistent and reliable tests.
  • Quality: Improves the overall quality of the codebase by promoting thorough and effective testing.
  • Onboarding: Eases the onboarding process for new developers by providing a clear and structured guide to testing.
  • Efficiency: Saves time by providing ready-to-use examples and reducing the learning curve for writing tests.

Objectives

  1. Document Testing Strategies: Outline the overall testing strategy, including unit tests, integration tests, and end-to-end tests.
  2. Environment Setup: Provide detailed instructions on setting up the testing environment, including necessary dependencies and configurations.
  3. Test Writing Guidelines: Offer guidelines on how to write effective and maintainable tests, including naming conventions, structuring test cases, and using assertions.
  4. Utilizing Helper Methods: Explain the usage of helper methods such as overrideEnvs, withOverriddenEnvs, useInMemoryRedisServer, startRedisInMemoryServer, and stopRedisInMemoryServer. Include examples and scenarios where these methods should be used.
  5. Common Pitfalls: Highlight common mistakes and pitfalls in writing tests and how to avoid them.
  6. Code Examples: Provide code examples and templates that developers can use as a starting point for writing their tests.
  7. Continuous Integration: Describe how tests are integrated into the CI/CD pipeline and the importance of maintaining a green build and isolating failing test cases.

Action Items

  • Create a new testing-guide.md file in the root directory of the project.
  • Populate the guide with the outlined sections and content.
  • Review and refine the guide with input from senior developers and the QA team.
  • Communicate the availability of the guide to all contributors and encourage its usage.

By implementing this guide, we aim to foster a culture of quality and reliability in our development process, ensuring that all code changes are thoroughly tested and validated.

@victor-yanev victor-yanev added the enhancement New feature or request label Sep 26, 2024
@victor-yanev victor-yanev self-assigned this Sep 26, 2024
@victor-yanev victor-yanev added the documentation Improvements or additions to documentation label Sep 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation enhancement New feature or request
Projects
Status: Sprint Backlog
Development

No branches or pull requests

1 participant