1
0
Fork 0
mirror of https://github.com/maybe-finance/maybe.git synced 2025-07-31 02:59:39 +02:00
Maybe/test/controllers/api/v1
Zach Gollwitzer 018310d4d1 Fix rate limiting errors in API transaction controller tests
When tests run in parallel, they were sharing the same API key fixtures
which caused Redis rate limit counters to accumulate across test workers,
leading to unexpected rate limit errors.

Changes:
- Create fresh API keys in setup instead of using fixtures
- Each API key gets a unique auto-generated ID
- Clear existing active keys to avoid validation conflicts
- Use different sources (web/mobile) for multiple test keys
- Clear Redis rate limit data in setup to ensure clean state
- Update api_headers helper to use display_key instead of plain_key

This follows the existing pattern used in UsageControllerTest for
handling API keys that interact with Redis state.
2025-07-08 11:46:33 -04:00
..
accounts_controller_test.rb Multi-step account forms + clearer balance editing (#2427) 2025-07-03 09:33:07 -04:00
auth_controller_test.rb Fix remaining rubocop offenses 2025-06-18 08:38:04 -05:00
base_controller_test.rb Add comprehensive API v1 with OAuth and API key authentication (#2389) 2025-06-17 15:57:05 -05:00
chats_controller_test.rb Fix rubocop linting issues in API chat endpoints 2025-06-18 04:36:31 -05:00
messages_controller_test.rb Fix rubocop linting issues in API chat endpoints 2025-06-18 04:36:31 -05:00
transactions_controller_test.rb Fix rate limiting errors in API transaction controller tests 2025-07-08 11:46:33 -04:00
usage_controller_test.rb Add comprehensive API v1 with OAuth and API key authentication (#2389) 2025-06-17 15:57:05 -05:00