Skip to content

Commit 53da769

Browse files
committed
Fix test
1 parent 0002a20 commit 53da769

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

go.mod

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ module github.com/kitagry/kj
33
go 1.16
44

55
require (
6-
github.com/goccy/go-yaml v1.8.9
6+
github.com/goccy/go-yaml v1.8.10
77
github.com/mattn/go-tty v0.0.3
88
k8s.io/api v0.21.1
99
k8s.io/apimachinery v0.21.1

go.sum

+2-2
Original file line numberDiff line numberDiff line change
@@ -82,8 +82,8 @@ github.com/go-playground/universal-translator v0.17.0 h1:icxd5fm+REJzpZx7ZfpaD87
8282
github.com/go-playground/universal-translator v0.17.0/go.mod h1:UkSxE5sNxxRwHyU+Scu5vgOQjsIJAF8j9muTVoKLVtA=
8383
github.com/go-playground/validator/v10 v10.4.1 h1:pH2c5ADXtd66mxoE0Zm9SUhxE20r7aM3F26W0hOn+GE=
8484
github.com/go-playground/validator/v10 v10.4.1/go.mod h1:nlOn6nFhuKACm19sB/8EGNn9GlaMV7XkbRSipzJ0Ii4=
85-
github.com/goccy/go-yaml v1.8.9 h1:4AEXg2qx+/w29jXnXpMY6mTckmYu1TMoHteKuMf0HFg=
86-
github.com/goccy/go-yaml v1.8.9/go.mod h1:U/jl18uSupI5rdI2jmuCswEA2htH9eXfferR3KfscvA=
85+
github.com/goccy/go-yaml v1.8.10 h1:XpBOLD8cmOZlLYjUFPqSZZ+Ubi4/UKxO2eXyhg5WuAA=
86+
github.com/goccy/go-yaml v1.8.10/go.mod h1:U/jl18uSupI5rdI2jmuCswEA2htH9eXfferR3KfscvA=
8787
github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q=
8888
github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q=
8989
github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q=

kubeconfig_test.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -49,11 +49,11 @@ func TestKubeconfig_CurrentNamespace(t *testing.T) {
4949
},
5050
"Context has no namespace": {
5151
currentContext: "a",
52-
expect: "",
52+
expect: "default",
5353
},
5454
"Context doesn't exist": {
5555
currentContext: "not exist context",
56-
expect: "",
56+
expect: "default",
5757
},
5858
}
5959

main.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ import (
1010
"path/filepath"
1111
"strings"
1212

13-
"github.com/goccy/go-yaml"
1413
"github.com/mattn/go-tty"
1514
batchv1 "k8s.io/api/batch/v1"
1615
batchv1beta1 "k8s.io/api/batch/v1beta1"
@@ -19,6 +18,7 @@ import (
1918
_ "k8s.io/client-go/plugin/pkg/client/auth"
2019
"k8s.io/client-go/tools/clientcmd"
2120
"k8s.io/client-go/util/homedir"
21+
"sigs.k8s.io/yaml"
2222
)
2323

2424
const cmdName = "kj"

0 commit comments

Comments
 (0)