fix: log referral completion errors - #81
Merged
Merged
Conversation
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Referrer gets "Referral Completed!" / "Indicacao Concluida!" notification - Referred user gets "You earned a coupon!" / "Voce ganhou um cupom!" notification - Both users now receive a 10% discount coupon (previously only referrer) - Notifications use user's language preference (en/pt-BR) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
thomasluizon
added a commit
that referenced
this pull request
Jun 4, 2026
The auth rate-limit (5/min, partitioned by user) is shared across every step-up and verify call. StepUpVerify_ExceedsAuthRateLimit deliberately exhausts it, and as a sibling of the other pending-ops tests on the same class-wide account that bled 429s into them whenever they shared a clock-minute. Move it into a dedicated nested RateLimitTests class with its own IAsyncLifetime and its own registered account so the exhausted bucket is isolated. Shared seeding helpers become static and parameterized. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
thomasluizon
added a commit
that referenced
this pull request
Jun 5, 2026
Add PendingOperationsControllerTests driving the full agent confirmation flow over real HTTP against Postgres: confirm -> step-up -> step-up/verify -> execute, anchored on the api_keys.manage (StepUp) capability. Adds a capturing IEmailService fake (CapturingEmailService) to the test factory via ConfigureTestServices so the step-up code (emailed only) is readable by the test. Asserts confirmation-token persistence, step-up challenge issuance + 60s service cooldown, valid/invalid code verification, the auth rate limiter on repeated verifies, execute-time step_up_required enforcement, and the full happy path creating a real API key. Refs thomasluizon/orbit-ui-mobile#81 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
thomasluizon
added a commit
that referenced
this pull request
Jun 5, 2026
The auth rate-limit (5/min, partitioned by user) is shared across every step-up and verify call. StepUpVerify_ExceedsAuthRateLimit deliberately exhausts it, and as a sibling of the other pending-ops tests on the same class-wide account that bled 429s into them whenever they shared a clock-minute. Move it into a dedicated nested RateLimitTests class with its own IAsyncLifetime and its own registered account so the exhausted bucket is isolated. Shared seeding helpers become static and parameterized. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
thomasluizon
added a commit
that referenced
this pull request
Jun 5, 2026
…) (#178) * test(api): HTTP integration tests for pending-operations endpoints (#81) Add PendingOperationsControllerTests driving the full agent confirmation flow over real HTTP against Postgres: confirm -> step-up -> step-up/verify -> execute, anchored on the api_keys.manage (StepUp) capability. Adds a capturing IEmailService fake (CapturingEmailService) to the test factory via ConfigureTestServices so the step-up code (emailed only) is readable by the test. Asserts confirmation-token persistence, step-up challenge issuance + 60s service cooldown, valid/invalid code verification, the auth rate limiter on repeated verifies, execute-time step_up_required enforcement, and the full happy path creating a real API key. Refs thomasluizon/orbit-ui-mobile#81 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * test(api): isolate step-up rate-limit test to its own user (#81) The auth rate-limit (5/min, partitioned by user) is shared across every step-up and verify call. StepUpVerify_ExceedsAuthRateLimit deliberately exhausts it, and as a sibling of the other pending-ops tests on the same class-wide account that bled 429s into them whenever they shared a clock-minute. Move it into a dedicated nested RateLimitTests class with its own IAsyncLifetime and its own registered account so the exhausted bucket is isolated. Shared seeding helpers become static and parameterized. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Test Plan
🤖 Generated with Claude Code