Skip to content

Commit

Permalink
Upgrade go-yaml to commit 496545a6307b
Browse files Browse the repository at this point in the history
  • Loading branch information
Shell32-Natsu committed Jun 8, 2021
1 parent 440026b commit 6936ae8
Show file tree
Hide file tree
Showing 113 changed files with 3,997 additions and 3,943 deletions.
20 changes: 10 additions & 10 deletions api/filters/fieldspec/fieldspec_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -260,16 +260,16 @@ apiVersion: foo/v1beta1
kind: Bar
a:
b:
- c:
d: a
- c:
d: a
`,
expected: `
apiVersion: foo/v1beta1
kind: Bar
a:
b:
- c:
d: e
- c:
d: e
`,
filter: fieldspec.Filter{
SetValue: filtersutil.SetScalar("e"),
Expand Down Expand Up @@ -313,14 +313,14 @@ apiVersion: foo/v1beta1
kind: Bar
a:
b:
- c: {}
- c: {}
`,
expected: `
apiVersion: foo/v1beta1
kind: Bar
a:
b:
- c: {d: e}
- c: {d: e}
`,
filter: fieldspec.Filter{
SetValue: filtersutil.SetScalar("e"),
Expand Down Expand Up @@ -383,14 +383,14 @@ apiVersion: v1
kind: Bar
spec:
containers:
- image: foo
- image: foo
`,
expected: `
apiVersion: v1
kind: Bar
spec:
containers:
- image: bar
- image: bar
`,
filter: fieldspec.Filter{
SetValue: filtersutil.SetScalar("bar"),
Expand All @@ -409,14 +409,14 @@ apiVersion: v1
kind: Bar
spec:
containers:
- image: foo
- image: foo
`,
expected: `
apiVersion: v1
kind: Bar
spec:
containers:
- image: bar
- image: bar
`,
filter: fieldspec.Filter{
SetValue: filtersutil.SetScalar("bar"),
Expand Down
4 changes: 2 additions & 2 deletions api/filters/fsslice/fsslice_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,14 +58,14 @@ apiVersion: foo/v1
kind: Bar
q:
r:
- s: {}
- s: {}
`,
expected: `
apiVersion: foo/v1
kind: Bar
q:
r:
- s: {t: e}
- s: {t: e}
a:
b: e
`,
Expand Down
32 changes: 16 additions & 16 deletions api/filters/imagetag/example_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,17 +21,17 @@ metadata:
name: instance
spec:
containers:
- name: FooBar
image: nginx
- name: FooBar
image: nginx
---
apiVersion: example.com/v1
kind: Bar
metadata:
name: instance
spec:
containers:
- name: BarFoo
image: nginx:1.2.1
- name: BarFoo
image: nginx:1.2.1
`)}},
Filters: []kio.Filter{Filter{
ImageTag: types.Image{
Expand All @@ -58,17 +58,17 @@ spec:
// name: instance
// spec:
// containers:
// - name: FooBar
// image: apache@12345
// - name: FooBar
// image: apache@12345
// ---
// apiVersion: example.com/v1
// kind: Bar
// metadata:
// name: instance
// spec:
// containers:
// - name: BarFoo
// image: apache@12345
// - name: BarFoo
// image: apache@12345
}

func ExampleLegacyFilter() {
Expand All @@ -80,17 +80,17 @@ metadata:
name: instance
spec:
containers:
- name: FooBar
image: nginx
- name: FooBar
image: nginx
---
apiVersion: example.com/v1
kind: Bar
metadata:
name: instance
spec:
containers:
- name: BarFoo
image: nginx:1.2.1
- name: BarFoo
image: nginx:1.2.1
`)}},
Filters: []kio.Filter{LegacyFilter{
ImageTag: types.Image{
Expand All @@ -112,15 +112,15 @@ spec:
// name: instance
// spec:
// containers:
// - name: FooBar
// image: apache@12345
// - name: FooBar
// image: apache@12345
// ---
// apiVersion: example.com/v1
// kind: Bar
// metadata:
// name: instance
// spec:
// containers:
// - name: BarFoo
// image: apache@12345
// - name: BarFoo
// image: apache@12345
}
Loading

0 comments on commit 6936ae8

Please sign in to comment.