Repository navigation
Conversation
Pull Request Test Coverage Report for Build 8380587546Details
💛 - Coveralls |
aaqilniz
marked this pull request as ready for review
March 21, 2024 19:31
samarpanB
reviewed
Mar 27, 2024
samarpanB
left a comment
Contributor
There was a problem hiding this comment.
Can you add or update a test case for this please ?
aaqilniz
marked this pull request as draft
October 18, 2026 05:17
aaqilniz
force-pushed
the
fix/push-correct-arg
branch
from
November 8, 2026 17:14
1e8dd38 to
79e4027
Compare
aaqilniz
marked this pull request as ready for review
November 8, 2026 17:27
Contributor
Author
|
Hi, @samarpanB. Can you please have a quick look at this PR whenever you get a chance? I have added the new tests and updated an existing snapshot. |
Signed-off-by: Muhammad Aaqil <aaqilcs102@gmail.com>
aaqilniz
force-pushed
the
fix/push-correct-arg
branch
from
November 8, 2026 17:40
79e4027 to
8c7dc39
Compare
This branch has not been deployed
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.
Description
Problem
When generating controllers and service methods using lb4 openapi, query or path parameters containing hyphens (e.g.,
limit-number,status-code) were emitted as raw literals inside method parameter binding calls. This resulted in invalid TypeScript code (e.g.,this.openApiService.getCustomers(limit-number, status-code)), where the TypeScript compiler interprets the hyphen as a subtraction operator rather than part of a valid identifier.Solution
Updated the OpenAPI parameter generation logic to sanitize hyphenated parameter names into
camelCaseidentifiers (argName) before they are written to the method body call arguments.Changes
Modified the parameter iteration loop in the generator to pass the resolved, sanitized
argNameto method calls instead of the rawparam.name.Added an integration test suite and specification fixture (
hyphenated-params.json) validating that hyphenated query parameters correctly map to camelCase identifiers in generated controllers without syntax regressions.Closes #11887
Checklist
npm testpasses on your machinepackages/cliwere updatedexamples/*were updated👉 Check out how to submit a PR 👈