Skip to content

Commit

Permalink
fix: protect ~/.git-credentials from tests
Browse files Browse the repository at this point in the history
  • Loading branch information
msvticket committed Jan 6, 2024
1 parent 04bc4c9 commit 8888ee6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 24 deletions.
24 changes: 0 additions & 24 deletions .lighthouse/jenkins-x/pullrequest.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,34 +20,10 @@ spec:
name: ""
resources: {}
- name: jx-variables
- name: test-credentials0
resources: {}
image: ghcr.io/distroless/busybox
securityContext:
runAsUser: 0
script: |
#!/bin/sh
cat /tekton/home/.git-credentials
- name: build-make-linux
resources: {}
- name: test-credentials1
resources: {}
image: ghcr.io/distroless/busybox
securityContext:
runAsUser: 0
script: |
#!/bin/sh
cat /tekton/home/.git-credentials
- name: build-make-test
resources: {}
- name: test-credentials2
securityContext:
runAsUser: 0
resources: {}
image: ghcr.io/distroless/busybox
script: |
#!/bin/sh
cat /tekton/home/.git-credentials
- name: build-container-build:webhooks
resources: {}
script: |
Expand Down
2 changes: 2 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,9 @@ build-jenkins-controller-linux: ## Build the Jenkins controller binary for Linux

.PHONY: test
test: ## Runs the unit tests
chmod u-w ~/.git-credentials
CGO_ENABLED=$(CGO_ENABLED) $(GOTEST) -short ./pkg/... ./cmd/...
chmod u+w ~/.git-credentials

.PHONY: compile-e2e
compile-e2e:
Expand Down

0 comments on commit 8888ee6

Please sign in to comment.