Skip to content

Add unit tests for wallet address truncation helper #559

Description

@Chucks1093

Summary

The wallet address truncation helper (first 4 + last 4 characters with ellipsis) is used in the header and on profile pages but has no unit tests. Tests should cover standard addresses, edge cases, and the full address passthrough when the address is shorter than the truncation threshold.

Scope

  • Test a standard 56-character Stellar address returns GABCD...WXYZ format
  • Test an address shorter than 8 characters is returned as-is without truncation
  • Test an empty string input returns an empty string
  • Test the separator character is (ellipsis) not three dots

Acceptance Criteria

  • Standard address truncated to first 4 + last 4 with ellipsis
  • Short address returned as-is
  • Empty string handled without error
  • Separator is a single ellipsis character

ETA: 12 hours


Coordinate on Telegram

Metadata

Metadata

Assignees

Labels

Stellar WaveIssues in the Stellar wave program

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions