Skip to content

test: ErrorBoundary onError callback, reset key remount, TransactionPanel Try Again pre-filled form #192

Description

@k-deejah

Problem

Three test gaps cover the ErrorBoundary onError callback, reset key behaviour, and TransactionPanel "Try again" pre-filled form.

1. ErrorBoundary onError callback and production console suppression are untested

After issue #75, no test verifies: onError is called with the error and info when a child throws, console.error is not called in prod mode (import.meta.env.DEV = false), and the default log fires in dev mode.

2. ErrorBoundary reset key prevents the error loop

No test verifies that after reset(), the children are remounted (new component instance) rather than just re-rendered — preventing the same corrupted state from immediately re-throwing.

3. TransactionPanel "Try again" preserves form field values

After issue #71, the "Try again" button returns to the idle form with dest, amount, and memo pre-filled. No test verifies these values are preserved in the form inputs after "Try again" is clicked.

Solution

Write Vitest tests for all three behaviours.

Acceptance Criteria

  • ErrorBoundary onError callback test passes
  • ErrorBoundary reset key remount test passes
  • TransactionPanel "Try again" pre-filled form test passes
  • All tests pass with npm test

Note for Contributors: Write a clear PR description. Include the full npm test output and explain how you verified the reset key triggers a remount rather than a re-render.

Metadata

Metadata

Assignees

Labels

Stellar WaveIssues in the Stellar wave programhelp wantedExtra attention is needed

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions