Add condition to run tests only on maintainer's branches
This commit is contained in:
18
.github/workflows/test.yml
vendored
18
.github/workflows/test.yml
vendored
@@ -15,6 +15,12 @@ jobs:
|
|||||||
- run: npm ci
|
- run: npm ci
|
||||||
- run: npm test
|
- run: npm test
|
||||||
test-with-output-secrets:
|
test-with-output-secrets:
|
||||||
|
if: |
|
||||||
|
github.ref == 'refs/heads/main' ||
|
||||||
|
(
|
||||||
|
github.event_name == 'pull_request' &&
|
||||||
|
github.event.pull_request.head.repo.full_name == github.repository
|
||||||
|
)
|
||||||
uses: ./.github/workflows/acceptance-test.yml
|
uses: ./.github/workflows/acceptance-test.yml
|
||||||
secrets: inherit
|
secrets: inherit
|
||||||
with:
|
with:
|
||||||
@@ -23,6 +29,12 @@ jobs:
|
|||||||
multiline-secret: op://acceptance-tests/multiline-secret/notesPlain
|
multiline-secret: op://acceptance-tests/multiline-secret/notesPlain
|
||||||
export-env: false
|
export-env: false
|
||||||
test-with-export-env:
|
test-with-export-env:
|
||||||
|
if: |
|
||||||
|
github.ref == 'refs/heads/main' ||
|
||||||
|
(
|
||||||
|
github.event_name == 'pull_request' &&
|
||||||
|
github.event.pull_request.head.repo.full_name == github.repository
|
||||||
|
)
|
||||||
uses: ./.github/workflows/acceptance-test.yml
|
uses: ./.github/workflows/acceptance-test.yml
|
||||||
secrets: inherit
|
secrets: inherit
|
||||||
with:
|
with:
|
||||||
@@ -31,6 +43,12 @@ jobs:
|
|||||||
multiline-secret: op://acceptance-tests/multiline-secret/notesPlain
|
multiline-secret: op://acceptance-tests/multiline-secret/notesPlain
|
||||||
export-env: true
|
export-env: true
|
||||||
test-references-with-ids:
|
test-references-with-ids:
|
||||||
|
if: |
|
||||||
|
github.ref == 'refs/heads/main' ||
|
||||||
|
(
|
||||||
|
github.event_name == 'pull_request' &&
|
||||||
|
github.event.pull_request.head.repo.full_name == github.repository
|
||||||
|
)
|
||||||
uses: ./.github/workflows/acceptance-test.yml
|
uses: ./.github/workflows/acceptance-test.yml
|
||||||
secrets: inherit
|
secrets: inherit
|
||||||
with:
|
with:
|
||||||
|
|||||||
Reference in New Issue
Block a user