Skip to content

Add unit test suite and enable branch coverage#112

Merged
gmazoyer merged 1 commit into
mainfrom
tests-and-branch-coverage
Jun 27, 2026
Merged

Add unit test suite and enable branch coverage#112
gmazoyer merged 1 commit into
mainfrom
tests-and-branch-coverage

Conversation

@gmazoyer

@gmazoyer gmazoyer commented Jun 27, 2026

Copy link
Copy Markdown
Member

What

Adds a unit test suite covering the API client, endpoints, query layer, response/record handling, models, tokens and helpers. Enables branch coverage and uploads it to Codecov.

Why

The library had little automated testing. This raises confidence in refactors and guards against regressions in URL building, auth token routing, response parsing and diffing.

Changes

  • Add unit tests across api, endpoint, query, response, models, token and util
  • Mint auth tokens dynamically in tests instead of shipping static JWT fixtures
  • Fix Record list diffing so items containing the separator are not conflated
  • Count single-object responses as one result
  • Remove dead code: Request.get_openapi, Record pickle hooks, Token.str
  • Correct the cat() docstring
  • Enable --cov-branch and upload coverage to Codecov with a token

Requires the CODECOV_TOKEN secret to be set on the repository.

Closes #12

Cover the API client, endpoints, query layer, response/record handling,
models, tokens and helpers with unit tests, and report branch coverage.

- Add unit tests across api, endpoint, query, response, models, token and util
- Mint auth tokens dynamically in tests instead of shipping static JWT fixtures
- Fix Record list diffing so items containing the separator are not conflated
- Count single-object responses as one result
- Remove dead code: Request.get_openapi, Record pickle hooks, Token.__str__
- Correct the cat() docstring
- Enable --cov-branch and upload coverage to Codecov with a token
@gmazoyer gmazoyer merged commit 36a7135 into main Jun 27, 2026
5 checks passed
@gmazoyer gmazoyer deleted the tests-and-branch-coverage branch June 27, 2026 10:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add more unit tests

1 participant