title: Add Network Failure Injection Tests for Wallet Submission and Polling
Description:
Introduce failure injection tests covering RPC outages, Horizon timeouts, dropped responses, and flaky wallet signing to harden the integration layer.
Requirements and Context:
- Real production failures are usually transient or partial
- Current tests focus more on happy path than degraded conditions
- Must cover submission, confirmation polling, and backend event fetch loops
Suggested Execution:
Fork and Branch
git checkout -b test/network-failure-injection
Implement Changes::
Files to Edit:
frontend/src/services/stellar.service.ts - Make transport failures injectable in tests
frontend/src/services/transactionMonitor.ts - Add deterministic backoff hooks for tests
backend/src/services/stellarEventListener.ts - Support mocked failure responses
Files to Create:
frontend/src/services/__tests__/stellar-network-failure.test.ts - Frontend failure tests
backend/src/__tests__/stellarEventListener.failure-injection.test.ts - Backend polling failure tests
Test
- Verify retries happen for transient network errors
- Verify terminal failures stop cleanly
- Verify user-facing errors remain actionable
Commit
git add .
git commit -m "test(integration): add network failure injection coverage"
Guidelines:
- Use deterministic timers in tests
- Exercise both retryable and non-retryable error classes
title: Add Network Failure Injection Tests for Wallet Submission and Polling
Description:
Introduce failure injection tests covering RPC outages, Horizon timeouts, dropped responses, and flaky wallet signing to harden the integration layer.
Requirements and Context:
Suggested Execution:
Fork and Branch
git checkout -b test/network-failure-injectionImplement Changes::
Files to Edit:
frontend/src/services/stellar.service.ts- Make transport failures injectable in testsfrontend/src/services/transactionMonitor.ts- Add deterministic backoff hooks for testsbackend/src/services/stellarEventListener.ts- Support mocked failure responsesFiles to Create:
frontend/src/services/__tests__/stellar-network-failure.test.ts- Frontend failure testsbackend/src/__tests__/stellarEventListener.failure-injection.test.ts- Backend polling failure testsTest
Commit
git add .git commit -m "test(integration): add network failure injection coverage"Guidelines: