-
Notifications
You must be signed in to change notification settings - Fork 138
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
feat: always store namespace in func.yaml and warn if current ns & func.yaml ns is different #1118
Conversation
@gauron99 the unitests are failing |
you need to add |
Codecov Report
@@ Coverage Diff @@
## main #1118 +/- ##
==========================================
+ Coverage 45.89% 45.92% +0.03%
==========================================
Files 65 65
Lines 8701 8717 +16
==========================================
+ Hits 3993 4003 +10
- Misses 4321 4325 +4
- Partials 387 389 +2
|
})) | ||
|
||
// set namespace argument if given & reset after | ||
cmd.SetArgs([]string{}) // Do not use test command args |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why we cannot use command args?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When i used cmd.SetArgs
i got an error Got error 'unknown flag: --namespace'
as it is a global flag, using viper worked to fix it
…ck kubeconfig for testing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
/hold for others
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: gauron99, zroubalik 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:
Approvers can indicate their approval by writing |
/lgtm |
Changes
changes to
func deploy
(ex:
func.yaml->namespace = default
&&oc->namespace = myns
-> print warning where func is deployed)update
context.TODO
withcontext.Background
in deploy_test.goFixes #1084