Skip to content

Refactor CSI Translation Library into a struct that is injected into various components to simplify unit testing #82683

Merged
k8s-ci-robot merged 1 commit intokubernetes:masterfrom
davidz627:fix/translationStruct
Sep 29, 2019
Merged

Refactor CSI Translation Library into a struct that is injected into various components to simplify unit testing #82683
k8s-ci-robot merged 1 commit intokubernetes:masterfrom
davidz627:fix/translationStruct

Conversation

@davidz627
Copy link
Copy Markdown
Contributor

@davidz627 davidz627 commented Sep 13, 2019

Fixes: #82670

An example of a unit test possible with this new struct: kubernetes-csi/external-provisioner#343

/kind cleanup
/priority important-soon
/sig storage
/assign @ddebroy @jsafrane @msau42
/cc @ddebroy @leakingtapan @saad-ali @shanesiebken

NONE

@k8s-ci-robot k8s-ci-robot added the release-note-none Denotes a PR that doesn't merit a release note. label Sep 13, 2019
@k8s-ci-robot k8s-ci-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release. sig/storage Categorizes an issue or PR as relevant to SIG Storage. labels Sep 13, 2019
@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Sep 13, 2019
@k8s-ci-robot
Copy link
Copy Markdown
Contributor

@davidz627: GitHub didn't allow me to request PR reviews from the following users: shanesiebken.

Note that only kubernetes members and repo collaborators can review this PR, and authors cannot review their own PRs.

Details

In response to this:

An example of a unit test possible with this new struct: kubernetes-csi/external-provisioner#343
/kind cleanup
/priority important-soon
/sig storage
/assign @ddebroy @jsafrane @msau42
/cc @ddebroy @leakingtapan @saad-ali @shanesiebken

NONE

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.

@k8s-ci-robot k8s-ci-robot added area/kubelet area/test sig/api-machinery Categorizes an issue or PR as relevant to SIG API Machinery. sig/apps Categorizes an issue or PR as relevant to SIG Apps. sig/node Categorizes an issue or PR as relevant to SIG Node. sig/scheduling Categorizes an issue or PR as relevant to SIG Scheduling. sig/testing Categorizes an issue or PR as relevant to SIG Testing. labels Sep 13, 2019
@davidz627 davidz627 force-pushed the fix/translationStruct branch from 822a546 to c7af1d4 Compare September 13, 2019 01:03
Copy link
Copy Markdown
Contributor

@ddebroy ddebroy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is great! Couple of comments

Copy link
Copy Markdown

@misterikkit misterikkit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR mostly LGTM. I think I will have more comments/opinions on the fake impl of the translator interface. I'll leave those comments on your WIP PR.

@davidz627 davidz627 force-pushed the fix/translationStruct branch from c7af1d4 to 481c79f Compare September 17, 2019 00:15
@davidz627
Copy link
Copy Markdown
Contributor Author

@misterikkit @jsafrane @ddebroy Thanks for your reviews! I've updated the PR, PTAL

@davidz627 davidz627 force-pushed the fix/translationStruct branch 2 times, most recently from 523c447 to 1e85565 Compare September 17, 2019 18:22
@davidz627
Copy link
Copy Markdown
Contributor Author

/test pull-kubernetes-e2e-gce-100-performance

Copy link
Copy Markdown

@misterikkit misterikkit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Sep 19, 2019
@davidz627
Copy link
Copy Markdown
Contributor Author

/assign @saad-ali @jsafrane @mikedanese
for approval

Copy link
Copy Markdown
Member

@saad-ali saad-ali left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/approve

@davidz627 davidz627 force-pushed the fix/translationStruct branch from 6c99c64 to 9e37967 Compare September 27, 2019 00:22
@k8s-ci-robot k8s-ci-robot removed the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Sep 27, 2019
@davidz627 davidz627 force-pushed the fix/translationStruct branch from 9e37967 to 5e06e7e Compare September 27, 2019 00:24
@davidz627
Copy link
Copy Markdown
Contributor Author

/assign @ahg-g @Huang-Wei
for scheduler approval

@Huang-Wei
Copy link
Copy Markdown
Member

/approve
on the scheduling part.

You have to make CI happy:

pkg/scheduler/algorithm/predicates/csi_volume_predicate.go:34:6: exported type InTreeToCSITranslator should have comment or be unexported

…various components to simplify unit testing in future
@davidz627 davidz627 force-pushed the fix/translationStruct branch from 5e06e7e to 92cb06a Compare September 27, 2019 20:00
@davidz627
Copy link
Copy Markdown
Contributor Author

/retest

@mikedanese
Copy link
Copy Markdown
Member

/approve

@k8s-ci-robot
Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: davidz627, Huang-Wei, mikedanese, saad-ali

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

The pull request process is described here

Details 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 Sep 29, 2019
@mikedanese
Copy link
Copy Markdown
Member

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Sep 29, 2019
@k8s-ci-robot k8s-ci-robot merged commit 14e5adf into kubernetes:master Sep 29, 2019
@k8s-ci-robot k8s-ci-robot added this to the v1.17 milestone Sep 29, 2019
@davidz627 davidz627 deleted the fix/translationStruct branch September 30, 2019 17:56
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. area/kubelet area/test cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. lgtm "Looks good to me", indicates that a PR is ready to be merged. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release. release-note-none Denotes a PR that doesn't merit a release note. sig/api-machinery Categorizes an issue or PR as relevant to SIG API Machinery. sig/apps Categorizes an issue or PR as relevant to SIG Apps. sig/node Categorizes an issue or PR as relevant to SIG Node. sig/scheduling Categorizes an issue or PR as relevant to SIG Scheduling. sig/storage Categorizes an issue or PR as relevant to SIG Storage. sig/testing Categorizes an issue or PR as relevant to SIG Testing. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add Mock Driver to csi translation library to support unit testing

10 participants