Skip to content

fix: cover diagnostic contract id conversion - #561

Merged
Glittersup merged 1 commit into
TricklePay:mainfrom
iyanukid2008-pixel:fix/issue-499
Oct 26, 2026
Merged

Glittersup merged 1 commit into
TricklePay:mainfrom
iyanukid2008-pixel:fix/issue-499

Conversation

@iyanukid2008-pixel

Copy link
Copy Markdown
Contributor

Summary

  • Add a regression test using a real xdr.DiagnosticEvent to verify the diagnostic contract hash is converted to the expected C-address in the extracted failure string.
  • Log unexpected diagnostic XDR parsing failures at debug level instead of silently swallowing them.
  • The explicit Buffer conversion that satisfies StrKey.encodeContract is present in the current base; this change adds regression coverage for its runtime behavior.

Closes #499

Validation

  • npx vitest run lib/contract-confirm.test.ts passed (2 tests).
  • npm run typecheck passed.
  • npm run lint passed with 7 existing warnings.
  • NEXT_PUBLIC_MOCK_API=true npm run build passed.
  • npm test reported 45 failing tests across 10 files and 911 passing tests; failures are outside the new test file and cover existing app/configuration, fixture, and RPC-mock tests.

@Glittersup
Glittersup merged commit 443358e into TricklePay:main Oct 26, 2026
2 checks 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.

Convert the contract id to the type StrKey.encodeContract expects

2 participants