Skip to content

Test service-specific Framework command passthrough#8

Merged
GrahamCampbell merged 1 commit intomainfrom
pr/service-command-passthrough
Apr 26, 2026
Merged

Test service-specific Framework command passthrough#8
GrahamCampbell merged 1 commit intomainfrom
pr/service-command-passthrough

Conversation

@GrahamCampbell
Copy link
Copy Markdown
Contributor

@GrahamCampbell GrahamCampbell commented Apr 26, 2026

  • Adds regression coverage for nested service-specific Framework commands like deploy:function, deploy:list:functions, rollback:function, invoke, and invoke:local.
  • Preserves the hardened generic Framework passthrough route instead of reapplying the older command-routing rewrite.
  • Documents nested service-specific command examples in help output.
  • Preserves repeated passthrough options for documented commands like invoke local --env.

Co-authored-by: Jordan Craw <jordan.craw@hurricanecommerce.com>

Co-authored-by: Jordan Ashley Craw <27454899+rageycomma@users.noreply.github.com>
Copy link
Copy Markdown

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

Adds regression coverage and minor runtime/supporting changes to ensure Serverless Framework “service-specific passthrough” commands (including nested forms like deploy:function and invoke:local) are preserved end-to-end in Compose, and documents the nested command forms in CLI help output.

Changes:

  • Add unit tests covering nested service-specific command parsing/routing and options validation behavior.
  • Add help-output examples demonstrating nested service-specific commands.
  • Update Framework component CLI argument formatting to preserve repeated passthrough options (e.g., --env multiple times).

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated no comments.

Show a summary per file
File Description
test/unit/src/validate-options.test.js Adds regression test ensuring nested passthrough commands aren’t rejected by Compose option validation.
test/unit/src/render-help.test.js Verifies help output includes nested service-specific command examples.
test/unit/src/index.test.js Tests CLI argv parsing preserves nested commands for service:command:subcommand and --service forms.
test/unit/src/components-service.test.js Ensures nested commands are passed through to Framework services without being rewritten.
test/unit/components/framework/index.test.js Validates nested Framework commands translate to correct serverless argv; adds coverage for repeated passthrough options.
src/render-help.js Adds “Examples” section showing nested service-specific command usage.
components/framework/index.js Expands array-valued options into repeated CLI params and centralizes param formatting logic.

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

@GrahamCampbell GrahamCampbell merged commit 5a036cb into main Apr 26, 2026
7 checks passed
@GrahamCampbell GrahamCampbell deleted the pr/service-command-passthrough branch April 26, 2026 13:48
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.

2 participants