Skip to content

Commit

Permalink
chore: move test workflows to test.yml
Browse files Browse the repository at this point in the history
Signed-off-by: Keith Zantow <kzantow@gmail.com>
  • Loading branch information
kzantow committed May 20, 2024
1 parent 9b3285b commit 00ce720
Show file tree
Hide file tree
Showing 3 changed files with 66 additions and 91 deletions.
42 changes: 0 additions & 42 deletions .github/workflows/demo.yml

This file was deleted.

49 changes: 0 additions & 49 deletions .github/workflows/sarifdemo.yml

This file was deleted.

66 changes: 66 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,3 +69,69 @@ jobs:

- name: "Check Grype version after scan-action"
run: grype version | egrep "^Version:.*0.54.0$"

test-image:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5
- uses: ./
with:
image: "alpine:latest"
fail-build: false

test-directory:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5
- uses: ./
with:
path: "tests/fixtures/npm-project"
severity-cutoff: "negligible"
fail-build: false

test-sbom:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5
- uses: ./
with:
sbom: tests/fixtures/test_sbom.spdx.json
fail-build: false

test-windows:
runs-on: windows-latest
steps:
- uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5
- uses: ./
with:
output-format: table
image: "alpine:latest"
fail-build: false

test-sarif-image:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5
- name: Run the local Scan Action with SARIF generation enabled
id: scan
uses: ./
with:
image: "debian:8"
fail-build: false

- name: Inspect Generated SARIF
run: cat ${{ steps.scan.outputs.sarif }}

test-sarif-directory:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5
- name: Run the local Scan Action with SARIF generation enabled
id: scan
uses: ./
with:
path: "tests/fixtures/npm-project"
fail-build: false

- name: Inspect Generated SARIF
run: cat ${{ steps.scan.outputs.sarif }}

0 comments on commit 00ce720

Please sign in to comment.