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 pkg unit tests and mock dependencies #1992

Merged
merged 1 commit into from Feb 2, 2019

Conversation

saschagrunert
Copy link
Member

This commit adds mocking capabilities via gomock and includes unit tests
for the pkg package of cri-o.

@k8s-ci-robot k8s-ci-robot added the size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. label Jan 3, 2019
@k8s-ci-robot k8s-ci-robot added cncf-cla: yes needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Jan 3, 2019
@k8s-ci-robot
Copy link
Contributor

Hi @saschagrunert. Thanks for your PR.

I'm waiting for a kubernetes-sigs or kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-ci-robot
Copy link

Hi @saschagrunert. Thanks for your PR.

I'm waiting for a kubernetes-sigs or openshift member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@saschagrunert saschagrunert force-pushed the pkg-unit-tests-and-mocks branch 4 times, most recently from 56e06bf to 9b94360 Compare January 3, 2019 11:42
@TomSweeneyRedHat
Copy link
Contributor

/ok-to-test

@openshift-ci-robot openshift-ci-robot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Jan 3, 2019
@saschagrunert
Copy link
Member Author

/test kata-containers

@rhatdan
Copy link
Contributor

rhatdan commented Jan 4, 2019

/retest

@saschagrunert
Copy link
Member Author

saschagrunert commented Jan 4, 2019

@rhatdan I'm wondering if there anything I can do to fix the jenkins error ERROR: kata-log-parser: no log records to process?

@rhatdan
Copy link
Contributor

rhatdan commented Jan 4, 2019

I think @sameo reported that they were working to fix the kata-containers issues.

@saschagrunert
Copy link
Member Author

/test kata-containers

@saschagrunert
Copy link
Member Author

/test all

@vrothberg
Copy link
Member

@saschagrunert, the kata tests are flaky, so we can ignore them (for now).

@saschagrunert
Copy link
Member Author

saschagrunert commented Jan 7, 2019

Okay cool, I just rebased to the latest master to see if everything works as intended.
So please TAL again.

@saschagrunert saschagrunert force-pushed the pkg-unit-tests-and-mocks branch 2 times, most recently from 26d8e48 to 980de65 Compare January 18, 2019 10:34
@saschagrunert
Copy link
Member Author

@vrothberg
Copy link
Member

During my latest rebase I had to add two new test cases for the latest GetImageService() modifications:
[...]
Please have a look again

Awesome, thanks! Will have a look now.

@vrothberg
Copy link
Member

LGTM, @runcom @mrunalp, PTAL

@runcom
Copy link
Member

runcom commented Jan 18, 2019

I'm having a look at this today! @saschagrunert sorry if it took so long but great work, much appreciated!

@saschagrunert
Copy link
Member Author

/test all

@saschagrunert
Copy link
Member Author

/test e2e_features_rhel

@saschagrunert
Copy link
Member Author

/test e2e_rhel

@saschagrunert
Copy link
Member Author

@runcom I don't want to put the pressure to high so see this as a friendly ping :)

@runcom
Copy link
Member

runcom commented Jan 28, 2019

Yes! No worry for the ping, just got home from conference (on the train home actually lol), this will be the week we'll merge this no worry :)

This commit adds mocking capabilities via gomock and includes unit tests
for the `pkg` package of cri-o.

Signed-off-by: Sascha Grunert <sgrunert@suse.com>
@saschagrunert
Copy link
Member Author

/test all

@saschagrunert
Copy link
Member Author

/test e2e_rhel

@saschagrunert
Copy link
Member Author

@runcom I rebased on top of the latest master including the vendoring changes. I also added the whitelist for gomock. In the end it seems that some packages get removed nevertheless (see diff).

@saschagrunert
Copy link
Member Author

/test e2e_fedora

@saschagrunert
Copy link
Member Author

/retest

@mrunalp
Copy link
Member

mrunalp commented Feb 1, 2019

@saschagrunert I intend to make a final pass and get this in tomorrow.

@saschagrunert
Copy link
Member Author

@saschagrunert I intend to make a final pass and get this in tomorrow.

That would be really awesome, thank you very much!

@mrunalp
Copy link
Member

mrunalp commented Feb 2, 2019

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Feb 2, 2019
@mrunalp
Copy link
Member

mrunalp commented Feb 2, 2019

/approve

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: mrunalp, saschagrunert

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Feb 2, 2019
@k8s-ci-robot k8s-ci-robot merged commit 1023cb9 into cri-o:master Feb 2, 2019
@saschagrunert saschagrunert deleted the pkg-unit-tests-and-mocks branch February 4, 2019 07:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

9 participants