Skip to content

Commit

Permalink
updated per code review
Browse files Browse the repository at this point in the history
Signed-off-by: Patrick Zheng <[email protected]>
  • Loading branch information
Two-Hearts committed Aug 18, 2023
1 parent 0248c4b commit 1ca206d
Show file tree
Hide file tree
Showing 7 changed files with 17 additions and 17 deletions.
2 changes: 1 addition & 1 deletion .github/licenserc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ header:
- 'tsconfig.json'
- '**/data/**'
- 'dist'
- '**/tests/**'
- 'tests'

comment: on-failure

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/e2e-test-sign.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
id: prepare
uses: docker/build-push-action@v4
with:
context: .github/tests/e2e
context: ./tests/e2e
push: true
tags: localhost:5000/e2e:latest
- name: Retrieve digest
Expand Down
30 changes: 15 additions & 15 deletions .github/workflows/e2e-test-verify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
id: prepare
uses: docker/build-push-action@v4
with:
context: .github/tests/e2e
context: ./tests/e2e
push: true
tags: localhost:5000/e2e:latest
- name: Retrieve digest
Expand All @@ -52,8 +52,8 @@ jobs:
run: |
notation cert generate-test "e2e-test"
notation cert delete --type ca --store e2e-test -y --all
mkdir -p ${GITHUB_WORKSPACE}/.github/tests/e2e/truststore/x509/ca/e2e-test
cp ${{ env.E2E_CERT }} ${GITHUB_WORKSPACE}/.github/tests/e2e/truststore/x509/ca/e2e-test/e2e-test.crt
mkdir -p ${GITHUB_WORKSPACE}/tests/e2e/truststore/x509/ca/e2e-test
cp ${{ env.E2E_CERT }} ${GITHUB_WORKSPACE}/tests/e2e/truststore/x509/ca/e2e-test/e2e-test.crt
# Sign artifact
- name: Sign artifact using notation plugin
Expand All @@ -73,16 +73,16 @@ jobs:
uses: ./verify
with:
target_artifact_reference: ${{ env.target_artifact_reference }}
trust_policy: .github/tests/e2e/trustpolicy/trustpolicy.json
trust_store: .github/tests/e2e/truststore
trust_policy: ./tests/e2e/trustpolicy/trustpolicy.json
trust_store: ./tests/e2e/truststore

- name: Verify released artifact missing target artifact reference
continue-on-error: true
id: missing-artifact-reference
uses: ./verify
with:
trust_policy: .github/tests/e2e/trustpolicy/trustpolicy.json
trust_store: .github/tests/e2e/truststore
trust_policy: ./tests/e2e/trustpolicy/trustpolicy.json
trust_store: ./tests/e2e/truststore
- name: 'Should Fail: Verify released artifact missing target artifact reference'
if: steps.missing-artifact-reference.outcome != 'failure'
run: |
Expand All @@ -95,7 +95,7 @@ jobs:
uses: ./verify
with:
target_artifact_reference: ${{ env.target_artifact_reference }}
trust_store: .github/tests/e2e/truststore
trust_store: ./tests/e2e/truststore
- name: 'Should Fail: Verify released artifact missing trust policy'
if: steps.missing-trust-policy.outcome != 'failure'
run: |
Expand All @@ -108,8 +108,8 @@ jobs:
uses: ./verify
with:
target_artifact_reference: ${{ env.target_artifact_reference }}
trust_policy: .github/tests/e2e/trustpolicy/invalid-trustpolicy.json
trust_store: .github/tests/e2e/truststore
trust_policy: ./tests/e2e/trustpolicy/invalid-trustpolicy.json
trust_store: ./tests/e2e/truststore
- name: 'Should Fail: Verify released artifact with invalid trust policy'
if: steps.invalid-trust-policy.outcome != 'failure'
run: |
Expand All @@ -122,7 +122,7 @@ jobs:
uses: ./verify
with:
target_artifact_reference: ${{ env.target_artifact_reference }}
trust_policy: .github/tests/e2e/trustpolicy/trustpolicy.json
trust_policy: ./tests/e2e/trustpolicy/trustpolicy.json
- name: 'Should Fail: Verify released artifact missing trust store'
if: steps.missing-trust-store.outcome != 'failure'
run: |
Expand All @@ -135,8 +135,8 @@ jobs:
uses: ./verify
with:
target_artifact_reference: ${{ env.target_artifact_reference }}
trust_policy: .github/tests/e2e/trustpolicy/trustpolicy.json
trust_store: .github/tests/e2e/invalid-trust-store/x509
trust_policy: ./tests/e2e/trustpolicy/trustpolicy.json
trust_store: ./tests/e2e/invalid-trust-store/x509
- name: 'Should Fail: Verify released artifact with invalid trust store structure'
if: steps.invalid-trust-store.outcome != 'failure'
run: |
Expand All @@ -151,8 +151,8 @@ jobs:
uses: ./verify
with:
target_artifact_reference: ${{ env.target_artifact_reference }}
trust_policy: .github/tests/e2e/trustpolicy/trustpolicy.json
trust_store: .github/tests/e2e/truststore/invalid-trust-store
trust_policy: ./tests/e2e/trustpolicy/trustpolicy.json
trust_store: ./tests/e2e/truststore/invalid-trust-store
- name: 'Should Fail: Verify released artifact without valid cert in trust store'
if: steps.invalid-cert.outcome != 'failure'
run: |
Expand Down
File renamed without changes.
File renamed without changes.

0 comments on commit 1ca206d

Please sign in to comment.