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

refactor: cli test command #5550

Merged
merged 2 commits into from
Dec 3, 2022
Merged

Conversation

eddycharly
Copy link
Member

Signed-off-by: Charles-Edouard Brétéché charles.edouard@nirmata.com

Explanation

This PR refactors cli test command:

  • creates an api package
  • creates a template package
  • moves git utils in a separate package

Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>
@codecov
Copy link

codecov bot commented Dec 2, 2022

Codecov Report

Merging #5550 (caacefc) into main (a7b4089) will not change coverage.
The diff coverage is 100.00%.

@@           Coverage Diff           @@
##             main    #5550   +/-   ##
=======================================
  Coverage   36.59%   36.59%           
=======================================
  Files         173      173           
  Lines       19375    19375           
=======================================
  Hits         7091     7091           
  Misses      11477    11477           
  Partials      807      807           
Impacted Files Coverage Δ
cmd/cli/kubectl-kyverno/apply/apply_command.go 26.46% <100.00%> (ø)

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

Copy link
Contributor

@samj1912 samj1912 left a comment

Choose a reason for hiding this comment

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

Simple refactor. LGTM.

Comment on lines +1 to +7
package manifest

import "fmt"

func print(manifest string) {
fmt.Println(manifest)
}
Copy link
Contributor

Choose a reason for hiding this comment

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

Not sure if I understand the point of this small function. Why not call fmt.Println directly?

Copy link
Member Author

Choose a reason for hiding this comment

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

I’m thinking about using real template in the future, right now it’s just static content :(

@eddycharly eddycharly merged commit 6893842 into kyverno:main Dec 3, 2022
@eddycharly eddycharly deleted the refactor-cli-A branch December 3, 2022 18:56
MdSahil-oss pushed a commit to MdSahil-oss/kyverno that referenced this pull request Dec 29, 2022
Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>

Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>
Signed-off-by: Md Sahil <Mohdssahil1@gmail.com>
MdSahil-oss pushed a commit to MdSahil-oss/kyverno that referenced this pull request Jan 11, 2023
Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>

Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>
Signed-off-by: MdSahil-oss <Mohdssahil1@gmail.com>
MdSahil-oss pushed a commit to MdSahil-oss/kyverno that referenced this pull request Jan 11, 2023
Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>

Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>
Signed-off-by: MdSahil-oss <Mohdssahil1@gmail.com>
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.

None yet

2 participants