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

test: add unit test to getSELinuxSecurityOpts #1939

Closed
wants to merge 1 commit into from

Conversation

MarkLux
Copy link
Contributor

@MarkLux MarkLux commented Jul 31, 2018

Ⅰ. Describe what this PR did

add the unit test for criutils getSELinuxSecurityOpts() function, with input cases check.

Ⅱ. Does this pull request fix one issue?

fixes #1912

Ⅲ. Describe how you did it

add normal and nil input test cases to verify the function output

Ⅳ. Describe how to verify it

run go test -v run getSELinuxSecurityOpts in package v1alpha1

Ⅴ. Special notes for reviews

maybe it's better to further check the format of SELinux Options

@CLAassistant
Copy link

CLAassistant commented Jul 31, 2018

CLA assistant check
All committers have signed the CLA.

@pouchrobot
Copy link
Collaborator

@MarkLux Thanks for your contribution. 🍻
Please sign off in each of your commits.

@pouchrobot
Copy link
Collaborator

We found this is your first time to contribute to Pouch, @MarkLux
👏 We really appreciate it.
Just remind that you have read the contribution guide: https://github.com/alibaba/pouch/blob/master/CONTRIBUTING.md
If you didn't, you should do that first. If done, welcome again and please enjoy hacking! 🍻

@codecov-io
Copy link

codecov-io commented Jul 31, 2018

Codecov Report

Merging #1939 into master will increase coverage by 0.05%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1939      +/-   ##
==========================================
+ Coverage    63.3%   63.35%   +0.05%     
==========================================
  Files         200      200              
  Lines       15521    15521              
==========================================
+ Hits         9825     9833       +8     
+ Misses       4456     4447       -9     
- Partials     1240     1241       +1
Flag Coverage Δ
#criv1alpha1test 33.76% <ø> (+0.01%) ⬆️
#criv1alpha2test 34.23% <ø> (-0.09%) ⬇️
#integrationtest 38.4% <ø> (ø) ⬆️
#unittest 20.99% <ø> (+0.13%) ⬆️
Impacted Files Coverage Δ
cri/stream/portforward/httpstream.go 69.16% <0%> (-6.67%) ⬇️
cri/stream/runtime.go 71.01% <0%> (-2.9%) ⬇️
daemon/logger/jsonfile/utils.go 73.17% <0%> (+1.62%) ⬆️
cri/v1alpha1/cri_utils.go 77.14% <0%> (+2.85%) ⬆️

@allencloud allencloud changed the title add unit test to getSELinuxSecurityOpts test: add unit test to getSELinuxSecurityOpts Aug 1, 2018
@allencloud allencloud closed this Aug 1, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[help wanted] add unit-test for getSELinuxSecurityOpts
5 participants