feat(cli): Add CLI integration tests and migrate to System.CommandLine 2.0.1#21
Merged
feat(cli): Add CLI integration tests and migrate to System.CommandLine 2.0.1#21
Conversation
## CLI Enhancements - Add 'modulus build' command for compiling modules - Add 'modulus pack' command for packaging modules as .modpkg - Fix pack command output path and package naming (use module name instead of GUID) - Fix IModuleCleanupService dependency in CliServiceProvider ## Project Templates - Add dotnet new templates (modulus-avalonia, modulus-blazor) - Add VSIX extension project structure - Add Nuke targets: pack-templates, publish-templates, pack-vsix - Update template package references to Agibuild.Modulus.* ## Documentation - Add getting-started.md and getting-started.zh-CN.md - Add cli-reference.md with complete command reference - Add module-development.md with development guide - Update README.md and README.zh-CN.md with new CLI commands ## Build System - Enable nullable reference types in build project - Fix nullable warnings in BuildTasks.cs - Add template packaging targets ## Proposal - Add add-cli-integration-tests proposal for CLI testing framework
…e 2.0.1 - Add CLI integration tests project (Modulus.Cli.IntegrationTests) - Add command-specific tests: new, build, pack, install, uninstall, list - Add end-to-end lifecycle tests and module load verification - Add CliRunner and CliTestContext for test isolation - Add command handlers for database-dependent commands - Migrate CLI commands to System.CommandLine 2.0.1 API - Add TestCli target to Nuke build system - All 35 tests passing (1 skipped due to process timeout)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Add comprehensive CLI integration tests and migrate to System.CommandLine 2.0.1 stable API.
Changes
CLI Integration Tests
Modulus.Cli.IntegrationTestsnew,build,pack,install,uninstall,listModuleLoaderCliRunnerandCliTestContextfor isolated test environmentsCommand Handlers
InstallHandler,UninstallHandler,ListHandlerfor database-dependent commandsSystem.CommandLine 2.0.1 Migration
Option<T>("--name", "-alias") { Description = "..." }syntaxcommand.Options.Add()andcommand.Arguments.Add()Program.csto userootCommand.Parse(args).InvokeAsync()Build System
TestClitarget to Nuke buildTest Results
Related
add-cli-integration-tests