add Go lint

Signed-off-by: yxxhero <aiopsclub@163.com>
This commit is contained in:
yxxhero
2022-07-16 20:21:11 +08:00
parent cc13492623
commit ac23def893
60 changed files with 576 additions and 194 deletions
+1 -1
View File
@@ -51,7 +51,7 @@ func GetArgs(args string, state *state.HelmState) []string {
value := argVal[1]
argsMap.SetArg(arg, value, false)
} else {
//check if next value is arg to flag
// check if next value is arg to flag
if index+1 < len(argsVals) {
nextVal := argsVals[index+1]
if strings.HasPrefix(nextVal, "--") {
-2
View File
@@ -10,7 +10,6 @@ import (
// TestGetArgs tests the GetArgs function
func TestGetArgs(t *testing.T) {
tests := []struct {
args string
expected string
@@ -86,6 +85,5 @@ func TestSetArg(t *testing.T) {
require.NotContainsf(t, ap.flags, test.flag, "expected flag %s to be not set", test.flag)
require.NotContainsf(t, ap.m, test.flag, "expected m %s to be not set", test.flag)
}
}
}