mirror of
https://github.com/kubernetes-sigs/kustomize.git
synced 2026-06-13 01:50:55 +00:00
Merge pull request #2560 from yutachaos/feature/added_numberonlytag_test_editset_image
Add test case when image tag is a number
This commit is contained in:
@@ -38,6 +38,30 @@ func TestSetImage(t *testing.T) {
|
||||
" newTag: my-tag",
|
||||
}},
|
||||
},
|
||||
{
|
||||
given: given{
|
||||
args: []string{"image1=my-image1:1234"},
|
||||
},
|
||||
expected: expected{
|
||||
fileOutput: []string{
|
||||
"images:",
|
||||
"- name: image1",
|
||||
" newName: my-image1",
|
||||
" newTag: \"1234\"",
|
||||
}},
|
||||
},
|
||||
{
|
||||
given: given{
|
||||
args: []string{"image1=my-image1:3.2e2"},
|
||||
},
|
||||
expected: expected{
|
||||
fileOutput: []string{
|
||||
"images:",
|
||||
"- name: image1",
|
||||
" newName: my-image1",
|
||||
" newTag: \"3.2e2\"",
|
||||
}},
|
||||
},
|
||||
{
|
||||
given: given{
|
||||
args: []string{"image1=my-image1@sha256:24a0c4b4a4c0eb97a1aabb8e29f18e917d05abfe1b7a7c07857230879ce7d3d3"},
|
||||
|
||||
Reference in New Issue
Block a user