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

[help wanted] add more unit-test for CRI #1756

Closed
26 of 38 tasks
YaoZengzeng opened this issue Jul 20, 2018 · 13 comments
Closed
26 of 38 tasks

[help wanted] add more unit-test for CRI #1756

YaoZengzeng opened this issue Jul 20, 2018 · 13 comments

Comments

@YaoZengzeng
Copy link
Contributor

YaoZengzeng commented Jul 20, 2018

Task tracking

cri/stream/httpstream.go

  • IsUpgradeRequest
  • negotiateProtocol
  • Handshake

cri/stream/remotecommand/errors.go

  • NewInternalError
  • Status
  • Error

cri/stream/errors.go

  • WriteError

cri/stream/request_cache.go

  • the whole file

cri/v1alpha1/cri_stream.go

  • toCNIPortMappings

cri/v1alpha1/cri_utils.go

  • generateMountBindings

  • modifySandboxNamespaceOptions

  • applySandboxSecurityContext

  • applySandboxLinuxOptions

  • makeSandboxPouchConfig // complete TODO

  • toCriSandbox // complete TODO

  • parseDNSOptions

  • setupSandboxFiles

  • makeContainerName // complete TODO

  • modifyContainerNamespaceOptions // complete TODO

  • getAppArmorSecurityOpts

  • getSELinuxSecurityOpts

  • getSeccompSecurityOpts

  • modifyHostConfig

  • modifyContainerConfig

  • updateCreateConfig

  • toCriContainer // compelet TODO

  • containerNetns

  • imageToCriImage // complete TODO

  • getUserFromImageUser // complete TODO

  • parseUserFromImageUser // complete TODO

  • getContainerMetrics

  • imageFSPath

  • parseWeightDeviceFromCRI

  • parseWeightDeviceFromPouch

  • parseThrottleDeviceFromCRI

  • parseThrottleDeviceFromPouch

  • parseUlimitFromCRI

  • parseUlimitFromPouch

@YaoZengzeng
Copy link
Contributor Author

@fuweid @starnop @ZouRui89 Welcome to complete the list and make it more correct :)

@YaoZengzeng
Copy link
Contributor Author

It would be so appreciate that if you would help us finish this target list.

Please declare which case you will finish under this issue to avoid conflict with others.

Thanks! 😄

@YaoZengzeng
Copy link
Contributor Author

I'll finish cri/stream/request_cache.go today.

@ZouRui89
Copy link
Contributor

If a method exists in both v1alpha1 and v1alpha2, do we write the same test cases or just leave one side blank? @YaoZengzeng

@ZouRui89
Copy link
Contributor

generateMountBindings and modifySandboxNamespaceOptions for me then.

@starnop
Copy link
Contributor

starnop commented Jul 23, 2018

@ZouRui89 I think both of them should have test cases even though the methods are actually the same. And if you find that this method can be extracted as a public method, don't hesitate to reconstruct it. Thanks :)

@starnop
Copy link
Contributor

starnop commented Jul 23, 2018

I will complete the following tests:
cri/v1alpha1/cri_utils.go

imageToCriImage
getUserFromImageUser
parseUserFromImageUser

@starnop
Copy link
Contributor

starnop commented Jul 25, 2018

Today, I will complete the following tests:
cri/v1alpha1/cri_utils.go

parseWeightDeviceFromCRI
parseWeightDeviceFromPouch
parseThrottleDeviceFromCRI
parseThrottleDeviceFromPouch
parseUlimitFromCRI
parseUlimitFromPouch

@YaoZengzeng
Copy link
Contributor Author

Today, I will complete the tests in cri/stream/errors.go.

@starnop
Copy link
Contributor

starnop commented Aug 1, 2018

Today, I will complete the following tests:
cri/v1alpha1/cri_utils.go

toCriContainer

@starnop
Copy link
Contributor

starnop commented Aug 3, 2018

Today, I will complete the following tests:
cri/v1alpha1/cri_utils.go

toCNIPortMappings

@starnop
Copy link
Contributor

starnop commented Aug 6, 2018

Today, I will complete the following tests:
cri/v1alpha1/cri_utils.go

modifyHostConfig

@starnop
Copy link
Contributor

starnop commented Aug 7, 2018

Today, I will complete the following tests:
cri/v1alpha1/cri_utils.go

modifyContainerConfig
containerNetns

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

No branches or pull requests

5 participants