Skip to content

fix: recovery event coverage, decoder test, transfer_from doc, validation reference stability - #731

Merged
abore9769 merged 1 commit into
VERITOKEN-xx:mainfrom
Realericky:fix/issues-670-671-672-673
Sep 1, 2026
Merged

fix: recovery event coverage, decoder test, transfer_from doc, validation reference stability#731
abore9769 merged 1 commit into
VERITOKEN-xx:mainfrom
Realericky:fix/issues-670-671-672-673

Conversation

@Realericky

Copy link
Copy Markdown

Summary

  • Add a unit test asserting rwa-token's recover() emits rcv_exe with the old/new admin. Event emission itself (events::emit_recovery_executed) was already wired up in lib.rs/events.rs; this locks it in with a test per the acceptance criteria.
  • Add an eventParser test for the rcv_exe decoder to confirm oldAdmin/newAdmin mapping. The decoder was already correct; the test was missing.
  • Document in transfer_from that spender == from is an intentional, allowed pattern (no behavioral change).
  • Give useAmountValidation a small reference-stability cache so identical (value, decimals) inputs return the same result object across renders, preventing unnecessary re-renders in components that pass the result down. (Note: the function is a plain helper, not a React hook with internal state, so useCallback/useMemo weren't usable directly — the existing test suite calls it outside a render context by design.)

Test plan

  • cargo test -p rwa-token --features testutils
  • npm test in sdk
  • npm test in frontend

Closes #670
Closes #671
Closes #672
Closes #673

…tion reference stability

- Add a unit test asserting rwa-token's recover() emits rcv_exe with the
  old/new admin (event emission itself was already wired up).
- Add an eventParser rcv_exe decoder test to lock in the oldAdmin/newAdmin
  mapping (decoder itself was already correct).
- Document that transfer_from intentionally allows spender == from.
- Give useAmountValidation a small reference-stability cache so identical
  (value, decimals) inputs return the same result object across renders.

Closes VERITOKEN-xx#670
Closes VERITOKEN-xx#671
Closes VERITOKEN-xx#672
Closes VERITOKEN-xx#673
@drips-wave

drips-wave Bot commented Aug 30, 2026

Copy link
Copy Markdown

@Realericky 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

@abore9769
abore9769 merged commit e52184a into VERITOKEN-xx:main Sep 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment