Skip to content

test(clients): clear the client SonarCloud code smells - #1819

Merged
HuiJun merged 1 commit into
developfrom
fix/sonar-clients
Nov 1, 2026
Merged

HuiJun merged 1 commit into
developfrom
fix/sonar-clients

Conversation

@devin-ai-integration

Copy link
Copy Markdown
Contributor

What and why

Clears the three SonarCloud code smells on develop in the clients:

  • java:S5778 ApiIntegrationTest.java:746 and :749 — each assertThrows lambda built its ExecutionOptions with withEvents("Go") and then called the method under test. withEvents is a pure constructor, so it is hoisted into a named local before the assertion, leaving the lambda with only the invocation the test expects to throw. The assertions are unchanged.

Dispositions

  • python:S107 client/python/opensysml/__init__.py convert (14 parameters) — the module-level convert takes Connection.convert's public keyword arguments plus the service's host and port; reducing the count would break the published Python API. Recorded as the named multicriteria entry convertKeywords (ruleKey=python:S107, resourceKey=client/python/opensysml/__init__.py) in sonar-project.properties, with the one-line reason in its comment block, beside the existing keywordAuthoring/keywordChecking/wireRecord entries.

No behaviour change, no changelog fragment.

How it was verified

  • make build-grpc; Java client Maven tests: ApiIntegrationTest 92 run, 0 failures, 0 skipped; module 356 run, 0 failures, 1 skipped (pre-existing); conformance module 37 pass
  • go build ./... (no Go change)
  • SonarQube analyze_code_snippet (java, TEST) does not reproduce S5778 on develop either, so the two lambdas were checked by inspection: each now contains a single call. The Python disposition takes effect in develop's branch analysis (the snippet analyzer does not read sonar-project.properties).

Checklist

  • make test and make lint pass locally (Java client tests, Go build)
  • Tests added or updated for the change (n/a: test refactor, assertions unchanged)
  • Documentation extended where it already covers the surface (n/a)
  • Changelog entry added (n/a: refactor only)
  • baselines regenerated (n/a)
  • No internal work-item labels in the body, docs, or changelog

Link to Devin session: https://nasa-jpl-demo.devinenterprise.com/sessions/d6cd1346a2844bb0aa32b31cc438fc6b
Open in Devin Desktop: https://nasa-jpl-demo.devinenterprise.com/desktop/session/d6cd1346a2844bb0aa32b31cc438fc6b?variant=devin
Requested by: @HuiJun

Co-Authored-By: jason.han <hanhuijun@gmail.com>
@devin-ai-integration

Copy link
Copy Markdown
Contributor Author

I'll fix CI failures and address comments from users with write access. I'll skip comments containing "(aside)".

  • Disable automatic comment, CI, and merge conflict monitoring

@devin-ai-integration
devin-ai-integration Bot marked this pull request as ready for review November 1, 2026 06:27

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no bugs or issues to report.

Devin Review

@HuiJun
HuiJun merged commit ea9429f into develop Nov 1, 2026
53 checks passed
@HuiJun
HuiJun deleted the fix/sonar-clients branch November 1, 2026 13:44
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.

1 participant