Skip to content

Commit

Permalink
Use k8s pause image for integration test
Browse files Browse the repository at this point in the history
  • Loading branch information
halvards committed Jul 6, 2021
1 parent 4a6c870 commit 34b4e04
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
5 changes: 3 additions & 2 deletions build/cloudbuild.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ steps:
- -eu
- -c
- |-
kpt cfg set manifests image $(cat .image) --set-by cloudbuild
kpt fn eval manifests --image "gcr.io/kpt-fn/apply-setters:v${_KPT_APPLY_SETTERS_VERSION}" -- "image=$(cat .image)"
- id: commit
name: gcr.io/cloud-builders/git
Expand All @@ -140,7 +140,8 @@ steps:
substitutions:
_IMAGE_REPO: gcr.io/$PROJECT_ID
_KO_VERSION: '0.8.3'
_KPT_VERSION: '0.39.3'
_KPT_APPLY_SETTERS_VERSION: '0.1.1'
_KPT_VERSION: '1.0.0-beta.1'
_KUBEBUILDER_VERSION: '2.3.2'
_SECRET_NAME: projects/$PROJECT_ID/secrets/$REPO_NAME-deploy-key/versions/latest

Expand Down
4 changes: 2 additions & 2 deletions cmd/webhook/webhook_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ func Test_ResolvePublicGCRImage(t *testing.T) {
Containers: []corev1.Container{
{
Name: "test-container",
Image: "gcr.io/google-samples/hello-app:1.0",
Image: "gcr.io/google-containers/pause-amd64:3.2",
},
},
},
Expand All @@ -107,7 +107,7 @@ func Test_ResolvePublicGCRImage(t *testing.T) {
t.Fatalf("could not get test pod: %+v", err)
}

wantImage := "gcr.io/google-samples/hello-app:1.0@sha256:c62ead5b8c15c231f9e786250b07909daf6c266d0fcddd93fea882eb722c3be4"
wantImage := "gcr.io/google-containers/pause-amd64:3.2@sha256:4a1c4b21597c1b4415bdbecb28a3296c6b5e23ca4f9feeb599860a1dac6a0108"
gotImage := podOut.Spec.Containers[0].Image
if wantImage != gotImage {
t.Errorf("wanted %s, got %s", wantImage, gotImage)
Expand Down

0 comments on commit 34b4e04

Please sign in to comment.