Skip to content

Comments

refactor: CLI tests#61

Merged
macterra merged 5 commits intomainfrom
60-refactor-cli-tests
Feb 11, 2026
Merged

refactor: CLI tests#61
macterra merged 5 commits intomainfrom
60-refactor-cli-tests

Conversation

@macterra
Copy link
Collaborator

No description provided.

@macterra macterra linked an issue Feb 11, 2026 that may be closed by this pull request
@coveralls
Copy link

coveralls commented Feb 11, 2026

Pull Request Test Coverage Report for Build 21923380512

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 95.469%

Totals Coverage Status
Change from base Build 21921283514: 0.0%
Covered Lines: 3311
Relevant Lines: 3404

💛 - Coveralls

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Refactors the CLI end-to-end test suite by replacing the legacy Expect/TCL scripts with Jest + TypeScript tests that drive the CLI through docker compose exec, and updates CI to run the new test target.

Changes:

  • Removed the Expect-based CLI test runner and individual .expect test scripts.
  • Added Jest/TypeScript CLI tests under tests/cli/ plus shared docker/CLI helpers.
  • Added a dedicated Jest config + npm script for CLI tests and updated the GitHub Actions workflow to run them.

Reviewed changes

Copilot reviewed 43 out of 44 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
tests/run_cli_tests.sh Removed legacy Expect runner script.
tests/cli/wallet.test.ts Adds Jest CLI tests for wallet commands (new/show/check mnemonic).
tests/cli/schema.test.ts Adds Jest CLI tests for schema creation/list/get/template.
tests/cli/id.test.ts Adds Jest CLI tests for ID lifecycle (create/list/remove/resolve/backup/recover/rotate).
tests/cli/helpers.ts Adds shared helpers to execute CLI/admin via docker compose exec and parse DIDs.
tests/cli/help.test.ts Adds Jest CLI tests validating help output and ordering.
tests/cli/encryption.test.ts Adds Jest CLI test for encrypt-file.
tests/cli/credential.test.ts Adds Jest CLI tests for issuing/accepting/publishing/revealing/revoking credentials, with container file setup.
tests/cli/alias.test.ts Adds Jest CLI tests for alias add/list/remove.
tests/cli-tests/test_cli_validate_help.expect Removed legacy Expect-based help validation.
tests/cli-tests/test_cli_show_wallet.expect Removed legacy Expect-based show-wallet validation.
tests/cli-tests/test_cli_show_mnemonic.expect Removed legacy Expect-based show-mnemonic validation.
tests/cli-tests/test_cli_rotate_keys.expect Removed legacy Expect-based rotate-keys validation.
tests/cli-tests/test_cli_revoke_credentials.expect Removed legacy Expect-based revoke-credential validation.
tests/cli-tests/test_cli_reveal_credentials.expect Removed legacy Expect-based reveal-credential validation.
tests/cli-tests/test_cli_resolve_id.expect Removed legacy Expect-based resolve-id validation.
tests/cli-tests/test_cli_remove_id.expect Removed legacy Expect-based remove-id validation.
tests/cli-tests/test_cli_remove_alias.expect Removed legacy Expect-based remove-alias validation.
tests/cli-tests/test_cli_recover_id.expect Removed legacy Expect-based recover-id validation.
tests/cli-tests/test_cli_publish_credential.expect Removed legacy Expect-based publish-credential validation.
tests/cli-tests/test_cli_list_schema.expect Removed legacy Expect-based list-schemas validation.
tests/cli-tests/test_cli_list_issue_credentials.expect Removed legacy Expect-based list-issued/list-credentials flow validation.
tests/cli-tests/test_cli_list_dids.expect Removed legacy Expect-based list-ids validation.
tests/cli-tests/test_cli_list_credentials.expect Removed legacy Expect-based list-credentials validation.
tests/cli-tests/test_cli_list_aliases.expect Removed legacy Expect-based list-aliases validation.
tests/cli-tests/test_cli_issue_credential.expect Removed legacy Expect-based issue-credential validation.
tests/cli-tests/test_cli_get_schema.expect Removed legacy Expect-based get-schema validation.
tests/cli-tests/test_cli_get_credential_by_id.expect Removed legacy Expect-based get-credential validation.
tests/cli-tests/test_cli_encrypt_file.expect Removed legacy Expect-based encrypt-file validation.
tests/cli-tests/test_cli_create_wallet.expect Removed legacy Expect-based create-wallet/new-wallet validation.
tests/cli-tests/test_cli_create_schema_template.expect Removed legacy Expect-based create-schema-template validation.
tests/cli-tests/test_cli_create_schema.expect Removed legacy Expect-based create-schema validation.
tests/cli-tests/test_cli_create_id.expect Removed legacy Expect-based create-id validation.
tests/cli-tests/test_cli_check_wallet.expect Removed legacy Expect-based check-wallet validation.
tests/cli-tests/test_cli_check_list_ids.expect Removed legacy Expect-based list-ids validation.
tests/cli-tests/test_cli_backup_id.expect Removed legacy Expect-based backup-id validation.
tests/cli-tests/test_cli_add_alias.expect Removed legacy Expect-based add-alias validation.
tests/cli-tests/README.md Removed legacy documentation specific to the Expect-based runner.
test.env Adds a committed env file intended for tests/CI configuration.
package.json Adds test:cli script to run the dedicated CLI Jest suite.
jest.config.js Excludes tests/cli/ from the default Jest run.
jest.config.cli.js Adds dedicated Jest configuration for CLI tests.
.github/workflows/docker-build-test.yml Updates CI to install Node deps and run npm run test:cli instead of Expect-based scripts.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@macterra macterra merged commit 51f6838 into main Feb 11, 2026
13 checks passed
@macterra macterra deleted the 60-refactor-cli-tests branch February 11, 2026 21:24
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.

Replace expect CLI tests with vitest + child_process

2 participants