Skip to content

feat: investor list endpoint returns commitments for funded invoice - #215

Open
Stephan-Thomas wants to merge 1 commit into
StellarState:devfrom
Stephan-Thomas:issue-180-investor-list-test
Open

feat: investor list endpoint returns commitments for funded invoice#215
Stephan-Thomas wants to merge 1 commit into
StellarState:devfrom
Stephan-Thomas:issue-180-investor-list-test

Conversation

@Stephan-Thomas

@Stephan-Thomas Stephan-Thomas commented Aug 25, 2026

Copy link
Copy Markdown

Description

Closes #180

Type of Change

  • 🐛 Bug fix (non-breaking change which fixes an issue)
  • ✨ New feature (non-breaking change which adds functionality)
  • 💥 Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • 📝 Documentation update
  • 🎨 UI/UX improvement
  • ♻️ Code refactoring
  • ✅ Test addition or update
  • 🔧 Configuration change

Checklist

  • All GitHub Actions workflows are green on this PR (required for merge)
  • Commit messages follow Conventional Commits (feat:, fix:, chore:, etc.) — enforced by CI
  • No secrets, API keys, .env, or credentials committed (see CONTRIBUTING.md)
  • My code follows the code style of this project
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • Any dependent changes have been merged and published

Testing

Added an integration test covering the investor list endpoint for a funded invoice. The test seeds multiple investor commitments and verifies that the endpoint returns all commitments with the expected wallet, amount, share percentage, and commitment timestamp. It also verifies that share percentages sum to 100% and that unauthorized sellers cannot access another seller's investor list.

How to Test

  1. Seed a funded invoice with three investor commitments using different amounts.
  2. Authenticate as the invoice owner and request the investor list endpoint.
  3. Verify all three investors are returned with the expected fields and share percentages totaling 100%.
  4. Authenticate as a different seller and request the same endpoint.
  5. Verify the request is rejected with 403 Forbidden.

Test Coverage

  • Unit tests added/updated
  • Integration tests added/updated
  • E2E tests added/updated (if applicable)
  • Manual testing completed

Screenshots (if applicable)

Not applicable — this PR adds backend integration test coverage only.

Additional Notes

The test specifically validates the response shape and investor ownership authorization to prevent regressions where commitments are missing, incorrectly calculated, or exposed to unauthorized sellers.

For Reviewers

  • Code quality and readability
  • Test coverage
  • Security implications
  • Performance impact
  • Breaking changes

@drips-wave

drips-wave Bot commented Aug 25, 2026

Copy link
Copy Markdown

@Stephan-Thomas 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

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 integration test for the investor list endpoint returning all commitments for a funded invoice

1 participant