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

make NSTemplateTier generator generic & move to common #1006

Conversation

MatousJobanek
Copy link
Contributor

@MatousJobanek MatousJobanek commented Apr 3, 2024

depends on codeready-toolchain/toolchain-common#381

  • moves most of the nstemplatetier_generator.go into toolchain-common
  • loads the metadata & templates from the assets and passes them as a parameter of the generic GenerateTiers function
  • drops the test templates and related tests

KUBESAW-59

Copy link
Contributor

@mfrancisc mfrancisc left a comment

Choose a reason for hiding this comment

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

Great Job 👍

I like how the new nstemplatetiers.GenerateTiers function looks, only nit is that the client needs to depend on a couple of packages potentially:

  • the new nstemplatetiers
  • the commonclient

Do you see other implementations of the ensureObject function or maybe we could embed that in the nstemplatetiers.GenerateTiers function ?

Copy link
Contributor

@fbm3307 fbm3307 left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link

openshift-ci bot commented Apr 15, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: alexeykazakov, fbm3307, MatousJobanek, mfrancisc

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:
  • OWNERS [MatousJobanek,alexeykazakov]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Copy link

Quality Gate Passed Quality Gate passed

Issues
3 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
13.3% Duplication on New Code

See analysis details on SonarCloud

@MatousJobanek
Copy link
Contributor Author

/retest

Copy link

codecov bot commented Apr 17, 2024

Codecov Report

Merging #1006 (07deb94) into master (8ea73da) will decrease coverage by 0.26%.
The diff coverage is 92.30%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1006      +/-   ##
==========================================
- Coverage   84.87%   84.62%   -0.26%     
==========================================
  Files          55       55              
  Lines        5066     4852     -214     
==========================================
- Hits         4300     4106     -194     
+ Misses        583      573      -10     
+ Partials      183      173      -10     
Files Coverage Δ
controllers/usersignup/usersignup_controller.go 75.77% <ø> (ø)
...plates/nstemplatetiers/nstemplatetier_generator.go 91.30% <92.30%> (+0.58%) ⬆️

@MatousJobanek MatousJobanek merged commit c0d5f3c into codeready-toolchain:master Apr 18, 2024
11 of 13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants