Skip to content

test(assets): add unit tests for transfer subcommand - #49

Open
iborazzi wants to merge 1 commit into
ProjectOpenSea:mainfrom
iborazzi:test/add-tests-for-assets-transfer
Open

test(assets): add unit tests for transfer subcommand#49
iborazzi wants to merge 1 commit into
ProjectOpenSea:mainfrom
iborazzi:test/add-tests-for-assets-transfer

Conversation

@iborazzi

Copy link
Copy Markdown

Description

Adds unit test coverage for assetsCommand's transfer subcommand in src/commands/assets.ts, which previously had no tests.

Details

  • Tests that the command registers the transfer subcommand correctly.
  • Tests that a valid --body JSON file is read and POSTed to /api/v2/assets/transfer.
  • Tests error handling when the --body file does not exist.
  • Tests error handling when the --body file contains invalid JSON.

All 362 tests pass locally (npx vitest run), including the 4 new tests.

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.

1 participant