Skip to content

test: resolves issues #27 and #25 - add availableCurrencies unit test and RouteList component tests - #62

Merged
ToryMic merged 1 commit into
BreachDirect:mainfrom
Max-Owolabi:issue-27-25
Aug 10, 2026
Merged

test: resolves issues #27 and #25 - add availableCurrencies unit test and RouteList component tests#62
ToryMic merged 1 commit into
BreachDirect:mainfrom
Max-Owolabi:issue-27-25

Conversation

@Max-Owolabi

Copy link
Copy Markdown
Contributor

Summary

Resolves #27 and #25 — adds the missing test coverage for availableCurrencies() and RouteList.

Changes

  • tests/availableCurrencies.test.js (Add a unit test for availableCurrencies() #27): verifies availableCurrencies() returns a deduplicated, sorted list of every currency appearing in mockAnchors as fromCurrency or toCurrency (including an exact-match assertion for the current dataset).
  • tests/RouteList.test.jsx (Add component tests for RouteList #25): covers the three required cases — searched=false renders nothing, searched=true with empty routes shows the no-route message, and populated routes render one card per route.
  • CHANGELOG.md: entries under Unreleased.

Verification

  • npm test passes (23/23 across 4 test files, including the 8 new tests).

@ToryMic
ToryMic merged commit c08ab5b into BreachDirect:main Aug 10, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add a unit test for availableCurrencies()

2 participants