Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add unit tests for existing code #132

Open
Harsh4902 opened this issue Mar 21, 2025 · 3 comments
Open

Add unit tests for existing code #132

Harsh4902 opened this issue Mar 21, 2025 · 3 comments
Labels
Milestone

Comments

@Harsh4902
Copy link

Harsh4902 commented Mar 21, 2025

Reason/Context

  • To ensure the quality of upcoming developments, we have to add unit tests for existing code.

Description

Implementation ideas

No response

@lbroudoux lbroudoux added this to the 1.0.0 milestone Mar 21, 2025
@Harsh4902 Harsh4902 changed the title Add unit tests for existing commands Add unit tests for existing code Mar 22, 2025
@Rupam-It
Copy link

Rupam-It commented Mar 28, 2025

hey @Harsh4902 ,
can you check this test file
https://github.com/Rupam-It/microcks-cli/blob/issue130/cmd/help_command_test.go!

go test ./cmd -v
=== RUN   TestHelpCommand_Execute
--- PASS: TestHelpCommand_Execute (0.00s)
PASS
ok      github.com/microcks/microcks-cli/cmd    0.002s

if okk then i will add other files also !

@Harsh4902
Copy link
Author

Harsh4902 commented Mar 28, 2025

@Rupam-It I looked at current command's files. Actually, It's not feasible to add test because we have all the functionality into the one function. So I think firstly we should take a look at this. Furthermore, we don't have to test commands, we have to test functionalities so, we don't need to test output of specific command.

@Harsh4902
Copy link
Author

@Rupam-It Any thought on this?

@Rupam-It I looked at current command's files. Actually, It's not feasible to add test because we have all the functionality into the one function. So I think firstly we should take a look at this. Furthermore, we don't have to test commands, we have to test functionalities so, we don't need to test output of specific command.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants