Skip to content

Expand test coverage with mocked Copilot SDK #7

Description

@trsdn

Summary

Improve test coverage with comprehensive unit and integration tests using mocked dependencies.

Tasks

  • Create mock for \CopilotClient\ and \Session\
  • Add unit tests for \ ormatLocalDate()\ and \getDateRange()\ utilities
  • Add unit tests for \mergeDuplicates()\ function
  • Add integration tests for API endpoints (/api/news-stream, /api/news, /api/summarize-topic)
  • Add error case tests (network failures, parse errors, timeouts)
  • Add test coverage reporting

Acceptance Criteria

  • Test coverage > 80%
  • All utility functions have unit tests
  • API endpoints have integration tests with mocked responses
  • CI runs tests on every PR

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions