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

Increase unit test coverage of pkg/cloud/aws/actuators/machine #122

Merged
merged 9 commits into from
Dec 19, 2018
Merged

Increase unit test coverage of pkg/cloud/aws/actuators/machine #122

merged 9 commits into from
Dec 19, 2018

Conversation

ingvagabund
Copy link
Member

@ingvagabund ingvagabund commented Dec 7, 2018

Increase unit test coverage before:

  • sigs.k8s.io/cluster-api-provider-aws/pkg/cloud/aws/actuators/machine/actuator.go (62.1%)
  • sigs.k8s.io/cluster-api-provider-aws/pkg/cloud/aws/actuators/machine/awsclient.go (0.0%)
  • sigs.k8s.io/cluster-api-provider-aws/pkg/cloud/aws/actuators/machine/instances.go (52.9%)
  • sigs.k8s.io/cluster-api-provider-aws/pkg/cloud/aws/actuators/machine/loadbalancers.go (18.4%)
  • sigs.k8s.io/cluster-api-provider-aws/pkg/cloud/aws/actuators/machine/utils.go (53.9%)

Increase unit test coverage after:

  • sigs.k8s.io/cluster-api-provider-aws/pkg/cloud/aws/actuators/machine/actuator.go (91.6%)
  • sigs.k8s.io/cluster-api-provider-aws/pkg/cloud/aws/actuators/machine/awsclient.go (100.0%)
  • sigs.k8s.io/cluster-api-provider-aws/pkg/cloud/aws/actuators/machine/instances.go (91.2%)
  • sigs.k8s.io/cluster-api-provider-aws/pkg/cloud/aws/actuators/machine/loadbalancers.go (91.8%)
  • sigs.k8s.io/cluster-api-provider-aws/pkg/cloud/aws/actuators/machine/stubs.go (100.0%)
  • sigs.k8s.io/cluster-api-provider-aws/pkg/cloud/aws/actuators/machine/utils.go (76.5%)

Goal:

  • get coverage of each package above 90%

Current:

$ go test -race -cover ./pkg/cloud/aws/actuators/machine...
ok  	sigs.k8s.io/cluster-api-provider-aws/pkg/cloud/aws/actuators/machine	1.139s	coverage: 90.1% of statements

@openshift-ci-robot openshift-ci-robot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. labels Dec 7, 2018
@ingvagabund ingvagabund requested review from frobware and enxebre and removed request for frobware December 7, 2018 22:29
@ingvagabund ingvagabund requested review from frobware and removed request for bison December 7, 2018 22:29
@openshift-ci-robot openshift-ci-robot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. and removed size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. labels Dec 15, 2018
@ingvagabund ingvagabund changed the title WIP: Increase unit test coverage of pkg/cloud/aws/actuators/machine Increase unit test coverage of pkg/cloud/aws/actuators/machine Dec 15, 2018
@openshift-ci-robot openshift-ci-robot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Dec 15, 2018
@frobware
Copy link

/retest

1 similar comment
@ingvagabund
Copy link
Member Author

/retest

pkg/cloud/aws/actuators/machine/instaces_test.go Outdated Show resolved Hide resolved
pkg/cloud/aws/actuators/machine/instaces_test.go Outdated Show resolved Hide resolved
pkg/cloud/aws/actuators/machine/instaces_test.go Outdated Show resolved Hide resolved
pkg/cloud/aws/actuators/machine/instaces_test.go Outdated Show resolved Hide resolved
pkg/cloud/aws/actuators/machine/instaces_test.go Outdated Show resolved Hide resolved
pkg/cloud/aws/actuators/machine/actuator_test.go Outdated Show resolved Hide resolved
pkg/cloud/aws/actuators/machine/actuator_test.go Outdated Show resolved Hide resolved
pkg/cloud/aws/actuators/machine/actuator_test.go Outdated Show resolved Hide resolved
@ingvagabund
Copy link
Member Author

@frobware comments addressed. PTAL

@frobware
Copy link

/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Dec 19, 2018
@paulfantom
Copy link

/approve

@openshift-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: paulfantom

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

@openshift-ci-robot openshift-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Dec 19, 2018
@openshift-merge-robot openshift-merge-robot merged commit e0d0ff3 into openshift:master Dec 19, 2018
@ingvagabund ingvagabund deleted the unit-test-instances branch December 19, 2018 17:51
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. 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.

5 participants