Skip to content

test(api): Add contract tests for API response schemas (#36)#93

Merged
mikewheeleer merged 3 commits intoLiquifact:mainfrom
Sam-Rytech:test/api-contract-schemas
Apr 1, 2026
Merged

test(api): Add contract tests for API response schemas (#36)#93
mikewheeleer merged 3 commits intoLiquifact:mainfrom
Sam-Rytech:test/api-contract-schemas

Conversation

@Sam-Rytech
Copy link
Copy Markdown
Contributor

Description

This PR implements the API response schema contract tests to prevent breaking changes and ensure stable client expectations, as requested in issue #36.

Changes Made

  • Fixed a syntax error in src/app.js that was preventing the application from running.
  • Added missing knex dependency required for the test environment.
  • Created tests/contract/api-schemas.test.js using supertest.
  • Implemented schema validations for:
    • GET /health
    • GET /api/invoices
    • POST /api/invoices

Closes #36

@drips-wave
Copy link
Copy Markdown

drips-wave bot commented Mar 28, 2026

@Sam-Rytech Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@Sam-Rytech
Copy link
Copy Markdown
Contributor Author

@mikewheeleer PR opened

@Sam-Rytech
Copy link
Copy Markdown
Contributor Author

@mikewheeleer

@mikewheeleer mikewheeleer merged commit def12c0 into Liquifact:main Apr 1, 2026
1 check failed
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 Contract Tests for API Response Schemas

2 participants