Skip to content

feat: add tests list command to show test history for a service#320

Open
mugiwaraluffy56 wants to merge 4 commits intomicrocks:masterfrom
mugiwaraluffy56:feat/tests-list-command
Open

feat: add tests list command to show test history for a service#320
mugiwaraluffy56 wants to merge 4 commits intomicrocks:masterfrom
mugiwaraluffy56:feat/tests-list-command

Conversation

@mugiwaraluffy56
Copy link
Copy Markdown
Contributor

@mugiwaraluffy56 mugiwaraluffy56 commented May 7, 2026

Closes #310.

Adds a microcks tests list <serviceRef> command that prints a table of test results for a given service, including test ID, date, runner type, tested endpoint, and pass/fail status. Supports --page and --size flags for pagination.

The implementation follows the same pattern as the existing commands: GetTestResults(serviceRef string, page, size int) added to the MicrocksClient interface and implementation, calling GET /api/tests?serviceId=<ref>&page=<n>&size=<n>. Also adds RunnerType to TestResultSummary since the field is returned by the API but was not previously mapped.

Four httptest-based tests cover the normal case, empty results, pagination params, and invalid JSON response.

microcks tests list output

Signed-off-by: puneeth_aditya_5656 <myakampuneeth@gmail.com>
Signed-off-by: puneeth_aditya_5656 <myakampuneeth@gmail.com>
Signed-off-by: puneeth_aditya_5656 <myakampuneeth@gmail.com>
Signed-off-by: puneeth_aditya_5656 <myakampuneeth@gmail.com>
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.

feat: add tests list command to show test history for a service

1 participant