microcks / microcks/microcks-cli
Cleanup: CreateTestResult payload construction and minor typo in cmd
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 52
- Forks
- 68
- Avg merge
- 6h 54m
- Merged PRs (30d)
- 10
Description
I found the code in pkg/connectors/microcks_client.go and see that the CreateTestResult function is creating the JSON body using string concatenation. A little brittle and difficult to add more fields to the test request later on.
Also, I noticed that in cmd/cmd.go, the main entry point is called NewCommad (and not NewCommand).
I'm happy to put together a PR to:
Utilise a correct struct and json.Marshal test request payload.
Correct the typo in the NewCommad package and main.go in the CLI.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with pkg/connectors/microcks_client.go and inspect CreateTestResult's JSON payload construction, then check cmd/cmd.go and main.go for the NewCommad entry point. The work is complete when the test request uses a struct marshaled with json.Marshal and the CLI entry point consistently uses the corrected NewCommand name.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- api, cli
- Issue type
- Refactor
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Quiet
- Clarity
- Clearly specified
- Newbie friendliness
- 76/100