Skip to content

Add comprehensive integration tests for year validation logic and GraphQL sync edge cases #283

@nivedha2025cse-gif

Description

@nivedha2025cse-gif

Is your feature request related to a problem? Please describe.

A recent commit (7bb40d1) introduced custom validation logic to enforce year >= 2008 with a consistent error message. Currently, there is a lack of automated, robust testing around this validation system and real-time GraphQL syncing. Without an advanced integration test suite, future updates or feature extensions risk causing regressions that could silently break data processing or validation for edge-case inputs.

Describe the solution you'd like

I would like to introduce a comprehensive quality assurance architecture to protect the app/ validation logic:

  • Unit Testing Suite: Implement Jest or Vitest unit tests targeting the validation utility functions to ensure any input year < 2008 explicitly triggers the expected error handler, while valid entries resolve flawlessly.
  • GraphQL Mocking & Sync Testing: Build mock environments for real-time GraphQL synchronization to test application stability when handling edge cases like empty contribution graphs, boundary date ranges, and network fluctuations.
  • CI/CD Quality Gate: Wire the new testing scripts seamlessly into the existing GitHub Actions workflow so they run automatically on every incoming Pull Request, preventing breaking changes from hitting the main branch.

Describe alternatives you've considered

Manual testing is an alternative, but it is highly error-prone, untraceable, and slows down the contribution pipeline for an active open-source project like CommitPulse. @JhaSourav07 kindly assaign it to me

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions