mirror of
https://github.com/anchore/syft.git
synced 2026-03-30 13:43:25 +02:00
Compare commits
41 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
d71b747cd1 | ||
|
|
58a8a95e26 | ||
|
|
78a21b9c88 | ||
|
|
7d3882a425 | ||
|
|
673c85754c | ||
|
|
c5114fd745 | ||
|
|
f68a7cc899 | ||
|
|
7800b16529 | ||
|
|
834ddcb1c0 | ||
|
|
f5d318d934 | ||
|
|
8531e1917b | ||
|
|
860126c650 | ||
|
|
36639f136b | ||
|
|
f32238c268 | ||
|
|
0c8eef65f0 | ||
|
|
4d42f8af32 | ||
|
|
e38851143e | ||
|
|
a3dacf5ecd | ||
|
|
cccc9bf7f9 | ||
|
|
59f7725d0d | ||
|
|
7a6b1575ae | ||
|
|
92a6b36e89 | ||
|
|
7158535fe6 | ||
|
|
75455f050a | ||
|
|
22e78c7be1 | ||
|
|
d2461a9e0a | ||
|
|
01f0e332c2 | ||
|
|
c88051d74e | ||
|
|
7d3d1c6237 | ||
|
|
dcba765d86 | ||
|
|
2c201469c3 | ||
|
|
c583da1c15 | ||
|
|
22014b6022 | ||
|
|
b5e85c3ea5 | ||
|
|
35278f3d3d | ||
|
|
db76d85d51 | ||
|
|
e9e7e20cc8 | ||
|
|
eb072deb9c | ||
|
|
f4fc2d669a | ||
|
|
f5110f109a | ||
|
|
612eadb22e |
16
.binny.yaml
16
.binny.yaml
@ -2,7 +2,7 @@ tools:
|
|||||||
# we want to use a pinned version of binny to manage the toolchain (so binny manages itself!)
|
# we want to use a pinned version of binny to manage the toolchain (so binny manages itself!)
|
||||||
- name: binny
|
- name: binny
|
||||||
version:
|
version:
|
||||||
want: v0.11.3
|
want: v0.12.0
|
||||||
method: github-release
|
method: github-release
|
||||||
with:
|
with:
|
||||||
repo: anchore/binny
|
repo: anchore/binny
|
||||||
@ -18,7 +18,7 @@ tools:
|
|||||||
# used to sign mac binaries at release
|
# used to sign mac binaries at release
|
||||||
- name: quill
|
- name: quill
|
||||||
version:
|
version:
|
||||||
want: v0.5.1
|
want: v0.7.1
|
||||||
method: github-release
|
method: github-release
|
||||||
with:
|
with:
|
||||||
repo: anchore/quill
|
repo: anchore/quill
|
||||||
@ -26,7 +26,7 @@ tools:
|
|||||||
# used for linting
|
# used for linting
|
||||||
- name: golangci-lint
|
- name: golangci-lint
|
||||||
version:
|
version:
|
||||||
want: v2.9.0
|
want: v2.11.4
|
||||||
method: github-release
|
method: github-release
|
||||||
with:
|
with:
|
||||||
repo: golangci/golangci-lint
|
repo: golangci/golangci-lint
|
||||||
@ -42,7 +42,7 @@ tools:
|
|||||||
# used for signing the checksums file at release
|
# used for signing the checksums file at release
|
||||||
- name: cosign
|
- name: cosign
|
||||||
version:
|
version:
|
||||||
want: v3.0.4
|
want: v3.0.5
|
||||||
method: github-release
|
method: github-release
|
||||||
with:
|
with:
|
||||||
repo: sigstore/cosign
|
repo: sigstore/cosign
|
||||||
@ -58,7 +58,7 @@ tools:
|
|||||||
# used to release all artifacts
|
# used to release all artifacts
|
||||||
- name: goreleaser
|
- name: goreleaser
|
||||||
version:
|
version:
|
||||||
want: v2.13.3
|
want: v2.14.3
|
||||||
method: github-release
|
method: github-release
|
||||||
with:
|
with:
|
||||||
repo: goreleaser/goreleaser
|
repo: goreleaser/goreleaser
|
||||||
@ -90,7 +90,7 @@ tools:
|
|||||||
# used for running all local and CI tasks
|
# used for running all local and CI tasks
|
||||||
- name: task
|
- name: task
|
||||||
version:
|
version:
|
||||||
want: v3.48.0
|
want: v3.49.1
|
||||||
method: github-release
|
method: github-release
|
||||||
with:
|
with:
|
||||||
repo: go-task/task
|
repo: go-task/task
|
||||||
@ -98,7 +98,7 @@ tools:
|
|||||||
# used for triggering a release
|
# used for triggering a release
|
||||||
- name: gh
|
- name: gh
|
||||||
version:
|
version:
|
||||||
want: v2.86.0
|
want: v2.88.1
|
||||||
method: github-release
|
method: github-release
|
||||||
with:
|
with:
|
||||||
repo: cli/cli
|
repo: cli/cli
|
||||||
@ -106,7 +106,7 @@ tools:
|
|||||||
# used to upload test fixture cache
|
# used to upload test fixture cache
|
||||||
- name: oras
|
- name: oras
|
||||||
version:
|
version:
|
||||||
want: v1.3.0
|
want: v1.3.1
|
||||||
method: github-release
|
method: github-release
|
||||||
with:
|
with:
|
||||||
repo: oras-project/oras
|
repo: oras-project/oras
|
||||||
|
|||||||
4
.github/actions/bootstrap/action.yaml
vendored
4
.github/actions/bootstrap/action.yaml
vendored
@ -5,7 +5,7 @@ inputs:
|
|||||||
go-version:
|
go-version:
|
||||||
description: "Go version to install"
|
description: "Go version to install"
|
||||||
required: true
|
required: true
|
||||||
default: "1.25.x"
|
default: "1.26.x"
|
||||||
go-dependencies:
|
go-dependencies:
|
||||||
description: "Download go dependencies"
|
description: "Download go dependencies"
|
||||||
required: true
|
required: true
|
||||||
@ -29,7 +29,7 @@ runs:
|
|||||||
using: "composite"
|
using: "composite"
|
||||||
steps:
|
steps:
|
||||||
# note: go mod and build is automatically cached on default with v4+
|
# note: go mod and build is automatically cached on default with v4+
|
||||||
- uses: actions/setup-go@7a3fe6cf4cb3a834922a1244abfce67bcef6a0c5 # v6.2.0
|
- uses: actions/setup-go@4b73464bb391d4059bd26b0524d20df3927bd417 # v6.3.0
|
||||||
if: inputs.go-version != ''
|
if: inputs.go-version != ''
|
||||||
with:
|
with:
|
||||||
go-version: ${{ inputs.go-version }}
|
go-version: ${{ inputs.go-version }}
|
||||||
|
|||||||
5
.github/dependabot.yml
vendored
5
.github/dependabot.yml
vendored
@ -23,6 +23,11 @@ updates:
|
|||||||
open-pull-requests-limit: 10
|
open-pull-requests-limit: 10
|
||||||
labels:
|
labels:
|
||||||
- "dependencies"
|
- "dependencies"
|
||||||
|
ignore:
|
||||||
|
- dependency-name: "github.com/aquasecurity/go-pep440-version"
|
||||||
|
- dependency-name: "github.com/aquasecurity/go-version"
|
||||||
|
- dependency-name: "github.com/knqyf263/go-apk-version"
|
||||||
|
- dependency-name: "github.com/knqyf263/go-deb-version"
|
||||||
groups:
|
groups:
|
||||||
go-minor-patch:
|
go-minor-patch:
|
||||||
applies-to: version-updates # security updates get individual PRs
|
applies-to: version-updates # security updates get individual PRs
|
||||||
|
|||||||
2
.github/scripts/capability-drift-check.sh
vendored
2
.github/scripts/capability-drift-check.sh
vendored
@ -6,7 +6,7 @@ if [ "$(git status --porcelain | wc -l)" -ne "0" ]; then
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if ! make generate-capabilities; then
|
if ! make generate-capabilities REFRESH=false; then
|
||||||
echo "Generating capability descriptions failed"
|
echo "Generating capability descriptions failed"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|||||||
@ -33,9 +33,9 @@ def is_git_tracked_or_untracked(directory):
|
|||||||
|
|
||||||
|
|
||||||
def find_test_fixture_dirs_with_images(base_dir):
|
def find_test_fixture_dirs_with_images(base_dir):
|
||||||
"""Find directories that contain 'test-fixtures' and at least one 'image-*' directory."""
|
"""Find directories that contain 'testdata' and at least one 'image-*' directory."""
|
||||||
for root, dirs, files in os.walk(base_dir):
|
for root, dirs, files in os.walk(base_dir):
|
||||||
if 'test-fixtures' in root:
|
if 'testdata' in root:
|
||||||
image_dirs = [d for d in dirs if d.startswith('image-')]
|
image_dirs = [d for d in dirs if d.startswith('image-')]
|
||||||
if image_dirs:
|
if image_dirs:
|
||||||
yield os.path.realpath(root)
|
yield os.path.realpath(root)
|
||||||
|
|||||||
8
.github/workflows/codeql-analysis.yml
vendored
8
.github/workflows/codeql-analysis.yml
vendored
@ -41,14 +41,14 @@ jobs:
|
|||||||
persist-credentials: false
|
persist-credentials: false
|
||||||
|
|
||||||
- name: Install Go
|
- name: Install Go
|
||||||
uses: actions/setup-go@7a3fe6cf4cb3a834922a1244abfce67bcef6a0c5 #v6.2.0
|
uses: actions/setup-go@4b73464bb391d4059bd26b0524d20df3927bd417 #v6.3.0
|
||||||
with:
|
with:
|
||||||
go-version-file: go.mod
|
go-version-file: go.mod
|
||||||
check-latest: true
|
check-latest: true
|
||||||
|
|
||||||
# Initializes the CodeQL tools for scanning.
|
# Initializes the CodeQL tools for scanning.
|
||||||
- name: Initialize CodeQL
|
- name: Initialize CodeQL
|
||||||
uses: github/codeql-action/init@cdefb33c0f6224e58673d9004f47f7cb3e328b89 # v4.31.10
|
uses: github/codeql-action/init@0d579ffd059c29b07949a3cce3983f0780820c98 # v4.32.6
|
||||||
with:
|
with:
|
||||||
languages: ${{ matrix.language }}
|
languages: ${{ matrix.language }}
|
||||||
# If you wish to specify custom queries, you can do so here or in a config file.
|
# If you wish to specify custom queries, you can do so here or in a config file.
|
||||||
@ -59,7 +59,7 @@ jobs:
|
|||||||
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
|
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
|
||||||
# If this step fails, then you should remove it and run the build manually (see below)
|
# If this step fails, then you should remove it and run the build manually (see below)
|
||||||
- name: Autobuild
|
- name: Autobuild
|
||||||
uses: github/codeql-action/autobuild@cdefb33c0f6224e58673d9004f47f7cb3e328b89 # v4.31.10
|
uses: github/codeql-action/autobuild@0d579ffd059c29b07949a3cce3983f0780820c98 # v4.32.6
|
||||||
|
|
||||||
# ℹ️ Command-line programs to run using the OS shell.
|
# ℹ️ Command-line programs to run using the OS shell.
|
||||||
# 📚 https://git.io/JvXDl
|
# 📚 https://git.io/JvXDl
|
||||||
@ -73,4 +73,4 @@ jobs:
|
|||||||
# make release
|
# make release
|
||||||
|
|
||||||
- name: Perform CodeQL Analysis
|
- name: Perform CodeQL Analysis
|
||||||
uses: github/codeql-action/analyze@cdefb33c0f6224e58673d9004f47f7cb3e328b89 # v4.31.10
|
uses: github/codeql-action/analyze@0d579ffd059c29b07949a3cce3983f0780820c98 # v4.32.6
|
||||||
|
|||||||
6
.github/workflows/detect-schema-changes.yaml
vendored
6
.github/workflows/detect-schema-changes.yaml
vendored
@ -37,6 +37,8 @@ jobs:
|
|||||||
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd #v6.0.2
|
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd #v6.0.2
|
||||||
with:
|
with:
|
||||||
persist-credentials: false
|
persist-credentials: false
|
||||||
|
repository: anchore/syft # IMPORTANT! An additional protection that this is checking out code from the expected repository
|
||||||
|
ref: main # IMPORTANT! It is CRITICAL that this only ever considers the code from main and NEVER EVER from a fork.
|
||||||
|
|
||||||
- run: python .github/scripts/labeler.py
|
- run: python .github/scripts/labeler.py
|
||||||
env:
|
env:
|
||||||
@ -46,7 +48,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Delete existing comment
|
- name: Delete existing comment
|
||||||
if: ${{ hashFiles( env.CI_COMMENT_FILE ) == '' }}
|
if: ${{ hashFiles( env.CI_COMMENT_FILE ) == '' }}
|
||||||
uses: marocchino/sticky-pull-request-comment@773744901bac0e8cbb5a0dc842800d45e9b2b405 #v2.9.4
|
uses: marocchino/sticky-pull-request-comment@70d2764d1a7d5d9560b100cbea0077fc8f633987 #v3.0.2
|
||||||
with:
|
with:
|
||||||
header: ${{ env.COMMENT_HEADER }}
|
header: ${{ env.COMMENT_HEADER }}
|
||||||
hide: true
|
hide: true
|
||||||
@ -54,7 +56,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Add comment
|
- name: Add comment
|
||||||
if: ${{ hashFiles( env.CI_COMMENT_FILE ) != '' }}
|
if: ${{ hashFiles( env.CI_COMMENT_FILE ) != '' }}
|
||||||
uses: marocchino/sticky-pull-request-comment@773744901bac0e8cbb5a0dc842800d45e9b2b405 #v2.9.4
|
uses: marocchino/sticky-pull-request-comment@70d2764d1a7d5d9560b100cbea0077fc8f633987 #v3.0.2
|
||||||
with:
|
with:
|
||||||
header: ${{ env.COMMENT_HEADER }}
|
header: ${{ env.COMMENT_HEADER }}
|
||||||
path: ${{ env.CI_COMMENT_FILE }}
|
path: ${{ env.CI_COMMENT_FILE }}
|
||||||
|
|||||||
8
.github/workflows/release.yaml
vendored
8
.github/workflows/release.yaml
vendored
@ -150,13 +150,13 @@ jobs:
|
|||||||
uses: ./.github/actions/bootstrap
|
uses: ./.github/actions/bootstrap
|
||||||
|
|
||||||
- name: Login to Docker Hub
|
- name: Login to Docker Hub
|
||||||
uses: docker/login-action@c94ce9fb468520275223c153574b00df6fe4bcc9 #v3.7.0
|
uses: docker/login-action@b45d80f862d83dbcd57f89517bcf500b2ab88fb2 #v4.0.0
|
||||||
with:
|
with:
|
||||||
username: ${{ secrets.ANCHOREOSSWRITE_DH_USERNAME }}
|
username: ${{ secrets.ANCHOREOSSWRITE_DH_USERNAME }}
|
||||||
password: ${{ secrets.ANCHOREOSSWRITE_DH_PAT }}
|
password: ${{ secrets.ANCHOREOSSWRITE_DH_PAT }}
|
||||||
|
|
||||||
- name: Login to GitHub Container Registry
|
- name: Login to GitHub Container Registry
|
||||||
uses: docker/login-action@c94ce9fb468520275223c153574b00df6fe4bcc9 #v3.7.0
|
uses: docker/login-action@b45d80f862d83dbcd57f89517bcf500b2ab88fb2 #v4.0.0
|
||||||
with:
|
with:
|
||||||
registry: ghcr.io
|
registry: ghcr.io
|
||||||
username: ${{ github.actor }}
|
username: ${{ github.actor }}
|
||||||
@ -186,14 +186,14 @@ jobs:
|
|||||||
# for updating brew formula in anchore/homebrew-syft
|
# for updating brew formula in anchore/homebrew-syft
|
||||||
GITHUB_BREW_TOKEN: ${{ secrets.ANCHOREOPS_GITHUB_OSS_WRITE_TOKEN }}
|
GITHUB_BREW_TOKEN: ${{ secrets.ANCHOREOPS_GITHUB_OSS_WRITE_TOKEN }}
|
||||||
|
|
||||||
- uses: anchore/sbom-action@28d71544de8eaf1b958d335707167c5f783590ad #v0.22.2
|
- uses: anchore/sbom-action@17ae1740179002c89186b61233e0f892c3118b11 #v0.23.0
|
||||||
continue-on-error: true
|
continue-on-error: true
|
||||||
with:
|
with:
|
||||||
file: go.mod
|
file: go.mod
|
||||||
artifact-name: sbom.spdx.json
|
artifact-name: sbom.spdx.json
|
||||||
|
|
||||||
- name: Notify Slack of new release
|
- name: Notify Slack of new release
|
||||||
uses: slackapi/slack-github-action@91efab103c0de0a537f72a35f6b8cda0ee76bf0a #v2.1.1
|
uses: slackapi/slack-github-action@af78098f536edbc4de71162a307590698245be95 #v3.0.1
|
||||||
continue-on-error: true
|
continue-on-error: true
|
||||||
with:
|
with:
|
||||||
webhook: ${{ secrets.SLACK_TOOLBOX_WEBHOOK_URL }}
|
webhook: ${{ secrets.SLACK_TOOLBOX_WEBHOOK_URL }}
|
||||||
|
|||||||
@ -31,7 +31,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
repos: ${{ github.event.inputs.repos }}
|
repos: ${{ github.event.inputs.repos }}
|
||||||
|
|
||||||
- uses: actions/create-github-app-token@29824e69f54612133e76f7eaac726eef6c875baf #v2.2.1
|
- uses: actions/create-github-app-token@f8d387b68d61c58ab83c6c016672934102569859 #v3.0.0
|
||||||
id: generate-token
|
id: generate-token
|
||||||
with:
|
with:
|
||||||
app-id: ${{ secrets.TOKEN_APP_ID }}
|
app-id: ${{ secrets.TOKEN_APP_ID }}
|
||||||
|
|||||||
2
.github/workflows/update-bootstrap-tools.yml
vendored
2
.github/workflows/update-bootstrap-tools.yml
vendored
@ -45,7 +45,7 @@ jobs:
|
|||||||
echo "\`\`\`"
|
echo "\`\`\`"
|
||||||
} >> $GITHUB_STEP_SUMMARY
|
} >> $GITHUB_STEP_SUMMARY
|
||||||
|
|
||||||
- uses: actions/create-github-app-token@29824e69f54612133e76f7eaac726eef6c875baf #v2.2.1
|
- uses: actions/create-github-app-token@f8d387b68d61c58ab83c6c016672934102569859 #v3.0.0
|
||||||
id: generate-token
|
id: generate-token
|
||||||
with:
|
with:
|
||||||
app-id: ${{ secrets.TOKEN_APP_ID }}
|
app-id: ${{ secrets.TOKEN_APP_ID }}
|
||||||
|
|||||||
@ -46,7 +46,7 @@ jobs:
|
|||||||
- name: Push updated CPE cache to registry
|
- name: Push updated CPE cache to registry
|
||||||
run: make generate:cpe-index:cache:push
|
run: make generate:cpe-index:cache:push
|
||||||
|
|
||||||
- uses: actions/create-github-app-token@29824e69f54612133e76f7eaac726eef6c875baf #v2.2.1
|
- uses: actions/create-github-app-token@f8d387b68d61c58ab83c6c016672934102569859 #v3.0.0
|
||||||
id: generate-token
|
id: generate-token
|
||||||
with:
|
with:
|
||||||
app-id: ${{ secrets.TOKEN_APP_ID }}
|
app-id: ${{ secrets.TOKEN_APP_ID }}
|
||||||
@ -65,7 +65,7 @@ jobs:
|
|||||||
token: ${{ steps.generate-token.outputs.token }}
|
token: ${{ steps.generate-token.outputs.token }}
|
||||||
|
|
||||||
- name: Notify Slack on failure
|
- name: Notify Slack on failure
|
||||||
uses: slackapi/slack-github-action@91efab103c0de0a537f72a35f6b8cda0ee76bf0a #v2.1.1
|
uses: slackapi/slack-github-action@af78098f536edbc4de71162a307590698245be95 #v3.0.1
|
||||||
with:
|
with:
|
||||||
webhook: ${{ secrets.SLACK_TOOLBOX_WEBHOOK_URL }}
|
webhook: ${{ secrets.SLACK_TOOLBOX_WEBHOOK_URL }}
|
||||||
webhook-type: incoming-webhook
|
webhook-type: incoming-webhook
|
||||||
|
|||||||
@ -45,7 +45,7 @@ jobs:
|
|||||||
token: ${{ steps.generate-token.outputs.token }}
|
token: ${{ steps.generate-token.outputs.token }}
|
||||||
|
|
||||||
- name: Notify Slack on failure
|
- name: Notify Slack on failure
|
||||||
uses: slackapi/slack-github-action@91efab103c0de0a537f72a35f6b8cda0ee76bf0a #v2.1.1
|
uses: slackapi/slack-github-action@af78098f536edbc4de71162a307590698245be95 #v3.0.1
|
||||||
with:
|
with:
|
||||||
webhook: ${{ secrets.SLACK_TOOLBOX_WEBHOOK_URL }}
|
webhook: ${{ secrets.SLACK_TOOLBOX_WEBHOOK_URL }}
|
||||||
webhook-type: incoming-webhook
|
webhook-type: incoming-webhook
|
||||||
|
|||||||
11
.github/workflows/validations.yaml
vendored
11
.github/workflows/validations.yaml
vendored
@ -58,6 +58,9 @@ jobs:
|
|||||||
- name: Run unit tests
|
- name: Run unit tests
|
||||||
run: make unit
|
run: make unit
|
||||||
|
|
||||||
|
- name: Check for capability drift
|
||||||
|
run: make check-capability-drift
|
||||||
|
|
||||||
Integration-Test:
|
Integration-Test:
|
||||||
# Note: changing this job name requires making the same update in the .github/workflows/release.yaml pipeline
|
# Note: changing this job name requires making the same update in the .github/workflows/release.yaml pipeline
|
||||||
name: "Integration tests"
|
name: "Integration tests"
|
||||||
@ -106,7 +109,7 @@ jobs:
|
|||||||
run: make snapshot-smoke-test
|
run: make snapshot-smoke-test
|
||||||
|
|
||||||
- name: Upload snapshot artifacts
|
- name: Upload snapshot artifacts
|
||||||
uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f #v6.0.0
|
uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f #v7.0.0
|
||||||
with:
|
with:
|
||||||
name: snapshot
|
name: snapshot
|
||||||
path: snapshot/
|
path: snapshot/
|
||||||
@ -131,7 +134,7 @@ jobs:
|
|||||||
download-test-fixture-cache: true
|
download-test-fixture-cache: true
|
||||||
|
|
||||||
- name: Download snapshot artifacts
|
- name: Download snapshot artifacts
|
||||||
uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 #v7.0.0
|
uses: actions/download-artifact@70fc10c6e5e1ce46ad2ea6f2b72d43f7d47b13c3 #v8.0.0
|
||||||
with:
|
with:
|
||||||
name: snapshot
|
name: snapshot
|
||||||
path: snapshot
|
path: snapshot
|
||||||
@ -175,7 +178,7 @@ jobs:
|
|||||||
download-test-fixture-cache: true
|
download-test-fixture-cache: true
|
||||||
|
|
||||||
- name: Download snapshot artifacts
|
- name: Download snapshot artifacts
|
||||||
uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 #v7.0.0
|
uses: actions/download-artifact@70fc10c6e5e1ce46ad2ea6f2b72d43f7d47b13c3 #v8.0.0
|
||||||
with:
|
with:
|
||||||
name: snapshot
|
name: snapshot
|
||||||
path: snapshot
|
path: snapshot
|
||||||
@ -208,7 +211,7 @@ jobs:
|
|||||||
download-test-fixture-cache: true
|
download-test-fixture-cache: true
|
||||||
|
|
||||||
- name: Download snapshot artifacts
|
- name: Download snapshot artifacts
|
||||||
uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 #v7.0.0
|
uses: actions/download-artifact@70fc10c6e5e1ce46ad2ea6f2b72d43f7d47b13c3 #v8.0.0
|
||||||
with:
|
with:
|
||||||
name: snapshot
|
name: snapshot
|
||||||
path: snapshot
|
path: snapshot
|
||||||
|
|||||||
1
.gitignore
vendored
1
.gitignore
vendored
@ -37,6 +37,7 @@ VERSION
|
|||||||
coverage.txt
|
coverage.txt
|
||||||
*.log
|
*.log
|
||||||
**/test-fixtures/test-observations.json
|
**/test-fixtures/test-observations.json
|
||||||
|
**/testdata/test-observations.json
|
||||||
|
|
||||||
# probable archives
|
# probable archives
|
||||||
.images
|
.images
|
||||||
|
|||||||
@ -8,7 +8,9 @@ vars:
|
|||||||
OWNER: anchore
|
OWNER: anchore
|
||||||
PROJECT: syft
|
PROJECT: syft
|
||||||
|
|
||||||
CACHE_IMAGE: ghcr.io/{{ .OWNER }}/{{ .PROJECT }}/test-fixture-cache:latest
|
# v1: when fixtures were located at test-fixtures dirs
|
||||||
|
# v2: migration to testdata dirs
|
||||||
|
CACHE_IMAGE: ghcr.io/{{ .OWNER }}/{{ .PROJECT }}/test-fixture-cache:v2
|
||||||
|
|
||||||
# static file dirs
|
# static file dirs
|
||||||
TOOL_DIR: .tool
|
TOOL_DIR: .tool
|
||||||
@ -73,7 +75,6 @@ tasks:
|
|||||||
- task: check-licenses
|
- task: check-licenses
|
||||||
- task: lint
|
- task: lint
|
||||||
- task: check-json-schema-drift
|
- task: check-json-schema-drift
|
||||||
- task: check-capability-drift
|
|
||||||
- task: check-binary-fixture-size
|
- task: check-binary-fixture-size
|
||||||
|
|
||||||
test:
|
test:
|
||||||
@ -199,7 +200,7 @@ tasks:
|
|||||||
check-binary-fixture-size:
|
check-binary-fixture-size:
|
||||||
desc: Ensure that the binary test fixtures are not too large
|
desc: Ensure that the binary test fixtures are not too large
|
||||||
cmds:
|
cmds:
|
||||||
- .github/scripts/check_binary_fixture_size.sh syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets
|
- .github/scripts/check_binary_fixture_size.sh syft/pkg/cataloger/binary/testdata/classifiers/snippets
|
||||||
|
|
||||||
|
|
||||||
## Testing tasks #################################
|
## Testing tasks #################################
|
||||||
@ -266,9 +267,9 @@ tasks:
|
|||||||
fingerprints:
|
fingerprints:
|
||||||
desc: Generate fingerprints for all non-docker test fixture
|
desc: Generate fingerprints for all non-docker test fixture
|
||||||
silent: true
|
silent: true
|
||||||
# this will look for `test-fixtures/Makefile` and invoke the `fingerprint` target to calculate all cache input fingerprint files
|
# this will look for `testdata/Makefile` and invoke the `fingerprint` target to calculate all cache input fingerprint files
|
||||||
generates:
|
generates:
|
||||||
- '**/test-fixtures/**/*.fingerprint'
|
- '**/testdata/**/*.fingerprint'
|
||||||
- test/install/cache.fingerprint
|
- test/install/cache.fingerprint
|
||||||
cmds:
|
cmds:
|
||||||
- |
|
- |
|
||||||
@ -277,7 +278,7 @@ tasks:
|
|||||||
RESET='\033[0m'
|
RESET='\033[0m'
|
||||||
|
|
||||||
echo -e "${YELLOW}creating fingerprint files for non-docker fixtures...${RESET}"
|
echo -e "${YELLOW}creating fingerprint files for non-docker fixtures...${RESET}"
|
||||||
for dir in $(find . -type d -name 'test-fixtures'); do
|
for dir in $(find . -type d -name 'testdata'); do
|
||||||
if [ -f "$dir/Makefile" ]; then
|
if [ -f "$dir/Makefile" ]; then
|
||||||
# for debugging...
|
# for debugging...
|
||||||
#echo -e "${YELLOW}• calculating fingerprints in $dir... ${RESET}"
|
#echo -e "${YELLOW}• calculating fingerprints in $dir... ${RESET}"
|
||||||
@ -370,7 +371,7 @@ tasks:
|
|||||||
build-fixtures:
|
build-fixtures:
|
||||||
desc: Generate all non-docker test fixtures
|
desc: Generate all non-docker test fixtures
|
||||||
silent: true
|
silent: true
|
||||||
# this will look for `test-fixtures/Makefile` and invoke the `fixtures` target to generate any and all test fixtures
|
# this will look for `testdata/Makefile` and invoke the `fixtures` target to generate any and all test fixtures
|
||||||
cmds:
|
cmds:
|
||||||
- |
|
- |
|
||||||
# we want to stop on the first build error
|
# we want to stop on the first build error
|
||||||
@ -381,7 +382,7 @@ tasks:
|
|||||||
RESET='\033[0m'
|
RESET='\033[0m'
|
||||||
|
|
||||||
# Use a for loop with command substitution to avoid subshell issues
|
# Use a for loop with command substitution to avoid subshell issues
|
||||||
for dir in $(find . -type d -name 'test-fixtures'); do
|
for dir in $(find . -type d -name 'testdata'); do
|
||||||
if [ -f "$dir/Makefile" ]; then
|
if [ -f "$dir/Makefile" ]; then
|
||||||
echo -e "${YELLOW}${BOLD}generating fixtures in $dir${RESET}"
|
echo -e "${YELLOW}${BOLD}generating fixtures in $dir${RESET}"
|
||||||
make -C "$dir" fixtures
|
make -C "$dir" fixtures
|
||||||
@ -435,7 +436,7 @@ tasks:
|
|||||||
- "echo 'Docker daemon cache:'"
|
- "echo 'Docker daemon cache:'"
|
||||||
- "docker images --format '{{`{{.ID}}`}} {{`{{.Repository}}`}}:{{`{{.Tag}}`}}' | grep stereoscope-fixture- | sort"
|
- "docker images --format '{{`{{.ID}}`}} {{`{{.Repository}}`}}:{{`{{.Tag}}`}}' | grep stereoscope-fixture- | sort"
|
||||||
- "echo '\nTar cache:'"
|
- "echo '\nTar cache:'"
|
||||||
- 'find . -type f -wholename "**/test-fixtures/cache/stereoscope-fixture-*.tar" | sort'
|
- 'find . -type f -wholename "**/testdata/cache/stereoscope-fixture-*.tar" | sort'
|
||||||
|
|
||||||
check-docker-cache:
|
check-docker-cache:
|
||||||
desc: Ensure docker caches aren't using too much disk space
|
desc: Ensure docker caches aren't using too much disk space
|
||||||
@ -469,7 +470,7 @@ tasks:
|
|||||||
- "cd test/install && make ci-test-mac"
|
- "cd test/install && make ci-test-mac"
|
||||||
|
|
||||||
generate-compare-file:
|
generate-compare-file:
|
||||||
cmd: "go run ./cmd/syft {{ .COMPARE_TEST_IMAGE }} -o json > {{ .COMPARE_DIR }}/test-fixtures/acceptance-{{ .COMPARE_TEST_IMAGE }}.json"
|
cmd: "go run ./cmd/syft {{ .COMPARE_TEST_IMAGE }} -o json > {{ .COMPARE_DIR }}/testdata/acceptance-{{ .COMPARE_TEST_IMAGE }}.json"
|
||||||
|
|
||||||
compare-mac:
|
compare-mac:
|
||||||
deps: [tmpdir]
|
deps: [tmpdir]
|
||||||
@ -537,11 +538,16 @@ tasks:
|
|||||||
deps:
|
deps:
|
||||||
- tmpdir
|
- tmpdir
|
||||||
- fixtures
|
- fixtures
|
||||||
|
vars:
|
||||||
|
# set REFRESH=true to run package tests first and refresh test observations (default: true)
|
||||||
|
REFRESH: '{{ .REFRESH | default "true" }}'
|
||||||
cmds:
|
cmds:
|
||||||
# remove all test observations prior to regenerating
|
# remove all test observations prior to regenerating
|
||||||
- task: clean-test-observations
|
- task: clean-test-observations
|
||||||
|
if: '{{ eq .REFRESH "true" }}'
|
||||||
# this is required to update test observations; such evidence is used to update the packages/*.yaml
|
# this is required to update test observations; such evidence is used to update the packages/*.yaml
|
||||||
- "go test ./syft/pkg/... -count=1"
|
- cmd: "go test ./syft/pkg/... -count=1"
|
||||||
|
if: '{{ eq .REFRESH "true" }}'
|
||||||
- "go generate ./internal/capabilities/..."
|
- "go generate ./internal/capabilities/..."
|
||||||
- "gofmt -s -w ./internal/capabilities"
|
- "gofmt -s -w ./internal/capabilities"
|
||||||
# now that we have the latest capabilities, run completeness tests to ensure this is self-consistent
|
# now that we have the latest capabilities, run completeness tests to ensure this is self-consistent
|
||||||
@ -639,6 +645,15 @@ tasks:
|
|||||||
|
|
||||||
## Cleanup targets #################################
|
## Cleanup targets #################################
|
||||||
|
|
||||||
|
clean:
|
||||||
|
desc: Remove all cache files and old builds
|
||||||
|
cmds:
|
||||||
|
- task: clean-snapshot
|
||||||
|
- task: clean-cache
|
||||||
|
- task: clean-test-observations
|
||||||
|
- task: clean-docker-cache
|
||||||
|
- task: clean-oras-cache
|
||||||
|
|
||||||
clean-snapshot:
|
clean-snapshot:
|
||||||
desc: Remove any snapshot builds
|
desc: Remove any snapshot builds
|
||||||
cmds:
|
cmds:
|
||||||
@ -648,7 +663,7 @@ tasks:
|
|||||||
clean-docker-cache:
|
clean-docker-cache:
|
||||||
desc: Remove all docker cache tars and images from the daemon
|
desc: Remove all docker cache tars and images from the daemon
|
||||||
cmds:
|
cmds:
|
||||||
- find . -type d -wholename "**/test-fixtures/cache" | xargs rm -rf
|
- find . -type d -wholename "**/testdata/cache" | xargs rm -rf
|
||||||
- docker images --format '{{`{{.ID}}`}} {{`{{.Repository}}`}}' | grep stereoscope-fixture- | awk '{print $1}' | uniq | xargs -r docker rmi --force
|
- docker images --format '{{`{{.ID}}`}} {{`{{.Repository}}`}}' | grep stereoscope-fixture- | awk '{print $1}' | uniq | xargs -r docker rmi --force
|
||||||
|
|
||||||
clean-oras-cache:
|
clean-oras-cache:
|
||||||
@ -665,7 +680,7 @@ tasks:
|
|||||||
RESET='\033[0m'
|
RESET='\033[0m'
|
||||||
|
|
||||||
# Use a for loop with command substitution to avoid subshell issues
|
# Use a for loop with command substitution to avoid subshell issues
|
||||||
for dir in $(find . -type d -name 'test-fixtures'); do
|
for dir in $(find . -type d -name 'testdata'); do
|
||||||
if [ -f "$dir/Makefile" ]; then
|
if [ -f "$dir/Makefile" ]; then
|
||||||
echo -e "${YELLOW}${BOLD}deleting ephemeral test fixtures in $dir${RESET}"
|
echo -e "${YELLOW}${BOLD}deleting ephemeral test fixtures in $dir${RESET}"
|
||||||
(make -C "$dir" clean)
|
(make -C "$dir" clean)
|
||||||
@ -675,6 +690,6 @@ tasks:
|
|||||||
- rm -f {{ .LAST_CACHE_PULL_FILE }} {{ .CACHE_PATHS_FILE }}
|
- rm -f {{ .LAST_CACHE_PULL_FILE }} {{ .CACHE_PATHS_FILE }}
|
||||||
|
|
||||||
clean-test-observations:
|
clean-test-observations:
|
||||||
desc: Remove all test observations (i.e. test-fixtures/test-observations.json)
|
desc: Remove all test observations (i.e. testdata/test-observations.json)
|
||||||
cmds:
|
cmds:
|
||||||
- find . -type f -wholename "**/test-fixtures/test-observations.json" | xargs rm -f
|
- find . -type f -wholename "**/testdata/test-observations.json" | xargs rm -f
|
||||||
|
|||||||
@ -219,7 +219,7 @@ func (l attestLogFrame) View() string {
|
|||||||
sb := strings.Builder{}
|
sb := strings.Builder{}
|
||||||
|
|
||||||
for _, line := range l.lines {
|
for _, line := range l.lines {
|
||||||
sb.WriteString(fmt.Sprintf(" %s %s\n", l.borderStype.Render("░░"), line))
|
fmt.Fprintf(&sb, " %s %s\n", l.borderStype.Render("░░"), line)
|
||||||
}
|
}
|
||||||
|
|
||||||
return sb.String()
|
return sb.String()
|
||||||
|
|||||||
@ -49,7 +49,7 @@ func AppClioSetupConfig(id clio.Identification, out io.Writer) *clio.SetupConfig
|
|||||||
},
|
},
|
||||||
).
|
).
|
||||||
WithPostRuns(func(_ *clio.State, _ error) {
|
WithPostRuns(func(_ *clio.State, _ error) {
|
||||||
stereoscope.Cleanup()
|
stereoscope.Cleanup() //nolint:staticcheck // we don't have access to the image object here
|
||||||
})
|
})
|
||||||
return clioCfg
|
return clioCfg
|
||||||
}
|
}
|
||||||
|
|||||||
@ -19,30 +19,30 @@ func Test_scanOptions_validateLegacyOptionsNotUsed(t *testing.T) {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "config file with no legacy options",
|
name: "config file with no legacy options",
|
||||||
cfg: "test-fixtures/scan-configs/no-legacy-options.yaml",
|
cfg: "testdata/scan-configs/no-legacy-options.yaml",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "config file with default image pull source legacy option",
|
name: "config file with default image pull source legacy option",
|
||||||
cfg: "test-fixtures/scan-configs/with-default-pull-source.yaml",
|
cfg: "testdata/scan-configs/with-default-pull-source.yaml",
|
||||||
wantErr: assertErrorContains("source.image.default-pull-source"),
|
wantErr: assertErrorContains("source.image.default-pull-source"),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "config file with exclude-binary-overlap-by-ownership legacy option",
|
name: "config file with exclude-binary-overlap-by-ownership legacy option",
|
||||||
cfg: "test-fixtures/scan-configs/with-exclude-binary-overlap-by-ownership.yaml",
|
cfg: "testdata/scan-configs/with-exclude-binary-overlap-by-ownership.yaml",
|
||||||
wantErr: assertErrorContains("package.exclude-binary-overlap-by-ownership"),
|
wantErr: assertErrorContains("package.exclude-binary-overlap-by-ownership"),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "config file with file string legacy option",
|
name: "config file with file string legacy option",
|
||||||
cfg: "test-fixtures/scan-configs/with-file-string.yaml",
|
cfg: "testdata/scan-configs/with-file-string.yaml",
|
||||||
wantErr: assertErrorContains("outputs"),
|
wantErr: assertErrorContains("outputs"),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "config file with file section",
|
name: "config file with file section",
|
||||||
cfg: "test-fixtures/scan-configs/with-file-section.yaml",
|
cfg: "testdata/scan-configs/with-file-section.yaml",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "config file with base-path legacy option",
|
name: "config file with base-path legacy option",
|
||||||
cfg: "test-fixtures/scan-configs/with-base-path.yaml",
|
cfg: "testdata/scan-configs/with-base-path.yaml",
|
||||||
wantErr: assertErrorContains("source.base-path"),
|
wantErr: assertErrorContains("source.base-path"),
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
@ -107,7 +107,7 @@ func fetchLatestApplicationVersion(id clio.Identification) (*hashiVersion.Versio
|
|||||||
return nil, fmt.Errorf("HTTP %d on fetching latest version: %s", resp.StatusCode, resp.Status)
|
return nil, fmt.Errorf("HTTP %d on fetching latest version: %s", resp.StatusCode, resp.Status)
|
||||||
}
|
}
|
||||||
|
|
||||||
versionBytes, err := io.ReadAll(resp.Body)
|
versionBytes, err := io.ReadAll(io.LimitReader(resp.Body, 500))
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, fmt.Errorf("failed to read latest version: %w", err)
|
return nil, fmt.Errorf("failed to read latest version: %w", err)
|
||||||
}
|
}
|
||||||
|
|||||||
@ -122,7 +122,7 @@ func formatVersionOptions(nameVersionPairs []string) string {
|
|||||||
for _, name := range sortedAvailableFormats {
|
for _, name := range sortedAvailableFormats {
|
||||||
s.WriteString("\n")
|
s.WriteString("\n")
|
||||||
|
|
||||||
s.WriteString(fmt.Sprintf(" - %s", name))
|
fmt.Fprintf(&s, " - %s", name)
|
||||||
|
|
||||||
if len(availableVersions[name]) > 0 {
|
if len(availableVersions[name]) > 0 {
|
||||||
s.WriteString(" @ ")
|
s.WriteString(" @ ")
|
||||||
|
|||||||
@ -125,7 +125,7 @@ func TestPkgCoverageImage(t *testing.T) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func TestPkgCoverageDirectory(t *testing.T) {
|
func TestPkgCoverageDirectory(t *testing.T) {
|
||||||
sbom, _ := catalogDirectory(t, "test-fixtures/image-pkg-coverage")
|
sbom, _ := catalogDirectory(t, "testdata/image-pkg-coverage")
|
||||||
|
|
||||||
observedLanguages := strset.New()
|
observedLanguages := strset.New()
|
||||||
definedLanguages := strset.New()
|
definedLanguages := strset.New()
|
||||||
@ -261,7 +261,7 @@ func TestPkgCoverageImage_HasEvidence(t *testing.T) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func TestPkgCoverageDirectory_HasEvidence(t *testing.T) {
|
func TestPkgCoverageDirectory_HasEvidence(t *testing.T) {
|
||||||
sbom, _ := catalogDirectory(t, "test-fixtures/image-pkg-coverage")
|
sbom, _ := catalogDirectory(t, "testdata/image-pkg-coverage")
|
||||||
|
|
||||||
var cases []testCase
|
var cases []testCase
|
||||||
cases = append(cases, commonTestCases...)
|
cases = append(cases, commonTestCases...)
|
||||||
|
|||||||
@ -22,7 +22,7 @@ import (
|
|||||||
func TestFileCataloging_Default(t *testing.T) {
|
func TestFileCataloging_Default(t *testing.T) {
|
||||||
cfg := options.DefaultCatalog().ToSBOMConfig(clio.Identification{})
|
cfg := options.DefaultCatalog().ToSBOMConfig(clio.Identification{})
|
||||||
cfg = cfg.WithFilesConfig(filecataloging.DefaultConfig())
|
cfg = cfg.WithFilesConfig(filecataloging.DefaultConfig())
|
||||||
sbom, _ := catalogDirectoryWithConfig(t, "test-fixtures/files", cfg)
|
sbom, _ := catalogDirectoryWithConfig(t, "testdata/files", cfg)
|
||||||
|
|
||||||
var metadata map[file.Coordinates]file.Metadata
|
var metadata map[file.Coordinates]file.Metadata
|
||||||
|
|
||||||
@ -48,13 +48,13 @@ func TestFileCataloging_AllFiles(t *testing.T) {
|
|||||||
SkipFilesAboveSize: 30,
|
SkipFilesAboveSize: 30,
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
sbom, _ := catalogDirectoryWithConfig(t, "test-fixtures/files", cfg)
|
sbom, _ := catalogDirectoryWithConfig(t, "testdata/files", cfg)
|
||||||
|
|
||||||
pwd, err := os.Getwd()
|
pwd, err := os.Getwd()
|
||||||
require.NoError(t, err)
|
require.NoError(t, err)
|
||||||
|
|
||||||
testPath := func(path string) string {
|
testPath := func(path string) string {
|
||||||
return filepath.Join(pwd, "test-fixtures/files", path)
|
return filepath.Join(pwd, "testdata/files", path)
|
||||||
}
|
}
|
||||||
|
|
||||||
metadata := map[file.Coordinates]file.Metadata{
|
metadata := map[file.Coordinates]file.Metadata{
|
||||||
|
|||||||
@ -11,7 +11,7 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
func TestNpmPackageLockDirectory(t *testing.T) {
|
func TestNpmPackageLockDirectory(t *testing.T) {
|
||||||
sbom, _ := catalogDirectory(t, "test-fixtures/npm-lock")
|
sbom, _ := catalogDirectory(t, "testdata/npm-lock")
|
||||||
|
|
||||||
foundPackages := strset.New()
|
foundPackages := strset.New()
|
||||||
|
|
||||||
@ -32,7 +32,7 @@ func TestNpmPackageLockDirectory(t *testing.T) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func TestYarnPackageLockDirectory(t *testing.T) {
|
func TestYarnPackageLockDirectory(t *testing.T) {
|
||||||
sbom, _ := catalogDirectory(t, "test-fixtures/yarn-lock")
|
sbom, _ := catalogDirectory(t, "testdata/yarn-lock")
|
||||||
|
|
||||||
foundPackages := strset.New()
|
foundPackages := strset.New()
|
||||||
// merge-objects and should-type are devDependencies in package.json and are excluded by default
|
// merge-objects and should-type are devDependencies in package.json and are excluded by default
|
||||||
|
|||||||
@ -26,7 +26,7 @@ func TestBinaryElfRelationships(t *testing.T) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// run the test...
|
// run the test...
|
||||||
sbom, _ := catalogFixtureImage(t, "elf-test-fixtures", source.SquashedScope)
|
sbom, _ := catalogFixtureImage(t, "elf-testdata", source.SquashedScope)
|
||||||
|
|
||||||
// get a mapping of package names to their IDs
|
// get a mapping of package names to their IDs
|
||||||
nameToId := map[string]artifact.ID{}
|
nameToId := map[string]artifact.ID{}
|
||||||
|
|||||||
@ -278,7 +278,7 @@ func packageCatalogerExports(t *testing.T) map[string]exportTokenSet {
|
|||||||
if info.IsDir() ||
|
if info.IsDir() ||
|
||||||
!strings.HasSuffix(info.Name(), ".go") ||
|
!strings.HasSuffix(info.Name(), ".go") ||
|
||||||
strings.HasSuffix(info.Name(), "_test.go") ||
|
strings.HasSuffix(info.Name(), "_test.go") ||
|
||||||
strings.Contains(path, "test-fixtures") ||
|
strings.Contains(path, "testdata") ||
|
||||||
strings.Contains(path, "internal") {
|
strings.Contains(path, "internal") {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1 +0,0 @@
|
|||||||
../../../../../../syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures
|
|
||||||
@ -1 +0,0 @@
|
|||||||
See the syft/cataloger/java/test-fixtures/java-builds dir to generate test fixtures and copy to here manually.
|
|
||||||
@ -1,5 +1,5 @@
|
|||||||
# we should strive to not commit blobs to the repo and strive to keep the build process of how blobs are acquired in-repo.
|
# we should strive to not commit blobs to the repo and strive to keep the build process of how blobs are acquired in-repo.
|
||||||
# this blob is generated from syft/syft/catalogers/java/test-fixtures/java-builds , however, preserving the build process
|
# this blob is generated from syft/syft/catalogers/java/testdata/java-builds , however, preserving the build process
|
||||||
# twice in the repo seems redundant (even via symlink). Given that the fixture is a few kilobytes in size, the build process is already
|
# twice in the repo seems redundant (even via symlink). Given that the fixture is a few kilobytes in size, the build process is already
|
||||||
# captured, and integration tests should only be testing if jars can be discovered (not necessarily depth in java detection
|
# captured, and integration tests should only be testing if jars can be discovered (not necessarily depth in java detection
|
||||||
# functionality), committing it seems like an acceptable exception.
|
# functionality), committing it seems like an acceptable exception.
|
||||||
1
cmd/syft/internal/test/integration/testdata/elf-testdata
vendored
Symbolic link
1
cmd/syft/internal/test/integration/testdata/elf-testdata
vendored
Symbolic link
@ -0,0 +1 @@
|
|||||||
|
../../../../../../syft/pkg/cataloger/binary/testdata/elf-testdata
|
||||||
@ -0,0 +1 @@
|
|||||||
|
See the syft/cataloger/java/testdata/java-builds dir to generate test fixtures and copy to here manually.
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user