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 move2kube-api #21

Open
ashokponkumar opened this issue Oct 2, 2020 · 9 comments
Open

Add unit tests for move2kube-api #21

ashokponkumar opened this issue Oct 2, 2020 · 9 comments
Labels
good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines.

Comments

@ashokponkumar
Copy link
Member

Use the go's unit test framework similar to https://github.com/konveyor/move2kube/blob/master/types/info/versioninfo_test.go and write unit-tests for move2kube-api.

@ashokponkumar ashokponkumar added good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines. hacktoberfest labels Oct 2, 2020
@IsabellaDev
Copy link
Contributor

I'd like to try on this, but I'm new to Golang, could you please give me some hint like which functions need a test function? I checked your sample and noticed that not all functions have a test one. Thanks.

@ashokponkumar
Copy link
Member Author

@HarikrishnanBalagopal Can you give some high level guidance on how we could test this package?

@nasirhm
Copy link

nasirhm commented Dec 28, 2022

I would like to work on this @ashokponkumar

@ashokponkumar
Copy link
Member Author

I would like to work on this @ashokponkumar

Sure @nasirhm .

@nasirhm
Copy link

nasirhm commented Jan 12, 2023

@ashokponkumar / @HarikrishnanBalagopal Looking at the types in move2kube-api, They're all available in a single types.go: https://github.com/konveyor/move2kube-api/blob/main/internal/types/types.go . Should i begin by writing unit test cases for this one ?

@ashokponkumar
Copy link
Member Author

@ashokponkumar / @HarikrishnanBalagopal Looking at the types in move2kube-api, They're all available in a single types.go: https://github.com/konveyor/move2kube-api/blob/main/internal/types/types.go . Should i begin by writing unit test cases for this one ?

@HarikrishnanBalagopal Can you please look into @nasirhm 's question.

@HarikrishnanBalagopal
Copy link
Contributor

HarikrishnanBalagopal commented Jan 17, 2023

@ashokponkumar / @HarikrishnanBalagopal Looking at the types in move2kube-api, They're all available in a single types.go: https://github.com/konveyor/move2kube-api/blob/main/internal/types/types.go . Should i begin by writing unit test cases for this one ?

Hi @nasirhm , Thanks for looking into this issue.
konveyor/move2kube#881
You can look at the above for some tutorials and steps on how to get started writing tests.

The types package you mentioned is a good place to start since it has small functions which you can test individually.
Please let us know if you get stuck.

@satyazzz123
Copy link

@ashokponkumar @HarikrishnanBalagopal can I work on this issue?

@satyazzz123
Copy link

@HarikrishnanBalagopal @ashokponkumar i have raised a PR. Please have a look

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines.
Projects
None yet
Development

No branches or pull requests

5 participants