oh-xts-build-run
Original:🇨🇳 Chinese
Translated
Combined command for OpenHarmony XTS compilation and execution. Complete the compilation and execution of XTS test projects in one stop. Use this Skill when you need to execute the full XTS test process: (1) Compile the XTS test project to generate HAP files, (2) Run the XTS test and display the results. Supports passing --package and --api parameters to the execution phase.
2installs
Added on
NPX Install
npx skill4agent add openharmonyinsight/openharmony-skills oh-xts-build-runTags
Translated version includes tags in frontmatterSKILL.md Content (Chinese)
View Translation Comparison →OpenHarmony XTS Compilation and Execution
This Skill combines XTS compilation () and execution () into a complete workflow.
/oh-xts-build/oh-xts-runWorkflow
-
Execute Compilation: Run
/oh-xts-build- Update List.test.ets to register test cases
- Use hvigorw to compile and generate HAP files
- Check whether the main HAP and test HAP are generated successfully
-
Judge Results:
- If compilation fails → Stop the process and return compilation errors
- If compilation succeeds → Proceed to execution
-
Execute Test Run: Run
/oh-xts-run [parameters]- Automatically parse the package name (from pack.info or module.json5)
- Run the test and parse result statistics
-
Summarize Results: Unified display of the complete output of compilation and execution
Parameters
- : Specify the package name (optional)
--package=<package-name> - : Specify the test class name (optional)
--api=<api-name>
Implementation Locations
- Compilation command:
packages/cli/src/ui/commands/ohXtsBuildCommand.ts - Execution command:
packages/cli/src/ui/commands/ohXtsRunCommand.ts - Core module:
packages/cli/src/modules/xts/build-runner.ts