From b5e85c3ea54b7307337c3e570145ba4ec0436873 Mon Sep 17 00:00:00 2001 From: Alex Goodman Date: Fri, 6 Mar 2026 14:42:04 -0500 Subject: [PATCH] chore: migrate fixtures to testdata (#4651) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * migrate fixtures to testdata Signed-off-by: Alex Goodman * fix: correct broken symlinks after testdata migration The migration from test-fixtures to testdata broke several symlinks: - elf-test-fixtures symlinks pointed to old test-fixtures paths - elf-test-fixtures needed to be renamed to elf-testdata - image-pkg-coverage symlink pointed to test-fixtures instead of testdata Signed-off-by: Alex Goodman * fix: handle missing classifiers/bin directory in Makefile The clean-fingerprint target was failing when classifiers/bin doesn't exist (e.g., on fresh clone without downloaded binaries). Signed-off-by: Alex Goodman * fix: add gitignore negation for jar/zip fixtures in test/cli The jar and zip files in test/cli/testdata/image-unknowns were being gitignored by the root .gitignore patterns. This caused them to be untracked and not included when building docker images in CI, resulting in Test_Unknowns failures since the test expects errors from corrupt archive files that weren't present. Add a .gitignore in test/cli/testdata to negate the exclusions for these specific test fixture files. Signed-off-by: Alex Goodman * switch fixture cache to v2 Signed-off-by: Alex Goodman * test: update expected versions for rebuilt fixtures Update test expectations for packages that have been updated in upstream repositories when docker images are rebuilt: - glibc: 2.42-r4 → 2.43-r1 (wolfi) - php: 8.2.29 → 8.2.30 (ubuntu/apache) Signed-off-by: Alex Goodman * upgrade go Signed-off-by: Alex Goodman * fix: add go-shlex dependency for testdata manager tool The manager tool in syft/pkg/cataloger/binary/testdata/ imports go-shlex, but since it's in a testdata directory, Go doesn't track its dependencies. This caused CI failures when go.mod didn't explicitly list the dependency. Signed-off-by: Alex Goodman * refactor: move binary classifier manager to internal/ Move the manager tool from testdata/manager to internal/manager so that Go properly tracks its dependencies. Code in testdata directories is ignored by Go for dependency tracking, which caused CI failures when go.mod didn't explicitly list transitive dependencies. This is a cleaner solution than manually adding dependencies to go.mod for code that happens to live in testdata. Signed-off-by: Alex Goodman * fix: add gitignore negations for test fixtures blocked by root patterns Multiple test fixtures were being blocked by root-level gitignore patterns like bin/, *.jar, *.tar, and *.exe. This adds targeted .gitignore files with negation patterns to allow these specific test fixtures to be tracked: - syft/linux/testdata/os/busybox/bin/busybox (blocked by bin/) - syft/pkg/cataloger/java/testdata/corrupt/example.{jar,tar} (blocked by *.jar, *.tar) - syft/pkg/cataloger/binary/testdata/classifiers/snippets/go-version-hint/**/bin/go (blocked by bin/) - syft/pkg/cataloger/bitnami/testdata/no-rel/.../bin/redis-server (blocked by bin/) Also updates the bitnami test expectation to include the newly required .gitignore files in the test fixture. Signed-off-by: Alex Goodman * test: update glibc version expectation (2.43-r1 -> 2.43-r2) Signed-off-by: Alex Goodman * add capability drift check as unit step Signed-off-by: Alex Goodman * dont clear test observations before drift detection Signed-off-by: Alex Goodman * bump stereoscope commit to main Signed-off-by: Alex Goodman --------- Signed-off-by: Alex Goodman --- .github/actions/bootstrap/action.yaml | 2 +- .github/scripts/capability-drift-check.sh | 2 +- .../scripts/fingerprint_docker_fixtures.py | 4 +- .github/workflows/validations.yaml | 3 + .gitignore | 1 + Taskfile.yaml | 45 ++++-- cmd/syft/internal/clio_setup_config.go | 2 +- cmd/syft/internal/commands/scan_test.go | 12 +- .../scan-configs/no-legacy-options.yaml | 0 .../scan-configs/with-base-path.yaml | 0 .../with-default-pull-source.yaml | 0 ...h-exclude-binary-overlap-by-ownership.yaml | 0 .../scan-configs/with-file-section.yaml | 0 .../scan-configs/with-file-string.yaml | 0 .../test/integration/catalog_packages_test.go | 4 +- .../internal/test/integration/files_test.go | 6 +- .../test/integration/node_packages_test.go | 4 +- .../package_binary_elf_relationships_test.go | 2 +- .../package_cataloger_convention_test.go | 2 +- .../test-fixtures/elf-test-fixtures | 1 - .../pkgs/java/generate-fixtures.md | 1 - .../{test-fixtures => testdata}/.gitignore | 2 +- .../{test-fixtures => testdata}/Makefile | 0 .../test/integration/testdata/elf-testdata | 1 + .../files/somewhere/there/is/a-small-file | 0 .../there/is/a-symlink-to-a-small-file | 0 .../somewhere/there/is/a-symlink-to-file | 0 .../files/somewhere/there/is/a/file | 0 .../image-distro-id/Dockerfile | 0 .../image-go-bin-arch-coverage/Dockerfile | 0 .../image-go-bin-arch-coverage/app.go | 0 .../image-go-bin-arch-coverage/go.mod | 0 .../image-go-bin-arch-coverage/go.sum | 0 .../image-go-bin-arch-coverage/test | Bin .../image-golang-compiler/Dockerfile | 0 .../image-java-no-main-package/Dockerfile | 0 .../Dockerfile | 0 .../extract.py | 0 .../image-large-apk-data/Dockerfile | 0 .../image-mariner-distroless/Dockerfile | 0 .../image-os-binary-overlap/Dockerfile | 0 .../image-owning-package/Dockerfile | 0 .../image-photon-all-layers/Dockerfile | 0 .../image-pkg-coverage/Dockerfile | 0 .../image-pkg-coverage/cocoapods/Podfile.lock | 0 .../image-pkg-coverage/composer/composer.lock | 0 .../image-pkg-coverage/conan/conanfile.txt | 0 .../image-pkg-coverage/etc/os-release | 0 .../hackage/cabal.project.freeze | 0 .../image-pkg-coverage/hackage/stack.yaml | 0 .../hackage/stack.yaml.lock | 0 .../image-pkg-coverage/lib/apk/db/installed | 0 .../image-pkg-coverage/pkgs/dart/pubspec.lock | 0 .../pkgs/dotnet/TestLibrary.deps.json | 0 .../image-pkg-coverage/pkgs/elixir/mix.lock | 0 .../image-pkg-coverage/pkgs/erlang/accept.app | 0 .../image-pkg-coverage/pkgs/erlang/rebar.lock | 0 .../.github/workflows/validations.yaml | 0 .../image-pkg-coverage/pkgs/go/go.mod | 0 .../Cellar/afflib/1.2.3/.brew/afflib.rb | 0 .../java/example-java-app-maven-0.1.0.jar | Bin .../pkgs/java/example-jenkins-plugin.hpi | Bin .../pkgs/java/generate-fixtures.md | 1 + .../image-pkg-coverage/pkgs/java/pom.xml | 0 .../pkgs/javascript/package-json/package.json | 0 .../javascript/package-lock/package-lock.json | 0 .../pkgs/javascript/yarn/yarn.lock | 0 .../pkgs/lib/apk/db/installed | 0 .../share/man/glibc.1 | 0 .../pkgs/opam/ocaml-base-compiler.4.14.0/opam | 0 .../.channel.pecl.php.net/memcached.reg | 0 .../pkgs/php/vendor/composer/installed.json | 0 .../pkgs/python/dist-info/METADATA | 0 .../pkgs/python/dist-info/RECORD | 0 .../pkgs/python/dist-info/top_level.txt | 0 .../pkgs/python/egg-info/PKG-INFO | 0 .../pkgs/python/egg-info/top_level.txt | 0 .../pkgs/python/requires/requirements-dev.txt | 0 .../pkgs/python/requires/requirements.txt | 0 .../python/requires/test-requirements.txt | 0 .../pkgs/python/setup/setup.py | 0 .../PKG-INFO | 0 .../top_level.txt | 0 .../somerequests-3.22.0.dist-info/METADATA | 0 .../top_level.txt | 0 .../pkgs/r/base/DESCRIPTION | 0 .../pkgs/rockspec/kong-3.7.0-0.rockspec | 0 .../image-pkg-coverage/pkgs/ruby/Gemfile.lock | 0 .../pkgs/ruby/specifications/bundler.gemspec | 0 .../specifications/default/unbundler.gemspec | 0 .../image-pkg-coverage/pkgs/rust/Cargo.lock | 0 .../pkg/app-containers/skopeo-1.5.1/CONTENTS | 0 .../pkg/app-containers/skopeo-1.5.1/LICENSE | 0 .../db/pkg/app-containers/skopeo-1.5.1/SIZE | 0 .../pkgs/var/lib/dpkg/status | 0 .../pkgs/var/lib/dpkg/status.d/dash | 0 .../pkgs/var/lib/dpkg/status.d/netbase | 0 .../pkgs/var/lib/pacman/local/ALPM_DB_VERSION | 0 .../var/lib/pacman/local/pacman-6.0.1-5/desc | 0 .../var/lib/pacman/local/pacman-6.0.1-5/files | 0 .../var/lib/pacman/local/pacman-6.0.1-5/mtree | Bin .../pkgs/var/lib/rpm/Packages | Bin .../pkgs/var/lib/rpm/generate-fixture.sh | 0 .../wp-content/plugins/akismet/akismet.php | 0 .../image-pkg-coverage/swift/Package.resolved | 0 .../image-pkg-coverage/swipl/pack/hdt/pack.pl | 0 .../terraform/.terraform.lock.hcl | 0 .../image-rust-auditable/Dockerfile | 0 .../image-sbom-cataloger/Dockerfile | 0 .../image-sbom-cataloger/go.mod | 0 .../image-sbom-cataloger/test.spdx.json | 0 .../image-sbom-metadata-component/Dockerfile | 0 .../test.cdx.json | 0 .../image-sqlite-rpmdb/Dockerfile | 0 .../image-suse-all-layers/Dockerfile | 0 .../image-test-java-purls/Dockerfile | 0 .../image-test-java-purls/extract.py | 0 .../image-vertical-package-dups/Dockerfile | 0 .../collapse-white-space/index.d.ts | 0 .../collapse-white-space/index.js | 0 .../node_modules/collapse-white-space/license | 0 .../collapse-white-space/package-lock.json | 0 .../collapse-white-space/package.json | 0 .../collapse-white-space/readme.md | 0 .../node_modules/end-of-stream/LICENSE | 0 .../node_modules/end-of-stream/README.md | 0 .../node_modules/end-of-stream/index.js | 0 .../node_modules/end-of-stream/package.json | 0 .../npm-lock/node_modules/insert-css/LICENSE | 0 .../node_modules/insert-css/example.js | 0 .../npm-lock/node_modules/insert-css/index.js | 0 .../node_modules/insert-css/package.json | 0 .../node_modules/insert-css/readme.markdown | 0 .../npm-lock/node_modules/insert-css/test.js | 0 .../npm-lock/node_modules/once/LICENSE | 0 .../npm-lock/node_modules/once/README.md | 0 .../npm-lock/node_modules/once/once.js | 0 .../npm-lock/node_modules/once/package.json | 0 .../npm-lock/node_modules/pump/.travis.yml | 0 .../npm-lock/node_modules/pump/LICENSE | 0 .../npm-lock/node_modules/pump/README.md | 0 .../npm-lock/node_modules/pump/index.js | 0 .../npm-lock/node_modules/pump/package.json | 0 .../node_modules/pump/test-browser.js | 0 .../npm-lock/node_modules/pump/test-node.js | 0 .../npm-lock/node_modules/wrappy/LICENSE | 0 .../npm-lock/node_modules/wrappy/README.md | 0 .../node_modules/wrappy/package-lock.json | 0 .../npm-lock/node_modules/wrappy/package.json | 0 .../npm-lock/node_modules/wrappy/wrappy.js | 0 .../npm-lock/package-lock.json | 0 .../npm-lock/package.json | 0 .../yarn-lock/node_modules/async/LICENSE | 0 .../yarn-lock/node_modules/async/bower.json | 0 .../yarn-lock/node_modules/async/package.json | 0 .../node_modules/merge-objects/LICENSE.md | 0 .../node_modules/merge-objects/package.json | 0 .../resize-observer-polyfill/LICENSE | 0 .../resize-observer-polyfill/package.json | 0 .../node_modules/should-type/LICENSE | 0 .../node_modules/should-type/package.json | 0 .../yarn-lock/package.json | 0 .../nested-package/node_modules/async/LICENSE | 0 .../node_modules/async/bower.json | 0 .../node_modules/async/component.json | 0 .../node_modules/async/package.json | 0 .../packages/nested-package/package.json | 0 .../yarn-lock/yarn.lock | 0 go.mod | 63 ++++---- go.sum | 147 ++++++++---------- internal/capabilities/generate/README.md | 18 +-- .../generate/discover_metadata.go | 4 +- internal/capabilities/internal/fixtures.go | 12 +- .../internal/load_capabilities_test.go | 8 +- internal/file/digest_test.go | 4 +- .../{test-fixtures => testdata}/digest.txt | 0 .../{test-fixtures => testdata}/empty.txt | 0 .../generate-zip-fixture-from-source-dir.sh | 0 .../zip-source/b-file.txt | 0 .../zip-source/b-file/in-subdir.txt | 0 .../zip-source/some-dir/a-file.txt | 0 internal/file/zip_file_helpers_test.go | 2 +- internal/file/zip_file_manifest_test.go | 6 +- internal/file/zip_file_traversal_test.go | 2 +- internal/licenses/find_evidence_test.go | 4 +- .../{test-fixtures => testdata}/Knuth-CTAN | 0 .../apache-license-2.0 | 0 .../{test-fixtures => testdata}/multi-license | 0 .../nvidia-software-and-cuda-supplement | 0 .../not_rhel/Dockerfile | 0 .../not_rhel/etc/os-release | 0 ...10647.p0.g1d5732f.assembly.stream.el9.json | 0 .../rhel_content_manifests/Dockerfile | 0 .../rhel_content_manifests/etc/os-release | 0 ...10647.p0.g1d5732f.assembly.stream.el9.json | 0 ...90033.p0.gb45ea65.assembly.stream.el9.json | 0 .../rhel_no_manifests/Dockerfile | 0 .../rhel_no_manifests/etc/os-release | 0 .../binary/test-fixtures/elf-test-fixtures | 1 - .../relationship/binary/testdata/elf-testdata | 1 + .../generate/generate_license_list_test.go | 2 +- .../{test-fixtures => testdata}/licenses.json | 0 internal/testutils/golden_files.go | 69 ++++++++ syft/cpe/cpe_test.go | 2 +- .../{test-fixtures => testdata}/cpe-data.json | 0 syft/file/cataloger/executable/elf_test.go | 6 +- syft/file/cataloger/executable/macho_test.go | 6 +- syft/file/cataloger/executable/pe_test.go | 4 +- .../{test-fixtures => testdata}/.gitignore | 0 .../{test-fixtures => testdata}/Makefile | 0 .../elf/.gitignore | 0 .../elf/Dockerfile | 0 .../{test-fixtures => testdata}/elf/Makefile | 0 .../elf/differ/__main__.py | 0 .../elf/expected_verify | 0 .../elf/project/Makefile | 0 .../elf/project/lib.c | 0 .../elf/project/lib.h | 0 .../elf/project/main.c | 0 .../shared-info/.gitignore | 0 .../shared-info/Dockerfile | 0 .../shared-info/Makefile | 0 .../shared-info/project/Makefile | 0 .../shared-info/project/hello/Makefile | 0 .../shared-info/project/hello/hello.c | 0 .../shared-info/project/libhello/Makefile | 0 .../shared-info/project/libhello/hello.c | 0 .../shared-info/project/libhello/hello.h | 0 .../cataloger/filecontent/cataloger_test.go | 28 ++-- .../{test-fixtures => testdata}/a-path.txt | 0 .../another-path.txt | 0 .../last/empty/empty | 0 .../{test-fixtures => testdata}/last/path.txt | 0 .../cataloger/filedigest/cataloger_test.go | 10 +- .../image-file-type-mix/Dockerfile | 0 .../image-file-type-mix/file-1.txt | 0 .../last/empty/empty | 0 .../{test-fixtures => testdata}/last/path.txt | 0 .../image-file-type-mix/Dockerfile | 0 .../image-file-type-mix/file-1.txt | 0 .../internal/all_regular_files_test.go | 2 +- .../image-file-type-mix/Dockerfile | 0 .../image-file-type-mix/file-1.txt | 0 .../symlinked-root/nested/link-root | 0 .../symlinked-root/real-root/file1.txt | 0 .../symlinked-root/real-root/nested/file2.txt | 0 .../real-root/nested/linked-file1.txt | 0 .../req-resp/.gitignore | 0 .../req-resp/path/to/rel-inside.txt | 0 .../req-resp/path/to/the/file.txt | 0 .../req-resp/path/to/the/rel-outside.txt | 0 .../req-resp/root-link | 0 .../req-resp/somewhere/outside.txt | 0 syft/format/cpes/decoder_test.go | 2 +- syft/format/cyclonedxjson/decoder_test.go | 8 +- .../{test-fixtures => testdata}/bad-sbom | 0 .../identify/1.2.json | 0 .../identify/1.3.json | 0 .../identify/1.4.json | 0 .../identify/1.5.json | 0 .../identify/1.6.json | 0 .../identify/micronaut-1.4.json | 0 .../identify/micronaut-1.5.json | 0 .../identify/micronaut-1.6.json | 0 .../TestCycloneDxDirectoryEncoder.golden | 0 .../snapshot/TestCycloneDxImageEncoder.golden | 0 syft/format/cyclonedxxml/decoder_test.go | 4 +- .../{test-fixtures => testdata}/bad-sbom | 0 .../identify/1.0.xml | 0 .../identify/1.1.xml | 0 .../identify/1.2.xml | 0 .../identify/1.3.xml | 0 .../identify/1.4.xml | 0 .../identify/1.5.xml | 0 .../identify/1.6.xml | 0 .../TestCycloneDxDirectoryEncoder.golden | 0 .../snapshot/TestCycloneDxImageEncoder.golden | 0 syft/format/decoders_collection_test.go | 4 +- .../TestGithubDirectoryEncoder.golden | 0 .../snapshot/TestGithubImageEncoder.golden | 0 syft/format/internal/testutil/image_input.go | 2 +- syft/format/internal/testutil/snapshot.go | 2 +- .../image-simple/Dockerfile | 0 .../image-simple/file-1.txt | 0 .../image-simple/file-2.txt | 0 .../snapshot/TestImageEncoder.golden | 0 .../TestSPDXTagValueImageEncoder.golden | 0 .../stereoscope-fixture-image-simple.golden | Bin .../snapshot/Test_Encoder.golden | 0 syft/format/spdxjson/decoder_test.go | 4 +- .../identify/2.2.json | 0 .../identify/2.3.json | 0 .../TestSPDX22JSONRequredProperties.golden | 0 .../TestSPDXJSONDirectoryEncoder.golden | 0 .../snapshot/TestSPDXJSONImageEncoder.golden | 0 .../snapshot/TestSPDXRelationshipOrder.golden | 0 .../spdx/alpine-3.10.syft.spdx.json | 0 .../spdx/alpine-3.10.vendor.spdx.json | 0 .../spdx/bad/bad-sbom | 0 .../spdx/bad/example7-bin.spdx.json | 0 .../spdx/bad/example7-go-module.spdx.json | 0 .../spdx/bad/example7-golang.spdx.json | 0 .../example7-third-party-modules.spdx.json | 0 .../spdx/example7-bin.spdx.json | 0 .../spdx/example7-go-module.spdx.json | 0 .../spdx/example7-golang.spdx.json | 0 .../example7-third-party-modules.spdx.json | 0 syft/format/spdxtagvalue/decoder_test.go | 4 +- .../{test-fixtures => testdata}/bad-sbom | 0 .../identify/2.1.sbom | 0 .../identify/2.2.sbom | 0 .../identify/2.3.sbom | 0 .../snapshot/TestSPDXJSONSPDXIDs.golden | 0 .../snapshot/TestSPDXRelationshipOrder.golden | 0 .../TestSPDXTagValueDirectoryEncoder.golden | 0 .../TestSPDXTagValueImageEncoder.golden | 0 .../tag-value.spdx | 0 .../identify/11.0.0.json | 0 .../image-alpine/Dockerfile | 0 .../snapshot/TestDirectoryEncoder.golden | 0 .../TestEncodeFullJSONDocument.golden | 0 .../snapshot/TestImageEncoder.golden | 0 .../snapshot/TestTableEncoder.golden | 0 syft/format/template/encoder_test.go | 8 +- .../csv-hasField.template | 0 .../{test-fixtures => testdata}/csv.template | 0 .../legacy/csv-hasField.template | 0 .../legacy/csv.template | 0 .../snapshot/TestFormatWithOption.golden | 0 .../TestFormatWithOptionAndHasField.golden | 0 ...tFormatWithOptionAndHasField_Legacy.golden | 0 .../TestFormatWithOption_Legacy.golden | 0 .../alpine-syft.json | 0 .../snapshot/TestTextDirectoryEncoder.golden | 0 .../snapshot/TestTextImageEncoder.golden | 0 .../stereoscope-fixture-image-simple.golden | Bin .../fileresolver/chroot_context_test.go | 4 +- .../fileresolver/directory_indexer_test.go | 32 ++-- .../fileresolver/file_indexer_test.go | 14 +- .../fileresolver/filetree_resolver_test.go | 94 +++++------ syft/internal/fileresolver/metadata_test.go | 8 +- .../bad-symlinks/root/place/fd | 0 .../generate-tar-fixture-from-source-dir.sh | 0 .../image-duplicate-path/Dockerfile | 0 .../image-duplicate-path/file-1.txt | 0 .../image-duplicate-path/file-2.txt | 0 .../image-files-deleted/Dockerfile | 0 .../image-files-deleted/file-1.txt | 0 .../image-files-deleted/file-3.txt | 0 .../image-files-deleted/target/file-2.txt | 0 .../image-simple/Dockerfile | 0 .../image-simple/file-1.txt | 0 .../image-simple/file-2.txt | 0 .../target/really/nested/file-3.txt | 0 .../image-symlinks/Dockerfile | 0 .../image-symlinks/file-1.txt | 0 .../image-symlinks/file-2.txt | 0 .../image-symlinks/nested/nested/file-3.txt | 0 .../image-symlinks/new-file-2.txt | 0 .../image-symlinks/new-file-4.txt | 0 .../image-symlinks/parent/file-4.txt | 0 .../path-detected-2/.vimrc | 0 .../path-detected-2/empty | 0 .../path-detected/.vimrc | 0 .../path-detected/empty | 0 .../req-resp/.gitignore | 0 .../req-resp/path/to/rel-inside.txt | 0 .../req-resp/path/to/the/file.txt | 0 .../req-resp/path/to/the/rel-outside.txt | 0 .../req-resp/root-link | 0 .../req-resp/somewhere/outside.txt | 0 .../symlinked-root/nested/link-root | 0 .../symlinked-root/real-root/file1.txt | 0 .../symlinked-root/real-root/nested/file2.txt | 0 .../real-root/nested/linked-file1.txt | 0 .../symlinks-base/bar | 0 .../symlinks-base/base | 0 .../symlinks-base/baz | 0 .../symlinks-base/chain | 0 .../symlinks-base/foo | 0 .../symlinks-base/sub/item | 0 .../symlinks-base/sub/link | 0 .../file-1.txt | 0 .../file-2.txt | 0 .../file-3.txt | 0 .../link-1 | 0 .../link-2 | 0 .../link-dead | 0 .../link-indirect | 0 .../link-within | 0 .../parent-link | 0 .../parent/file-4.txt | 0 .../symlinks-loop/README.md | 0 .../symlinks-loop/block/loop0 | 0 .../symlinks-loop/devices/loop0/file.target | 0 .../symlinks-loop/devices/loop0/subsystem | 0 .../outside/link_to_readme | 0 .../root/link_to_link_to_readme | 0 .../symlinks-multiple-roots/root/readme | 0 .../symlinks-prune-indexing/before-path | 0 .../symlinks-prune-indexing/c-file.txt | 0 .../symlinks-prune-indexing/c-path | 0 .../path/1/2/3/4/dont-index-me-twice.txt | 0 .../5/6/7/8/dont-index-me-twice-either.txt | 0 .../symlinks-prune-indexing/path/file.txt | 0 .../link_to_link_to_new_readme | 0 .../symlinks-simple/link_to_new_readme | 0 .../symlinks-simple/readme | 0 .../outside_root/link_target/place | 0 .../system_paths/target/dev/place | 0 .../module_1/module_1_1/place | 0 .../system_paths/target/home/place | 0 .../system_paths/target/link/a-symlink | 0 .../system_paths/target/proc/place | 0 .../system_paths/target/symlinks-to-dev | 0 .../target/symlinks-to-hierarchical-dev | 0 .../system_paths/target/sys/place | 0 .../fileresolver/unindexed_directory_test.go | 72 ++++----- syft/linux/identify_release_test.go | 70 ++++----- .../bad-redhat-release | 0 .../bad-system-release-cpe | 0 .../{test-fixtures => testdata}/centos-8 | 0 .../{test-fixtures => testdata}/debian-8 | 0 .../os/almalinux/etc/os-release | 0 .../os/alpine/etc/os-release | 0 .../os/amazon/etc/os-release | 0 .../os/arch/etc/os-release | 0 syft/linux/testdata/os/busybox/.gitignore | 2 + syft/linux/testdata/os/busybox/bin/.gitignore | 2 + .../os/busybox/bin/busybox | 0 .../os/centos/usr/lib/os-release | 0 .../os/centos5/etc/redhat-release | 0 .../os/centos6/etc/system-release-cpe | 0 .../os/custom/etc/os-release | 0 .../from-debian_version/etc/debian_version | 0 .../debian/from-debian_version/etc/os-release | 0 .../debian/from-os-release/usr/lib/os-release | 0 .../os/empty/etc/os-release | 0 .../os/fedora/usr/lib/os-release | 0 .../os/mariner/etc/os-release | 0 .../os/opensuse-leap/etc/os-release | 0 .../os/oraclelinux/etc/os-release | 0 .../os/photon/etc/os-release | 0 .../redhat/from-os-release/usr/lib/os-release | 0 .../from-redhat-release/etc/redhat-release | 0 .../os/rockylinux/etc/os-release | 0 .../os/sles/etc/os-release | 0 .../os/ubuntu/etc/os-release | 0 .../os/wolfi/etc/os-release | 0 .../missing-id/usr/lib/os-release | 0 .../missing-version/usr/lib/os-release | 0 .../unknown-id/usr/lib/os-release | 0 syft/linux/{test-fixtures => testdata}/rhel-8 | 0 .../{test-fixtures => testdata}/ubuntu-20.04 | 0 .../{test-fixtures => testdata}/unprintable | 0 syft/pkg/cataloger/.gitignore | 3 +- syft/pkg/cataloger/ai/cataloger_test.go | 2 +- .../glob-paths/models/model.gguf | 0 syft/pkg/cataloger/alpine/cataloger_test.go | 8 +- .../pkg/cataloger/alpine/parse_apk_db_test.go | 10 +- .../alpine/{test-fixtures => testdata}/base | 0 .../corrupt/lib/apk/db/installed | 0 .../empty-deps-and-provides | 0 .../extra-file-attributes | 0 .../glob-paths/lib/apk/db/installed | 0 .../multiple-1/lib/apk/db/installed | 0 .../multiple-2/lib/apk/db/installed | 0 .../alpine/{test-fixtures => testdata}/single | 0 .../very-large-entries | 0 syft/pkg/cataloger/arch/cataloger_test.go | 6 +- syft/pkg/cataloger/arch/parse_alpm_db_test.go | 8 +- .../arch/{test-fixtures => testdata}/files | 0 .../var/lib/pacman/local/base-1.0/desc | 0 .../var/lib/pacman/local/base-1.0/files | 0 .../var/lib/pacman/local/dive-0.10.0/desc | 0 .../var/lib/pacman/local/corrupt-0.2.1-3/desc | 0 .../var/lib/pacman/local/emacs-29.3-3/desc | 0 .../var/lib/pacman/local/fuzzy-1.2-3/desc | 0 .../var/lib/pacman/local/fuzzy-1.2-3/files | 0 .../var/lib/pacman/local/gmp-6.2.1-2/desc | 0 .../var/lib/pacman/local/gmp-6.2.1-2/files | 0 .../var/lib/pacman/local/gmp-6.2.1-2/mtree | Bin .../var/lib/pacman/local/madeup-20.30-4/desc | 0 .../pacman/local/tree-sitter-0.22.6-1/desc | 0 .../arch/{test-fixtures => testdata}/mtree | Bin syft/pkg/cataloger/binary/README.md | 6 +- .../binary/classifier_cataloger_test.go | 24 +-- .../binary/elf_package_cataloger_test.go | 6 +- .../manager/internal/cli/cli.go | 4 +- .../internal/cli/commands/add_snippet.go | 6 +- .../manager/internal/cli/commands/download.go | 4 +- .../manager/internal/cli/commands/list.go | 4 +- .../manager/internal/cli/commands/root.go | 2 +- .../internal/cli/commands/write_snippet.go | 4 +- .../manager/internal/config/application.go | 0 .../internal/config/application_test.go | 0 .../internal/config/binary_from_image.go | 0 .../internal/config/binary_from_image_test.go | 0 .../app-configs/bad-image-collision.yaml | 0 .../bad-implicit-name-collision.yaml | 0 .../bad-missing-image-platform.yaml | 0 .../app-configs/bad-missing-image-ref.yaml | 0 .../app-configs/bad-missing-image.yaml | 0 .../app-configs/bad-missing-paths.yaml | 0 .../app-configs/bad-missing-version.yaml | 0 .../testdata/app-configs/bad-no-name.yaml | 0 .../config/testdata/app-configs/valid-1.yaml | 0 .../config/testdata/app-configs/valid-2.yaml | 0 .../manager/internal/download_from_image.go | 4 +- .../internal/download_from_image_test.go | 2 +- .../manager/internal/list_entries.go | 2 +- .../manager/internal/list_entries_test.go | 2 +- .../manager/internal/snippet_metadata.go | 0 .../manager/internal/snippet_metadata_test.go | 0 .../manager/internal/testdata/.gitignore | 0 .../bin/busybox/1.3.6/linux-amd64/busybox | 0 .../bin/busybox/1.3.6/linux-arm64/busybox | 0 .../busybox/1.3.6/linux-amd64/busybox | 0 .../busybox/1.3.6/linux-arm64/busybox | 0 .../postgres/9.6.10/linux-amd64/postgres | 0 .../manager/internal/ui/action.go | 0 .../manager/internal/ui/ansi.go | 0 .../manager/internal/ui/binary_list.go | 0 .../manager/internal/ui/error.go | 0 .../manager/internal/ui/title.go | 0 .../manager/internal/utils.go | 0 .../manager/internal/utils_test.go | 0 .../manager/main.go | 4 +- .../manager/testutil/snippet_or_binary.go | 14 +- .../testutil/snippet_or_binary_test.go | 0 .../{test-fixtures => testdata}/.gitignore | 6 +- .../{test-fixtures => testdata}/Makefile | 10 +- .../capture-snippet.sh | 0 .../classifiers/negative/.gitignore | 0 .../classifiers/negative/busybox | 0 .../classifiers/negative/go | 0 .../classifiers/negative/libpython2.7.so | 0 .../classifiers/negative/python2.6 | 0 .../classifiers/negative/traefik/traefik | Bin .../arangodb/3.11.8/linux-amd64/arangosh | Bin .../arangodb/3.12.0-2/linux-amd64/arangosh | Bin .../snippets/bash/5.1.16/linux-amd64/bash | Bin .../snippets/busybox/1.36.1/linux-amd64/[ | Bin .../busybox/1.36.1/linux-amd64/busybox | 0 .../chrome/126.0.6478.182/linux-amd64/chrome | Bin .../chrome/127.0.6533.119/linux-amd64/chrome | Bin .../snippets/consul/1.15.2/linux-amd64/consul | 0 .../snippets/dart/2.12.4/linux-amd64/dart | Bin .../snippets/dart/3.0.0/linux-arm/dart | Bin .../snippets/dart/3.5.2/linux-amd64/dart | Bin .../dart/3.6.0-216.1.beta/linux-amd64/dart | Bin .../snippets/elixir/1.19.1/linux-amd64/elixir | 0 .../linux-amd64/lib/elixir/ebin/elixir.app | 0 .../snippets/envoy/1.11.0/linux-amd64/envoy | Bin .../snippets/envoy/1.14.3/linux-amd64/envoy | Bin .../snippets/envoy/1.18.6/linux-amd64/envoy | Bin .../snippets/envoy/1.20.7/linux-amd64/envoy | Bin .../snippets/envoy/1.22.11/linux-amd64/envoy | Bin .../snippets/envoy/1.28.7/linux-amd64/envoy | Bin .../snippets/envoy/1.34.5/linux-amd64/envoy | Bin .../snippets/envoy/1.36.4/linux-amd64/envoy | Bin .../snippets/envoy/1.6.0/linux-amd64/envoy | Bin .../erlang/25.3.2.6/linux-amd64/erlexec | Bin .../erlang/26.1.2/linux-arm64/beam.smp | Bin .../erlang/26.2.0.0/linux-amd64/erlexec | Bin .../26.2.4/linux-amd64/liberts_internal.a | Bin .../snippets/erlang/27.0/linux-amd64/beam.smp | 0 .../libavcodec-9aae324f.so.59.37.100 | Bin .../snippets/ffmpeg/6.1.1/linux-amd64/ffmpeg | Bin .../snippets/ffmpeg/7.1.1/darwin-arm64/ffmpeg | Bin .../fluent-bit/1.3.10/linux-arm/fluent-bit | Bin .../1.7.0-dev-3/linux-amd64/fluent-bit | Bin .../fluent-bit/2.2.1/linux-arm64/fluent-bit | Bin .../fluent-bit/3.0.2/linux-amd64/fluent-bit | Bin .../snippets/gcc/12.3.0/linux-amd64/gcc | Bin .../snippets/go-version-hint/1.15/any/VERSION | 0 .../snippets/go-version-hint/1.15/any/bin/go | 0 .../go-version-hint/1.15w/any/VERSION | 0 .../go-version-hint/1.15w/any/bin/go.exe | 0 .../snippets/go-version-hint/1.21/any/VERSION | 0 .../snippets/go-version-hint/1.21/any/go | 0 .../go-version-hint/1.25/any/VERSION.cache | 0 .../snippets/go-version-hint/1.25/any/bin/go | 0 .../go-version-hint/1.25w/any/VERSION | 0 .../snippets/go-version-hint/1.25w/any/go.exe | 0 .../snippets/go/1.21.3/linux-amd64/go | Bin .../grafana/10.3.12/linux-amd64/grafana | Bin .../grafana/10.4.19/linux-amd64/grafana | Bin .../11.0.0-preview/linux-amd64/grafana | Bin .../grafana/11.0.0/linux-amd64/grafana | Bin .../grafana/12.0.0/linux-amd64/grafana | Bin .../grafana/12.2.0-258092/linux-amd64/grafana | Bin .../grafana/12.3.1/linux-amd64/grafana | Bin .../12.3.2-security-01/linux-amd64/grafana | Bin .../12.4.0-22081664032/linux-amd64/grafana | Bin .../6.0.0-beta1/linux-amd64/grafana-server | Bin .../6.7.0-test/linux-amd64/grafana-server | Bin .../grafana/6.7.6/linux-amd64/grafana-server | Bin .../grafana/7.5.17/linux-amd64/grafana-server | Bin .../grafana/9.0.0/linux-amd64/grafana-server | Bin .../grafana/9.2.13/linux-amd64/grafana | Bin .../grafana/9.2.20/linux-amd64/grafana | Bin .../9.3.0-beta1/linux-amd64/grafana-server | Bin .../grafana/9.4.0-beta1/linux-amd64/grafana | Bin .../grafana/9.5.21/linux-amd64/grafana | Bin .../snippets/gzip/1.12/linux-amd64/gzip | Bin .../haproxy/1.5.14/linux-amd64/haproxy | Bin .../haproxy/1.8.22/linux-amd64/haproxy | Bin .../haproxy/2.0.0/linux-amd64/haproxy | Bin .../haproxy/2.7.3/linux-amd64/haproxy | Bin .../haproxy/3.1-dev0/linux-amd64/haproxy | Bin .../haskell-cabal/3.10.3.0/linux-amd64/cabal | Bin .../haskell-ghc/9.6.5/linux-amd64/ghc-9.6.5 | Bin .../snippets/helm/3.10.3/linux-amd64/helm | Bin .../snippets/helm/3.11.1/linux-amd64/helm | Bin .../snippets/httpd/2.4.54/linux-amd64/httpd | Bin .../1.1.17/linux-amd64/pilot-agent | Bin .../1.26.8/linux-amd64/pilot-agent | Bin .../1.8.0/linux-amd64/pilot-agent | Bin .../1.1.17/linux-amd64/pilot-discovery | Bin .../1.26.8/linux-amd64/pilot-discovery | Bin .../1.3.8/linux-amd64/pilot-discovery | Bin .../1.8.0/linux-amd64/pilot-discovery | Bin .../17.0.3+7-jvmci-22.1-b06/linux-amd64/java | Bin .../21.0.2+13-LTS/linux-amd64/jdb | Bin .../1.8.0_451-b10/linux-amd64/java | Bin .../1.8.0_451-b10/linux-amd64/jdb | Bin .../11.0.22/linux-arm64/java | Bin .../11.0.22/linux-amd64/java | Bin .../1.8.0_352-b08/linux-amd64/java | Bin .../java-jre-openjdk/11.0.17/linux-amd64/java | Bin .../1.8.0_451-b10/linux-amd64/java | Bin .../1.8.0_451-b10/linux-amd64/java | Bin .../java-jre-oracle/19.0.1/darwin/java | Bin .../java-jre-oracle/19.0.1/linux-amd64/java | Bin .../snippets/jq/1.7.1/linux-amd64/jq | Bin .../lighttpd/1.4.76/linux-amd64/lighttpd | Bin .../mariadb/10.6.15/linux-amd64/mariadb | Bin .../memcached/1.6.18/linux-amd64/memcached | Bin .../mongodb/4.4.30/linux-amd64/mongod | Bin .../mongodb/5.0.32/linux-amd64/mongod | Bin .../mongodb/6.0.27/linux-amd64/mongod | Bin .../mongodb/7.0.28/linux-amd64/mongod | Bin .../mongodb/8.0.17/linux-amd64/mongod | Bin .../snippets/mysql/5.6.51/linux-amd64/mysql | Bin .../snippets/mysql/8.0.34/linux-amd64/mysql | Bin .../snippets/mysql/8.0.37/linux-amd64/mysql | Bin .../1.21.4.3/linux-amd64/nginx | Bin .../snippets/nginx/1.25.1/linux-amd64/nginx | Bin .../snippets/node/0.10.48/linux-amd64/node | Bin .../snippets/node/0.12.18/linux-amd64/node | Bin .../snippets/node/19.2.0/linux-amd64/node | Bin .../snippets/node/4.9.1/linux-amd64/node | Bin .../openssl/1.1.1w/linux-arm64/openssl | Bin .../openssl/1.1.1zb/linux-arm64/openssl | Bin .../openssl/3.1.4/linux-amd64/openssl | Bin .../percona-server/8.0.35/linux-amd64/mysql | Bin .../8.0.35/linux-amd64/xtrabackup | Bin .../8.0.34/linux-amd64/mysql | Bin .../snippets/perl/5.12.5/linux-amd64/perl | Bin .../snippets/perl/5.20.0/linux-amd64/perl | Bin .../snippets/perl/5.37.8/linux-amd64/perl | Bin .../php-apache/8.2.1/linux-amd64/libphp.so | 0 .../postgres/15.1/linux-amd64/postgres | Bin .../postgres/15beta4/linux-amd64/postgres | Bin .../postgres/9.5alpha1/linux-amd64/postgres | 0 .../postgres/9.6.24/linux-amd64/postgres | Bin .../proftpd/1.3.8b/linux-amd64/proftpd | Bin .../7.3.14/linux-amd64/libpypy3.9-c.so | Bin .../3.8.16/linux-amd64/dir/python3.8 | Bin .../3.8.16/linux-amd64/libpython3.8.so | Bin .../3.8.16/linux-amd64/patchlevel.h | 0 .../3.8.16/linux-amd64/python3.8 | Bin .../3.7.4/linux-amd64/libpython3.7m.so.1.0 | Bin .../3.5.3/linux-amd64/python3.5 | Bin .../python/3.6.3/linux-amd64/python3.6 | Bin .../qt/4.8.6/linux-amd64/libQtCore.so.4.8.6 | Bin .../5.15.2/linux-amd64/libQt5Core.so.5.15.2 | Bin .../qt/6.5.0/linux-amd64/libQt6Core.so.6.5.0 | Bin .../2.8.23/linux-amd64/redis-server | Bin .../4.0.11/linux-amd64/redis-server | Bin .../5.0.0/linux-amd64/redis-server | Bin .../6.0.16/linux-amd64/redis-server | Bin .../7.0.0/linux-amd64/redis-server | Bin .../7.0.14/linux-amd64/redis-server | Bin .../7.2.3/linux-amd64/redis-server | Bin .../7.2.3/linux-arm64/redis-server | Bin .../linux-unknown-454d5f333836/redis-server | Bin .../snippets/ruby/1.9.3p551/linux-amd64/ruby | Bin .../linux-amd64/libstd-86aefecbddda356d.so | Bin .../darwin/libstd-f6f9eec1635e636a.dylib | Bin .../linux-amd64/libstd-6f77337c1826707d.so | Bin .../darwin/libstd-16f2b65e77054c42.dylib | Bin .../linux-amd64/libstd-c6192dd4c4d410ac.so | Bin .../sqlcipher/4.5.5/linux-amd64/sqlcipher | Bin .../snippets/swipl/9.3.8/linux-amd64/swipl | Bin .../traefik/1.7.34/linux-amd64/traefik | Bin .../traefik/2.10.7/linux-amd64/traefik | Bin .../traefik/2.9.6/linux-amd64/traefik | Bin .../traefik/3.0.4/linux-riscv64/traefik | Bin .../traefik/3.6.5/linux-amd64/traefik | Bin .../util-linux/2.37.4/linux-amd64/getopt | Bin .../9.0.0/linux-amd64/valkey-server | Bin .../snippets/vault/1.19.4/linux-arm64/vault | 0 .../snippets/vault/1.20.2/linux-amd64/vault | 0 .../snippets/wp/2.9.0/linux-amd64/wp | 0 .../snippets/xz/5.6.2/linux-amd64/xz | Bin .../snippets/zstd/1.5.6/linux-amd64/zstd | Bin .../{test-fixtures => testdata}/config.yaml | 0 .../custom/extra/foo | 0 .../custom/go-1.14/go | Bin .../elf-testdata}/Dockerfile | 0 .../elf-testdata}/README.md | 2 +- .../elfbinwithcorrupt/elfsrc/hello_world.cpp | 0 .../elfbinwithcorrupt/elfsrc/hello_world.h | 0 .../elfbinwithcorrupt/elfsrc/makefile | 0 .../elfbinwithcorrupt/elfsrc/testbin.cpp | 0 .../elf-testdata}/elfbinwithcorrupt/makefile | 0 .../elfsrc/hello_world.cpp | 0 .../elfbinwithnestedlib/elfsrc/hello_world.h | 0 .../elfbinwithnestedlib/elfsrc/makefile | 0 .../elfbinwithnestedlib/elfsrc/testbin.cpp | 0 .../elfbinwithnestedlib/makefile | 0 .../elfsrc1/hello_world.cpp | 0 .../elfbinwithsisterlib/elfsrc1/hello_world.h | 0 .../elfbinwithsisterlib/elfsrc1/makefile | 0 .../elfbinwithsisterlib/elfsrc1/testbin.cpp | 0 .../elfsrc2/hello_world2.cpp | 0 .../elfsrc2/hello_world2.h | 0 .../elfbinwithsisterlib/elfsrc2/makefile | 0 .../elfbinwithsisterlib/elfsrc2/testbin2.cpp | 0 .../elfbinwithsisterlib/makefile | 0 .../image-busybox/Dockerfile | 0 .../image-dotnet-app/Dockerfile | 0 .../image-fedora-32bit/Dockerfile | 0 .../image-fedora-64bit/Dockerfile | 0 .../image-java-binary/Dockerfile | 0 .../image-java-ibm-8/Dockerfile | 0 .../image-java-ibm-jre-8/Dockerfile | 0 .../image-java-ibm-sdk-8/Dockerfile | 0 .../image-java-zulu-21/Dockerfile | 0 .../image-java-zulu-8/Dockerfile | 0 .../image-jruby/Dockerfile | 0 .../Dockerfile | 0 syft/pkg/cataloger/bitnami/cataloger_test.go | 20 ++- .../opt/bitnami/.bitnami_components.json | 0 .../opt/bitnami/.bitnami_components.json | 0 .../opt/bitnami/redis/.spdx-redis.spdx | 0 .../bitnami/postgresql/.spdx-postgresql.spdx | 0 .../json/opt/bitnami/postgresql/readme.txt | 0 .../.spdx-render-template.spdx | 0 .../no-rel/opt/bitnami/redis/.gitignore | 2 + .../no-rel/opt/bitnami/redis/.spdx-redis.spdx | 0 .../no-rel/opt/bitnami/redis/bin/.gitignore | 2 + .../no-rel/opt/bitnami/redis/bin/redis-server | 0 .../opt/bitnami/redis/.spdx-apache.spdx | 0 syft/pkg/cataloger/conda/cataloger_test.go | 4 +- .../package-1.2.3-pyhd8ed1ab_0.json | 0 .../jupyterlab-4.4.3-pyhd8ed1ab_0.json | 0 .../conda-meta/zlib-1.2.11-h90dfc92_1014.json | 0 syft/pkg/cataloger/cpp/cataloger_test.go | 4 +- .../pkg/cataloger/cpp/parse_conanfile_test.go | 2 +- .../pkg/cataloger/cpp/parse_conaninfo_test.go | 2 +- .../pkg/cataloger/cpp/parse_conanlock_test.go | 6 +- .../cpp/{test-fixtures => testdata}/README.md | 0 .../{test-fixtures => testdata}/conan.lock | 0 .../{test-fixtures => testdata}/conanfile.txt | 0 .../conaninfo.txt | 0 .../conanlock-v2/conan.lock | 0 .../corrupt/conan.lock | 0 .../glob-paths/somewhere/src/conan.lock | 0 .../glob-paths/somewhere/src/conanfile.txt | 0 .../glob-paths/somewhere/src/conaninfo.txt | 0 syft/pkg/cataloger/dart/cataloger_test.go | 4 +- .../cataloger/dart/parse_pubspec_lock_test.go | 22 +-- syft/pkg/cataloger/dart/parse_pubspec_test.go | 8 +- .../corrupt/pubspec.lock | 0 .../glob-paths/lock/src/pubspec.lock | 0 .../glob-paths/spec/pubspec.yaml | 0 .../glob-paths/spec/pubspec.yml | 0 .../invalid-sdk/pubspec.lock | 0 .../missing-sdk/pubspec.lock | 0 .../pubspec_locks/pubspec.lock | 0 .../pubspecs/appainter.pubspec.yaml | 0 .../pubspecs/macros.pubspec.yaml | 0 syft/pkg/cataloger/debian/cataloger_test.go | 8 +- .../cataloger/debian/parse_copyright_test.go | 16 +- .../cataloger/debian/parse_dpkg_db_test.go | 10 +- .../debian/parse_dpkg_info_files_test.go | 4 +- .../copyright/cuda | 0 .../copyright/dev-kit | 0 .../copyright/libaudit-common | 0 .../copyright/libc6 | 0 .../copyright/liblzma5 | 0 .../copyright/microsoft | 0 .../copyright/python | 0 .../copyright/trilicense | 0 .../lib/dpkg/info/libpam-runtime.conffiles | 0 .../usr/lib/dpkg/info/libpam-runtime.md5sums | 0 .../usr/lib/dpkg/info/libpam-runtime.preinst | 0 .../glob-paths/usr/lib/dpkg/status | 0 .../glob-paths/usr/lib/dpkg/status.d/pkg-1.0 | 0 .../usr/lib/opkg/info/pkg-1.0.control | 0 .../glob-paths/usr/lib/opkg/status | 0 .../usr/share/doc/libpam-runtime/copyright | 0 .../glob-paths/var/lib/dpkg/status | 0 .../glob-paths/var/lib/dpkg/status.d/pkg-1.0 | 0 .../image-distroless-deb/Dockerfile | 0 .../usr/share/doc/libsqlite3-0/copyright | 0 .../var/lib/dpkg/status.d/libsqlite3-0 | 0 .../lib/dpkg/status.d/libsqlite3-0.md5sums | 0 .../lib/dpkg/status.d/libsqlite3-0.preinst | 0 .../image-dpkg/Dockerfile | 0 .../image-dpkg/etc/os-release | 0 .../usr/share/doc/libpam-runtime/copyright | 0 .../lib/dpkg/info/libpam-runtime.conffiles | 0 .../var/lib/dpkg/info/libpam-runtime.md5sums | 0 .../var/lib/dpkg/info/libpam-runtime.preinst | 0 .../image-dpkg/var/lib/dpkg/status | 0 .../image-single-dpkg/Dockerfile | 0 .../info/util-linux.conffiles | 0 .../info/zlib1g.md5sums | 0 .../lib/dpkg/status.d/coreutils-relationships | 0 .../var/lib/dpkg/status.d/corrupt | 0 .../var/lib/dpkg/status.d/deinstall | 0 .../var/lib/dpkg/status.d/doc-examples | 0 .../var/lib/dpkg/status.d/empty | 0 .../var/lib/dpkg/status.d/installed-size-4KB | 0 .../var/lib/dpkg/status.d/libpam-runtime | 0 .../var/lib/dpkg/status.d/multiple | 0 .../var/lib/dpkg/status.d/single | 0 syft/pkg/cataloger/dotnet/cataloger_test.go | 12 +- .../dotnet/parse_packages_lock_test.go | 4 +- .../{test-fixtures => testdata}/.gitignore | 0 .../{test-fixtures => testdata}/Makefile | 0 .../dir-example-1/TestLibrary.deps.json | 0 .../glob-paths/src/packages.lock.json | 0 .../glob-paths/src/something.deps.json | 0 .../glob-paths/src/something.dll | 0 .../glob-paths/src/something.exe | 0 .../image-net2-app/.gitignore | 0 .../image-net2-app/Dockerfile | 0 .../image-net2-app/src/Program.cs | 0 .../image-net2-app/src/helloworld.csproj | 0 .../image-net6-asp-libman/.dockerignore | 0 .../image-net6-asp-libman/.gitignore | 0 .../image-net6-asp-libman/Dockerfile | 0 .../image-net6-asp-libman/src/.gitignore | 0 .../src/LibManSample.csproj | 0 .../image-net6-asp-libman/src/Program.cs | 0 .../image-net6-asp-libman/src/Startup.cs | 0 .../image-net6-asp-libman/src/libman.json | 0 .../src/vendor/lodash.js | 0 .../src/vendor/lodash.min.js | 0 .../image-net8-app-no-depjson/.gitignore | 0 .../image-net8-app-no-depjson/Dockerfile | 0 .../image-net8-app-no-depjson/src/Program.cs | 0 .../src/dotnetapp.csproj | 0 .../src/packages.lock.json | 0 .../image-net8-app-self-contained/.gitignore | 0 .../image-net8-app-self-contained/Dockerfile | 0 .../src/Program.cs | 0 .../src/dotnetapp.csproj | 0 .../src/packages.lock.json | 0 .../image-net8-app-single-file/.gitignore | 0 .../image-net8-app-single-file/Dockerfile | 0 .../image-net8-app-single-file/src/Program.cs | 0 .../src/dotnetapp.csproj | 0 .../src/packages.lock.json | 0 .../.gitignore | 0 .../Dockerfile | 0 .../src/Program.cs | 0 .../src/dotnetapp.csproj | 0 .../src/packages.lock.json | 0 .../image-net8-app-with-runtime/.gitignore | 0 .../image-net8-app-with-runtime/Dockerfile | 0 .../src/Program.cs | 0 .../src/dotnetapp.csproj | 0 .../src/packages.lock.json | 0 .../image-net8-app/.gitignore | 0 .../image-net8-app/Dockerfile | 0 .../image-net8-app/src/Program.cs | 0 .../image-net8-app/src/dotnetapp.csproj | 0 .../image-net8-app/src/packages.lock.json | 0 .../image-net8-compile-target/.gitignore | 0 .../image-net8-compile-target/Dockerfile | 0 .../image-net8-compile-target/src/Program.cs | 0 .../src/helloworld.csproj | 0 .../image-net8-ilrepack/.gitignore | 0 .../image-net8-ilrepack/Dockerfile | 0 .../image-net8-ilrepack/src/.gitignore | 0 .../image-net8-ilrepack/src/Program.cs | 0 .../image-net8-ilrepack/src/dotnetapp.csproj | 0 .../image-net8-privateassets/.gitignore | 0 .../image-net8-privateassets/Dockerfile | 0 .../image-net8-privateassets/src/.gitignore | 0 .../image-net8-privateassets/src/Program.cs | 0 .../src/dotnetapp.csproj | 0 .../packages.lock.json | 0 syft/pkg/cataloger/elixir/cataloger_test.go | 2 +- .../cataloger/elixir/parse_mix_lock_test.go | 4 +- .../glob-paths/src/mix.lock | 0 .../{test-fixtures => testdata}/mix.lock | 0 syft/pkg/cataloger/erlang/cataloger_test.go | 4 +- .../cataloger/erlang/parse_otp_app_test.go | 4 +- .../cataloger/erlang/parse_rebar_lock_test.go | 6 +- .../corrupt/rabbitmq.app | 0 .../corrupt/rebar.lock | 0 .../glob-paths/src/rabbitmq.app | 0 .../glob-paths/src/rebar.lock | 0 .../{test-fixtures => testdata}/rabbitmq.app | 0 .../{test-fixtures => testdata}/rebar-2.lock | 0 .../{test-fixtures => testdata}/rebar.lock | 0 syft/pkg/cataloger/generic/cataloger_test.go | 20 +-- .../generic/test-fixtures/a-path.txt | 1 - .../generic/test-fixtures/another-path.txt | 1 - .../generic/test-fixtures/last/path.txt | 1 - .../pkg/cataloger/generic/testdata/a-path.txt | 1 + .../generic/testdata/another-path.txt | 1 + .../{test-fixtures => testdata}/empty.txt | 0 .../cataloger/generic/testdata/last/path.txt | 1 + syft/pkg/cataloger/gentoo/cataloger_test.go | 6 +- syft/pkg/cataloger/gentoo/license_test.go | 8 +- .../glob-paths/var/db/pkg/x/y/CONTENTS | 0 .../etc/portage/license_groups | 0 .../pkg/app-containers/skopeo-1.5.1/CONTENTS | 0 .../pkg/app-containers/skopeo-1.5.1/LICENSE | 0 .../db/pkg/app-containers/skopeo-1.5.1/SIZE | 0 .../pkg/app-containers/skopeo-1.5.1/CONTENTS | 0 .../pkg/app-containers/skopeo-1.5.1/LICENSE | 0 .../db/pkg/app-containers/skopeo-1.5.1/SIZE | 0 .../license-groups/cycle | 0 .../license-groups/example1 | 0 .../license-groups/missing | 0 .../license-groups/self | 0 .../cataloger/githubactions/cataloger_test.go | 4 +- .../parse_composite_action_test.go | 4 +- .../githubactions/parse_workflow_test.go | 10 +- .../call-shared-workflow.yaml | 0 .../composite-action.yaml | 0 .../corrupt/composite-action.yaml | 0 .../corrupt/workflow-multi-job.yaml | 0 .../.github/actions/bootstrap/action.yaml | 0 .../.github/actions/unbootstrap/action.yml | 0 .../glob/.github/workflows/release.yml | 0 .../glob/.github/workflows/validations.yaml | 0 .../workflow-multi-job.yaml | 0 .../workflow-with-version-comments.yaml | 0 .../cataloger/golang/billy_adapter_test.go | 4 +- syft/pkg/cataloger/golang/cataloger_test.go | 4 +- .../golang/internal/gotestdata/README.md | 32 ++++ .../gotestdata}/go-source/cmd/bin1/main.go | 0 .../gotestdata}/go-source/cmd/bin2/main.go | 0 .../gotestdata}/go-source/go.mod | 0 .../gotestdata}/go-source/go.sum | 0 .../gotestdata}/go-source/pk1/pk1.go | 0 .../gotestdata}/go-source/pk1/pk1_test.go | 0 .../gotestdata}/go-source/pk2/pk2.go | 0 .../gotestdata}/go-source/pk3/pk3.go | 0 syft/pkg/cataloger/golang/licenses_test.go | 16 +- .../cataloger/golang/parse_go_binary_test.go | 10 +- syft/pkg/cataloger/golang/parse_go_mod.go | 4 + .../pkg/cataloger/golang/parse_go_mod_test.go | 28 ++-- syft/pkg/cataloger/golang/subfs_test.go | 2 +- .../{test-fixtures => testdata}/Makefile | 0 .../archs/.gitignore | 0 .../archs/Makefile | 0 .../archs/src/build.sh | 0 .../archs/src/go.mod | 0 .../archs/src/main.go | 0 .../corrupt/go.mod | 0 .../corrupt/go.sum | 0 .../glob-paths/partial-binary | 0 .../glob-paths/src/go.mod | 0 .../go-mod-fixtures/many-packages/go.mod | 0 .../go-mod-fixtures/one-package/go.mod | 0 .../go-mod-fixtures/one-package/go.sum | 0 .../go-mod-fixtures/relative-replace/go.mod | 0 .../go-sum-hashes/go.mod | 0 .../go-sum-hashes/go.sum | 0 .../image-not-a-module/.gitignore | 0 .../image-not-a-module/Dockerfile | 0 .../image-not-a-module/go.mod | 0 .../image-not-a-module/go.sum | 0 .../image-not-a-module/main.go | 0 .../image-small-upx/.gitignore | 0 .../image-small-upx/Dockerfile | 0 .../image-small-upx/go.mod | 0 .../image-small-upx/go.sum | 0 .../image-small-upx/main.go | 0 .../image-small/.gitignore | 0 .../image-small/Dockerfile | 0 .../image-small/go.mod | 0 .../image-small/go.sum | 0 .../image-small/main.go | 0 .../!cap!o!r!g/!cap!project/LICENSE.txt | 0 .../github.com/someorg/somename/LICENSE | 0 .../someorg/strangelicense/LiCeNsE.tXt | 0 .../!cap!project@v4.111.5/LICENSE.txt | 0 .../someorg/somename@v0.3.2/LICENSE | 0 .../someorg/strangelicense@v1.2.3/LiCeNsE.tXt | 0 .../{test-fixtures => testdata}/repo/LICENSE | 0 .../github.com/someorg/somepkg@version/a-file | 0 .../someorg/somepkg@version/subdir/subfile | 0 syft/pkg/cataloger/haskell/cataloger_test.go | 2 +- .../haskell/parse_cabal_freeze_test.go | 2 +- .../haskell/parse_stack_lock_test.go | 4 +- .../haskell/parse_stack_yaml_test.go | 4 +- .../cabal.project.freeze | 0 .../corrupt/stack.yaml | 0 .../corrupt/stack.yaml.lock | 0 .../glob-paths/src/cabal.project.freeze | 0 .../glob-paths/src/stack.yaml | 0 .../glob-paths/src/stack.yaml.lock | 0 .../{test-fixtures => testdata}/stack.yaml | 0 .../stack.yaml.lock | 0 syft/pkg/cataloger/homebrew/cataloger_test.go | 4 +- .../homebrew/parse_homebrew_formula_test.go | 8 +- .../formulas/crazy/1.0.0/.brew/crazy.rb | 0 .../formulas/syft/1.23.1/.brew/syft.rb | 0 .../homebrew/Cellar/foo/1.2.3/.brew/foo.rb | 0 .../Taps/testorg/sometap/Formula/bar.rb | 0 .../binutils/branching_matcher_test.go | 2 +- .../internal/binutils/classifier_test.go | 10 +- .../subdir/some-binary | 0 .../version-parts.txt | Bin .../{test-fixtures => testdata}/version.txt | 0 syft/pkg/cataloger/internal/pe/pe_test.go | 2 +- .../internal/pe/test-fixtures/image-net8-app | 1 - .../test-fixtures/image-net8-app-single-file | 1 - .../pe/{test-fixtures => testdata}/Makefile | 0 .../image-dotnet31-single-file/Dockerfile | 0 .../image-dotnet31-single-file/src/Program.cs | 0 .../src/hello.csproj | 0 .../image-dotnet5-single-file/Dockerfile | 0 .../image-dotnet5-single-file/src/Program.cs | 0 .../src/hello.csproj | 0 .../image-dotnet6-single-file/Dockerfile | 0 .../image-dotnet6-single-file/src/Program.cs | 0 .../src/hello.csproj | 0 .../internal/pe/testdata/image-net8-app | 1 + .../pe/testdata/image-net8-app-single-file | 1 + .../net8-app-single-file.deps.json | 0 .../internal/pkgtest/metadata_tracker.go | 4 +- .../internal/pkgtest/test_generic_parser.go | 2 + .../pkg/cataloger/java/archive_parser_test.go | 70 ++++----- syft/pkg/cataloger/java/cataloger_test.go | 12 +- .../graalvm_native_image_cataloger_test.go | 4 +- .../java/internal/maven/config_test.go | 8 +- .../java/internal/maven/pom_parser_test.go | 4 +- .../java/internal/maven/resolver_test.go | 6 +- .../declared-iso-8859-encoded-pom.xml.base64 | 0 .../.m2/settings.xml | 0 .../local/child-1/pom.xml | 0 .../local/child-2/pom.xml | 0 .../local/child-3/pom.xml | 0 .../local/circular-1/pom.xml | 0 .../local/circular-2/pom.xml | 0 .../local/contains-child-1/pom.xml | 0 .../local/parent-1/pom.xml | 0 .../local/parent-2/pom.xml | 0 .../local/parent-3/pom.xml | 0 .../org/child-one/1.3.6/child-one-1.3.6.pom | 0 .../org/child-two/2.1.90/child-two-2.1.90.pom | 0 .../my/org/circular/1.2.3/circular-1.2.3.pom | 0 .../parent-one/3.11.0/parent-one-3.11.0.pom | 0 .../parent-two/13.7.8/parent-two-13.7.8.pom | 0 .../parent/7.11.2/parent-7.11.2.pom | 0 .../commons-parent/54/commons-parent-54.pom | 0 .../junit/junit-bom/5.9.0/junit-bom-5.9.0.pom | 0 .../junit/junit-bom/5.9.1/junit-bom-5.9.1.pom | 0 .../3.4.6/opensaml-parent-3.4.6.pom | 0 ...undeclared-iso-8859-encoded-pom.xml.base64 | 0 syft/pkg/cataloger/java/package_url_test.go | 8 +- .../java/parse_gradle_lockfile_test.go | 2 +- .../java/parse_java_manifest_test.go | 14 +- .../java/parse_pom_properties_test.go | 10 +- syft/pkg/cataloger/java/parse_pom_xml_test.go | 28 ++-- .../java/tar_wrapped_archive_parser_test.go | 8 +- .../java/{test-fixtures => testdata}/Makefile | 0 .../java/testdata/corrupt/.gitignore | 2 + .../corrupt/example.jar | 0 .../corrupt/example.tar | 0 .../corrupt/pom.xml | 0 .../glob-paths/archives/.gitignore | 0 .../glob-paths/archives/example.tar | 0 .../glob-paths/archives/example.tar.br | 0 .../glob-paths/archives/example.tar.bz | 0 .../glob-paths/archives/example.tar.bz2 | 0 .../glob-paths/archives/example.tar.gz | 0 .../glob-paths/archives/example.tar.lz4 | 0 .../glob-paths/archives/example.tar.sz | 0 .../glob-paths/archives/example.tar.xz | 0 .../glob-paths/archives/example.tar.zst | 0 .../glob-paths/archives/example.tar.zstd | 0 .../glob-paths/archives/example.tbr | 0 .../glob-paths/archives/example.tbz | 0 .../glob-paths/archives/example.tbz2 | 0 .../glob-paths/archives/example.tgz | 0 .../glob-paths/archives/example.tlz4 | 0 .../glob-paths/archives/example.tsz | 0 .../glob-paths/archives/example.txz | 0 .../glob-paths/archives/example.tzst | 0 .../glob-paths/archives/example.tzstd | 0 .../glob-paths/archives/example.zip | 0 .../glob-paths/java-archives/.gitignore | 0 .../glob-paths/java-archives/example.ear | 0 .../glob-paths/java-archives/example.far | 0 .../glob-paths/java-archives/example.hpi | 0 .../glob-paths/java-archives/example.jar | 0 .../glob-paths/java-archives/example.jpi | 0 .../glob-paths/java-archives/example.kar | 0 .../glob-paths/java-archives/example.lpkg | 0 .../glob-paths/java-archives/example.nar | 0 .../glob-paths/java-archives/example.par | 0 .../glob-paths/java-archives/example.rar | 0 .../glob-paths/java-archives/example.sar | 0 .../glob-paths/java-archives/example.war | 0 .../glob-paths/src/pom.xml | 0 .../graalvm-sbom/micronaut.json | 0 .../gradle/.gitignore | 0 .../gradle/build.gradle | 0 .../gradle/gradle.lockfile | 0 .../jar-metadata/.gitignore | 0 .../jar-metadata/Makefile | 0 .../jar-metadata/README.md | 0 .../META-INF/MANIFEST.MF | 0 .../api-all/pom.properties | 0 .../org.apache.directory.api/api-all/pom.xml | 0 .../api-asn1-api/pom.properties | 0 .../api-asn1-api/pom.xml | 0 .../META-INF/MANIFEST.MF | 0 .../jackson-core/pom.xml | 0 .../commons-lang3-3.12.0/META-INF/MANIFEST.MF | 0 .../maven/org.apache.commons-lang3/pom.xml | 0 .../jackson-core-2.15.2/META-INF/MANIFEST.MF | 0 .../jackson-core/pom.xml | 0 .../gradle/2.11/META-INF/MANIFEST.MF | 0 .../micronaut-aop-4.9.11/META-INF/MANIFEST.MF | 0 .../maven/io.micronaut/micronaut-aop/pom.xml | 0 .../META-INF/MANIFEST.MF | 0 .../multiple-matching-1/pom.properties | 0 .../org.multiple/multiple-matching-1/pom.xml | 0 .../multiple-matching-2/pom.properties | 0 .../org.multiple/multiple-matching-2/pom.xml | 0 .../multiple-matching-3/pom.properties | 0 .../org.multiple/multiple-matching-3/pom.xml | 0 .../opensaml-core-3.4.6/META-INF/INDEX.LIST | 0 .../opensaml-core-3.4.6/META-INF/MANIFEST.MF | 0 .../org.opensaml/opensaml-core/pom.properties | 0 .../maven/org.opensaml/opensaml-core/pom.xml | 0 .../org.multiple-thename/META-INF/MANIFEST.MF | 0 .../maven/com.multiple/thename/pom.properties | 0 .../maven/com.multiple/thename/pom.xml | 0 .../maven/org.multiple/thename/pom.properties | 0 .../maven/org.multiple/thename/pom.xml | 0 .../META-INF/MANIFEST.MF | 0 .../java-builds/.gitignore | 0 .../java-builds/Makefile | 0 .../build-example-java-app-gradle.sh | 0 .../build-example-java-app-maven.sh | 0 .../build-example-java-app-native-image.sh | 0 .../build-example-jenkins-plugin.sh | 0 .../java-builds/build-example-macho-binary.sh | 0 .../build-example-sb-app-nestedjar.sh | 0 .../java-builds/example-java-app/.gitignore | 0 .../java-builds/example-java-app/build.gradle | 0 .../example-java-app/gradle.lockfile | 0 .../java-builds/example-java-app/pom.xml | 0 .../src/main/java/hello/Greeter.java | 0 .../src/main/java/hello/HelloWorld.java | 0 .../example-jenkins-plugin/pom.xml | 0 .../plugins/sample/HelloWorldBuilder.java | 0 .../src/main/resources/index.jelly | 0 .../sample/HelloWorldBuilder/config.jelly | 0 .../HelloWorldBuilder/config.properties | 0 .../HelloWorldBuilder/config_fr.properties | 0 .../sample/HelloWorldBuilder/help-name.html | 0 .../HelloWorldBuilder/help-name_fr.html | 0 .../HelloWorldBuilder/help-useFrench.html | 0 .../HelloWorldBuilder/help-useFrench_fr.html | 0 .../plugins/sample/Messages.properties | 0 .../plugins/sample/Messages_fr.properties | 0 .../java-builds/example-sb-app/.gitignore | 0 .../java-builds/example-sb-app/pom.xml | 0 .../com/example/springboot/Application.java | 0 .../example/springboot/HelloController.java | 0 .../example/springboot/HelloControllerIT.java | 0 .../springboot/HelloControllerTest.java | 0 .../oracle-jdk-se-8/usr/lib/jvm/.gitignore | 0 .../usr/lib/jvm/jdk-1.8-oracle-x64/bin/javac | 0 .../usr/lib/jvm/jdk-1.8-oracle-x64/release | 0 .../valid-post-jep223/jvm/openjdk/release | 0 .../jvm/openjdk/sibling/child/file1.txt | 0 .../manifest/continuation | 0 .../manifest/extra-empty-lines | 0 .../manifest/extra-info | 0 .../manifest/leading-space | 0 .../manifest/small | 0 .../manifest/standard-info | 0 .../manifest/version-with-date | 0 ...colon-delimited-with-equals.pom.properties | 0 .../pom/colon-delimited.pom.properties | 0 .../pom/commons-codec.pom.xml | 0 .../pom/commons-text-1.10.0/pom.xml | 0 ...quals-delimited-with-colons.pom.properties | 0 .../pom/example-java-app-maven/pom.xml | 0 .../pom/extra.pom.properties | 0 .../pom/neo4j-license-maven-plugin.pom.xml | 0 .../pom/small.pom.properties | 0 .../pom/transitive-top-level/pom.xml | 0 .../java/zip_wrapped_archive_parser_test.go | 2 +- .../cataloger/javascript/cataloger_test.go | 6 +- .../javascript/parse_package_json_test.go | 62 ++++---- .../javascript/parse_package_lock_test.go | 14 +- .../javascript/parse_pnpm_lock_test.go | 16 +- .../javascript/parse_yarn_lock_test.go | 20 +-- .../corrupt/package-lock.json | 0 .../corrupt/package.json | 0 .../corrupt/pnpm-lock.yaml | 0 .../glob-paths/src/package-lock.json | 0 .../glob-paths/src/package.json | 0 .../glob-paths/src/pnpm-lock.yaml | 0 .../glob-paths/src/yarn.lock | 0 .../pkg-json/package-all-author-fields.json | 0 .../pkg-json/package-author-non-standard.json | 0 .../pkg-json/package-authors-array.json | 0 .../pkg-json/package-authors-objects.json | 0 .../package-both-author-and-authors.json | 0 .../pkg-json/package-contributors.json | 0 .../pkg-json/package-license-object.json | 0 .../pkg-json/package-license-objects.json | 0 .../pkg-json/package-maintainers.json | 0 .../pkg-json/package-malformed-license.json | 0 .../pkg-json/package-nested-author.json | 0 .../pkg-json/package-no-license.json | 0 .../pkg-json/package-partial.json | 0 .../pkg-json/package-private.json | 0 .../pkg-json/package-repo-string.json | 0 .../pkg-json/package.json | 0 .../pkg-lock/alias-package-lock-1.json | 0 .../pkg-lock/alias-package-lock-2.json | 0 .../pkg-lock/array-license-package-lock.json | 0 .../node_modules/@actions/core/package.json | 0 .../pkg-lock/node_modules/cowsay/package.json | 0 .../pkg-lock/package-lock-2.json | 0 .../pkg-lock/package-lock-3.json | 0 .../pkg-lock/package-lock.json | 0 .../pnpm-remote/pnpm-lock.yaml | 0 .../pnpm-remote/registry_response.json | 0 .../pnpm-v6/pnpm-lock.yaml | 0 .../pnpm-v9-snapshots/pnpm-lock.yaml | 0 .../pnpm-v9/pnpm-lock.yaml | 0 .../pnpm/pnpm-lock.yaml | 0 .../yarn-berry-dev-deps/package.json | 0 .../yarn-berry-dev-deps/yarn.lock | 0 .../yarn-berry/yarn.lock | 0 .../yarn-dev-deps/package.json | 0 .../yarn-dev-deps/yarn.lock | 0 .../yarn-dups/yarn.lock | 0 .../yarn-remote/registry_response.json | 0 .../yarn-remote/yarn.lock | 0 .../yarn-v1-deps/yarn.lock | 0 .../yarn/yarn.lock | 0 .../{test-fixtures => testdata}/Makefile | 0 .../image-kernel-and-modules/Dockerfile | 0 syft/pkg/cataloger/lua/cataloger_test.go | 2 +- syft/pkg/cataloger/lua/parse_rockspec_test.go | 18 +-- .../corrupt/bad-1.23.0-0.rockspec | 0 .../glob-paths/lua/package.rockspec | 0 .../rockspec/kong-3.7.0-0.rockspec | 0 .../rockspec/kong-pgmoon-1.16.2-1.rockspec | 0 .../rockspec/lpeg-1.0.2-1.rockspec | 0 .../rockspec/luasyslog-2.0.1-1.rockspec | 0 syft/pkg/cataloger/nix/cataloger_test.go | 2 +- .../pkg/cataloger/nix/store_cataloger_test.go | 2 +- .../fixture-1/.gitignore | 0 ...a13jg89g9jws145c0k26k2x-glibc-2.34-210.drv | 0 .../lib/glibc.so | 0 .../share/man/glibc.1 | 0 .../image-nixos-jq-pkg-db/Dockerfile | 0 .../image-nixos-jq-pkg-db/clean_db.sql | 0 .../image-nixos-jq-pkg-store/Dockerfile | 0 syft/pkg/cataloger/ocaml/cataloger_test.go | 2 +- syft/pkg/cataloger/ocaml/parse_opam_test.go | 4 +- .../{test-fixtures => testdata}/alcotest.opam | 0 .../glob-paths/opam/alcotest.opam | 0 .../opam/ocaml-base-compiler.4.14.0/opam | 0 .../ocaml-base-compiler.4.14.0/opam | 0 syft/pkg/cataloger/php/cataloger_test.go | 8 +- .../php/interpreter_cataloger_test.go | 106 ++++++------- .../cataloger/php/parse_composer_lock_test.go | 4 +- .../php/parse_installed_json_test.go | 6 +- .../pkg/cataloger/php/parse_pecl_pear_test.go | 26 ++-- .../{test-fixtures => testdata}/composer.lock | 0 .../.channel.pecl.php.net/memcached.reg | 0 .../glob-paths/src/composer.lock | 0 .../glob-paths/src/installed.json | 0 .../image-apache/Dockerfile | 0 .../image-extensions/Dockerfile | 0 .../memcached-v5-format.reg | 0 .../memcached-v6-format.reg | 0 .../vendor/composer_1/installed.json | 0 .../vendor/composer_2/installed.json | 0 syft/pkg/cataloger/python/cataloger_test.go | 46 +++--- syft/pkg/cataloger/python/dependency_test.go | 4 +- syft/pkg/cataloger/python/license_test.go | 4 +- .../cataloger/python/parse_pdm_lock_test.go | 12 +- .../python/parse_pipfile_lock_test.go | 8 +- .../python/parse_poetry_lock_test.go | 8 +- .../python/parse_requirements_test.go | 8 +- syft/pkg/cataloger/python/parse_setup_test.go | 12 +- .../cataloger/python/parse_uv_lock_test.go | 6 +- .../python/parse_wheel_egg_metadata_test.go | 22 +-- .../python/parse_wheel_egg_record_test.go | 6 +- .../Python-2.7.egg-info | 0 .../empty-1.0.0-py3.8.egg-info | 0 .../site-packages/v.DIST-INFO/METADATA | 0 .../site-packages/w.EGG-INFO/PKG-INFO | 0 .../site-packages/x.dist-info/METADATA | 0 .../site-packages/y.egg-info/PKG-INFO | 0 .../glob-paths/site-packages/z.egg-info | 0 .../glob-paths/src/1-requirements-dev.txt | 0 .../glob-paths/src/Pipfile.lock | 0 .../glob-paths/src/extra-requirements.txt | 0 .../glob-paths/src/pdm.lock | 0 .../glob-paths/src/poetry.lock | 0 .../glob-paths/src/requirements-dev.txt | 0 .../glob-paths/src/requirements.txt | 0 .../glob-paths/src/setup.py | 0 .../glob-paths/src/uv.lock | 0 .../image-multi-site-package/Dockerfile | 0 .../installed-files/installed-files.txt | 0 .../pdm-lock-extras/pdm.lock | 0 .../pdm-lock-separate-files/pdm.lock | 0 .../pdm-lock/pdm.lock | 0 .../pipfile-lock/Pipfile.lock | 0 .../poetry/case-sensitivity/poetry.lock | 0 .../conflicting-with-extras/poetry.lock | 0 .../conflicting-with-extras/pyproject.toml | 0 .../poetry/dev-deps/poetry.lock | 0 .../poetry/multiple-extras/poetry.lock | 0 .../poetry/multiple-extras/pyproject.toml | 0 .../poetry/nested-extras/poetry.lock | 0 .../poetry/nested-extras/pyproject.toml | 0 .../poetry/simple-deps/poetry.lock | 0 .../poetry/simple-deps/pyproject.toml | 0 .../pyenv/good-config | 0 .../pyenv/trixy-config | 0 .../pypi-remote/Pipfile.lock | 0 .../pypi-remote/pdm.lock | 0 .../pypi-remote/poetry.lock | 0 .../pypi-remote/pyproject.toml | 0 .../pypi-remote/registry_response.json | 0 .../pypi-remote/registry_response_bad.json | 0 .../pypi-remote/requirements.txt | 0 .../pypi-remote/setup.py | 0 .../pypi-remote/uv.lock | 0 .../requires/requirements.txt | 0 .../setup/dynamic-setup.py | 0 .../setup/mixed-format-setup.py | 0 .../setup/multiline-split-setup.py | 0 .../setup/setup.py | 0 .../LICENSE.txt | 0 .../METADATA | 0 .../RECORD | 0 .../direct_url.json | 0 .../top_level.txt | 0 .../LICENSE.txt | 0 .../METADATA | 0 .../RECORD | 0 .../direct_url.json | 0 .../top_level.txt | 0 .../malformed-record/dist-info/METADATA | 0 .../malformed-record/dist-info/RECORD | 0 .../nested/dist-name/dist-info/LICENSE.txt | 0 .../nested/dist-name/dist-info/METADATA | 0 .../nested/dist-name/dist-info/RECORD | 0 .../dist-name/dist-info/direct_url.json | 0 .../nested/dist-name/dist-info/top_level.txt | 0 .../nested/egg-name/egg-info/PKG-INFO | 0 .../nested/egg-name/egg-info/PKG-INFO-INVALID | 0 .../nested/egg-name/egg-info/RECORD | 0 .../nested/egg-name/egg-info/top_level.txt | 0 .../no-version/no-version-py3.8.egg-info | 0 .../site-packages/partial.dist-info/METADATA | 0 .../site-packages/test/test.egg-info | 0 .../uppercase/dist-name/DIST-INFO/METADATA | 0 .../uppercase/dist-name/DIST-INFO/RECORD | 0 .../dist-name/DIST-INFO/direct_url.json | 0 .../dist-name/DIST-INFO/top_level.txt | 0 .../uppercase/egg-name/EGG-INFO/PKG-INFO | 0 .../egg-name/EGG-INFO/PKG-INFO-INVALID | 0 .../uppercase/egg-name/EGG-INFO/RECORD | 0 .../uppercase/egg-name/EGG-INFO/top_level.txt | 0 .../uv/conflicting-with-extras/pyproject.toml | 0 .../uv/conflicting-with-extras/uv.lock | 0 .../uv/multiple-extras/pyproject.toml | 0 .../uv/multiple-extras/uv.lock | 0 .../uv/nested-extras/pyproject.toml | 0 .../uv/nested-extras/uv.lock | 0 .../uv/simple-deps/pyproject.toml | 0 .../uv/simple-deps/uv.lock | 0 syft/pkg/cataloger/python/virtual_env_test.go | 4 +- syft/pkg/cataloger/r/cataloger_test.go | 2 +- .../pkg/cataloger/r/parse_description_test.go | 14 +- .../r/{test-fixtures => testdata}/DESCRIPTION | 0 .../installed/base/DESCRIPTION | 0 .../installed/stringr/DESCRIPTION | 0 .../{test-fixtures => testdata}/map-parse/bad | 0 .../map-parse/eof-multiline | 0 .../map-parse/multiline | 0 .../map-parse/no-name | 0 .../map-parse/no-version | 0 .../map-parse/simple | 0 syft/pkg/cataloger/redhat/cataloger_test.go | 4 +- .../redhat/parse_rpm_archive_test.go | 6 +- .../pkg/cataloger/redhat/parse_rpm_db_test.go | 10 +- .../redhat/parse_rpm_manifest_test.go | 2 +- .../sqlitetest/no_sqlite_driver_test.go | 2 +- .../{test-fixtures => testdata}/.gitignore | 0 .../{test-fixtures => testdata}/Makefile | 0 .../{test-fixtures => testdata}/Packages | Bin .../{test-fixtures => testdata}/bad/bad.rpm | 0 .../container-manifest-2 | 0 .../generate-fixture.sh | 0 .../glob-paths/dive-0.10.0.rpm | 0 .../glob-paths/usr/lib/sysimage/rpm/Packages | 0 .../usr/lib/sysimage/rpm/Packages.db | 0 .../usr/lib/sysimage/rpm/rpmdb.sqlite | 0 .../glob-paths/usr/share/rpm/Packages | 0 .../glob-paths/usr/share/rpm/Packages.db | 0 .../glob-paths/usr/share/rpm/rpmdb.sqlite | 0 .../glob-paths/var/lib/rpm/Packages | 0 .../glob-paths/var/lib/rpm/Packages.db | 0 .../glob-paths/var/lib/rpm/rpmdb.sqlite | 0 .../var/lib/rpmmanifest/container-manifest-2 | 0 .../image-minimal/Dockerfile | 0 .../image-minimal/remove.sh | 0 .../image-rpm-archive/Dockerfile | 0 syft/pkg/cataloger/ruby/cataloger_test.go | 4 +- .../cataloger/ruby/parse_gemfile_lock_test.go | 2 +- syft/pkg/cataloger/ruby/parse_gemspec_test.go | 2 +- .../{test-fixtures => testdata}/Gemfile.lock | 0 .../bundler.gemspec | 0 .../specifications/pkg/nested.gemspec | 0 .../glob-paths/specifications/root.gemspec | 0 .../glob-paths/src/Gemfile.lock | 0 .../glob-paths/src/Gemfile.next.lock | 0 syft/pkg/cataloger/rust/cataloger_test.go | 6 +- .../cataloger/rust/parse_cargo_lock_test.go | 6 +- .../{test-fixtures => testdata}/Cargo.lock | 0 .../Cargo.lock-with-git-deps | 0 .../glob-paths/partial-binary | 0 .../glob-paths/src/Cargo.lock | 0 .../image-audit/Cargo.lock | 0 .../image-audit/Cargo.toml | 0 .../image-audit/Dockerfile | 0 .../image-audit/src/main.rs | 0 syft/pkg/cataloger/sbom/cataloger_test.go | 6 +- .../alpine/syft-json/sbom.syft.json | 0 .../glob-paths/app.bom | 0 .../glob-paths/app.bom.json | 0 .../glob-paths/app.cdx | 0 .../glob-paths/app.cdx.json | 0 .../glob-paths/app.sbom | 0 .../glob-paths/app.sbom.json | 0 .../glob-paths/app.spdx | 0 .../glob-paths/app.spdx.json | 0 .../glob-paths/app.syft.json | 0 .../glob-paths/bom | 0 .../glob-paths/sbom | 0 syft/pkg/cataloger/snap/cataloger_test.go | 4 +- syft/pkg/cataloger/snap/integration_test.go | 2 +- .../cataloger/snap/parse_base_dpkg_test.go | 2 +- .../cataloger/snap/parse_integration_test.go | 2 +- .../snap/parse_kernel_changelog_test.go | 6 +- .../{test-fixtures => testdata}/dpkg.yaml | 0 .../base/usr/share/snappy/dpkg.yaml | 0 .../glob-paths/system/snap/manifest.yaml | 0 .../{test-fixtures => testdata}/manifest.yaml | 0 .../real-dpkg.yaml | 0 syft/pkg/cataloger/swift/cataloger_test.go | 2 +- .../swift/parse_package_resolved_test.go | 10 +- .../swift/parse_podfile_lock_test.go | 4 +- .../Package.resolved | 0 .../PackageV3.resolved | 0 .../{test-fixtures => testdata}/Podfile.lock | 0 .../bad-version-packages.resolved | 0 .../empty-packages.resolved | 0 .../glob-paths/src/Podfile.lock | 0 syft/pkg/cataloger/swipl/cataloger_test.go | 2 +- syft/pkg/cataloger/swipl/parse_pack_test.go | 2 +- .../glob-paths/pack.pl | 0 .../swipl/{test-fixtures => testdata}/pack.pl | 0 .../pkg/cataloger/terraform/cataloger_test.go | 2 +- .../two-providers/.terraform.lock.hcl | 0 .../pkg/cataloger/wordpress/cataloger_test.go | 2 +- .../cataloger/wordpress/parse_plugin_test.go | 2 +- .../glob-paths/wp-admin/index.php | 0 .../wp-content/plugins/akismet/akismet.php | 0 .../all-in-one-wp-migration.php | 0 .../glob-paths/wp-includes/index.php | 0 syft/pkg/license_set_test.go | 8 +- syft/pkg/license_test.go | 12 +- .../directorysource/directory_source_test.go | 74 ++++----- syft/source/filesource/file_source_test.go | 36 ++--- .../stereoscopesource/image_source_test.go | 2 +- .../actual-path/empty | 0 .../file-index-filter/.1/something | 0 .../file-index-filter/.2 | 0 .../file-index-filter/.vimrc | 0 .../file-index-filter/empty | 0 .../generate-tar-fixture-from-source-dir.sh | 0 .../image-simple/Dockerfile | 0 .../image-simple/file-1.txt | 0 .../image-simple/file-2.txt | 0 .../target/really/nested/file-3.txt | 0 .../path-detected-2/.vimrc | 0 .../path-detected-2/empty | 0 .../path-detected/.vimrc | 0 .../path-detected/empty | 0 .../{test-fixtures => testdata}/symlink | 0 .../outside_root/link_target/place | 0 .../system_paths/target/dev/place | 0 .../system_paths/target/home/place | 0 .../system_paths/target/link/a-symlink/place | 0 .../system_paths/target/proc/place | 0 .../system_paths/target/sys/place | 0 test/cli/all_formats_convertible_test.go | 4 +- test/cli/all_formats_expressible_test.go | 6 +- test/cli/archive_test.go | 2 +- test/cli/config_test.go | 2 +- test/cli/convert_cmd_test.go | 2 +- test/cli/json_schema_test.go | 2 +- test/cli/spdx_json_schema_test.go | 2 +- test/cli/spdx_tooling_validation_test.go | 2 +- test/cli/symlink_test.go | 2 +- test/cli/test-fixtures/image-pkg-coverage | 1 - test/cli/testdata/.gitignore | 3 + test/cli/{test-fixtures => testdata}/Makefile | 0 .../archive/dist-info/METADATA | 0 .../archive/dist-info/RECORD | 0 .../archive/dist-info/top_level.txt | 0 .../attestation/Dockerfile.ctfe_init | 0 .../attestation/config/config.json | 0 .../attestation/config/ctfe/ct_server.cfg | 0 .../attestation/config/ctfe/privkey.pem | 0 .../attestation/config/ctfe/pubkey.pem | 0 .../config/dex/docker-compose-config.yaml | 0 .../attestation/config/logid.sh | 0 .../attestation/docker-compose-config.yaml | 0 .../attestation/docker-compose.yaml | 0 .../configs/dir1/.syft.yaml | 0 .../configs/dir2/.syft.yaml | 0 .../{test-fixtures => testdata}/csv.template | 0 .../image-bad-binaries/Dockerfile | 0 .../image-bad-binaries/sources.list | 0 .../image-hidden-packages/Dockerfile | 0 .../image-java-spdx-tools/Dockerfile | 0 .../image-java-spdx-tools/Makefile | 0 .../image-node-binary/Dockerfile | 0 test/cli/testdata/image-pkg-coverage | 1 + .../image-unknowns/Dockerfile | 0 .../image-unknowns/exe | 0 .../image-unknowns/executable-script | 0 .../image-unknowns/package-lock.json | 0 .../image-unknowns/unextracted.tar.gz | 0 .../image-unknowns/unextracted.zip | 0 .../image-unknowns/unknown-readable.jar | Bin .../image-unknowns/unknown-unreadable.jar | 0 .../registry/.dockerignore | 0 .../registry/Dockerfile | 0 .../registry/Makefile | 0 test/compare/deb.sh | 2 +- test/compare/mac.sh | 2 +- test/compare/rpm.sh | 2 +- .../acceptance-centos-8.2.2004.json | 0 test/install/0_checksums_test.sh | 14 +- test/install/github_test.sh | 6 +- .../assets/invalid/.gitignore | 0 .../assets/invalid/checksums.txt | 0 .../invalid/syft_1.5.0_linux_arm64.tar.gz | 0 .../assets/valid/.gitignore | 0 .../assets/valid/checksums.txt | 0 .../valid/syft_1.5.0_linux_arm64.tar.gz | 0 .../github-api-syft-v0.36.0-release.json | 0 ...syft_0.35.1-SNAPSHOT-d461f63_checksums.txt | 0 .../syft_0.36.0_checksums.txt | 0 1589 files changed, 1184 insertions(+), 1058 deletions(-) rename cmd/syft/internal/commands/{test-fixtures => testdata}/scan-configs/no-legacy-options.yaml (100%) rename cmd/syft/internal/commands/{test-fixtures => testdata}/scan-configs/with-base-path.yaml (100%) rename cmd/syft/internal/commands/{test-fixtures => testdata}/scan-configs/with-default-pull-source.yaml (100%) rename cmd/syft/internal/commands/{test-fixtures => testdata}/scan-configs/with-exclude-binary-overlap-by-ownership.yaml (100%) rename cmd/syft/internal/commands/{test-fixtures => testdata}/scan-configs/with-file-section.yaml (100%) rename cmd/syft/internal/commands/{test-fixtures => testdata}/scan-configs/with-file-string.yaml (100%) delete mode 120000 cmd/syft/internal/test/integration/test-fixtures/elf-test-fixtures delete mode 100644 cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/java/generate-fixtures.md rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/.gitignore (82%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/Makefile (100%) create mode 120000 cmd/syft/internal/test/integration/testdata/elf-testdata rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/files/somewhere/there/is/a-small-file (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/files/somewhere/there/is/a-symlink-to-a-small-file (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/files/somewhere/there/is/a-symlink-to-file (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/files/somewhere/there/is/a/file (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-distro-id/Dockerfile (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-go-bin-arch-coverage/Dockerfile (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-go-bin-arch-coverage/app.go (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-go-bin-arch-coverage/go.mod (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-go-bin-arch-coverage/go.sum (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-go-bin-arch-coverage/test (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-golang-compiler/Dockerfile (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-java-no-main-package/Dockerfile (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-java-virtualpath-regression/Dockerfile (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-java-virtualpath-regression/extract.py (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-large-apk-data/Dockerfile (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-mariner-distroless/Dockerfile (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-os-binary-overlap/Dockerfile (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-owning-package/Dockerfile (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-photon-all-layers/Dockerfile (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/Dockerfile (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/cocoapods/Podfile.lock (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/composer/composer.lock (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/conan/conanfile.txt (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/etc/os-release (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/hackage/cabal.project.freeze (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/hackage/stack.yaml (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/hackage/stack.yaml.lock (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/lib/apk/db/installed (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/dart/pubspec.lock (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/dotnet/TestLibrary.deps.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/elixir/mix.lock (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/erlang/accept.app (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/erlang/rebar.lock (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/github-actions/.github/workflows/validations.yaml (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/go/go.mod (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/homebrew/Cellar/afflib/1.2.3/.brew/afflib.rb (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/java/example-java-app-maven-0.1.0.jar (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/java/example-jenkins-plugin.hpi (100%) create mode 100644 cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/java/generate-fixtures.md rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/java/pom.xml (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/javascript/package-json/package.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/javascript/package-lock/package-lock.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/javascript/yarn/yarn.lock (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/lib/apk/db/installed (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/nix/store/h0cnbmfcn93xm5dg2x27ixhag1cwndga-glibc-2.34-210-bin/share/man/glibc.1 (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/opam/ocaml-base-compiler.4.14.0/opam (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/php/.registry/.channel.pecl.php.net/memcached.reg (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/php/vendor/composer/installed.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/python/dist-info/METADATA (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/python/dist-info/RECORD (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/python/dist-info/top_level.txt (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/python/egg-info/PKG-INFO (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/python/egg-info/top_level.txt (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/python/requires/requirements-dev.txt (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/python/requires/requirements.txt (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/python/requires/test-requirements.txt (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/python/setup/setup.py (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/python/someotherpkg-3.19.0-py3.8.egg-info/PKG-INFO (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/python/someotherpkg-3.19.0-py3.8.egg-info/top_level.txt (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/python/somerequests-3.22.0.dist-info/METADATA (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/python/somerequests-3.22.0.dist-info/top_level.txt (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/r/base/DESCRIPTION (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/rockspec/kong-3.7.0-0.rockspec (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/ruby/Gemfile.lock (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/ruby/specifications/bundler.gemspec (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/ruby/specifications/default/unbundler.gemspec (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/rust/Cargo.lock (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/var/db/pkg/app-containers/skopeo-1.5.1/CONTENTS (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/var/db/pkg/app-containers/skopeo-1.5.1/LICENSE (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/var/db/pkg/app-containers/skopeo-1.5.1/SIZE (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/var/lib/dpkg/status (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/var/lib/dpkg/status.d/dash (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/var/lib/dpkg/status.d/netbase (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/var/lib/pacman/local/ALPM_DB_VERSION (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/var/lib/pacman/local/pacman-6.0.1-5/desc (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/var/lib/pacman/local/pacman-6.0.1-5/files (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/var/lib/pacman/local/pacman-6.0.1-5/mtree (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/var/lib/rpm/Packages (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/var/lib/rpm/generate-fixture.sh (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/pkgs/wordpress/wp-content/plugins/akismet/akismet.php (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/swift/Package.resolved (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/swipl/pack/hdt/pack.pl (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-pkg-coverage/terraform/.terraform.lock.hcl (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-rust-auditable/Dockerfile (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-sbom-cataloger/Dockerfile (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-sbom-cataloger/go.mod (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-sbom-cataloger/test.spdx.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-sbom-metadata-component/Dockerfile (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-sbom-metadata-component/test.cdx.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-sqlite-rpmdb/Dockerfile (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-suse-all-layers/Dockerfile (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-test-java-purls/Dockerfile (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-test-java-purls/extract.py (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/image-vertical-package-dups/Dockerfile (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/collapse-white-space/index.d.ts (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/collapse-white-space/index.js (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/collapse-white-space/license (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/collapse-white-space/package-lock.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/collapse-white-space/package.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/collapse-white-space/readme.md (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/end-of-stream/LICENSE (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/end-of-stream/README.md (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/end-of-stream/index.js (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/end-of-stream/package.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/insert-css/LICENSE (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/insert-css/example.js (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/insert-css/index.js (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/insert-css/package.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/insert-css/readme.markdown (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/insert-css/test.js (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/once/LICENSE (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/once/README.md (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/once/once.js (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/once/package.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/pump/.travis.yml (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/pump/LICENSE (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/pump/README.md (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/pump/index.js (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/pump/package.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/pump/test-browser.js (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/pump/test-node.js (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/wrappy/LICENSE (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/wrappy/README.md (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/wrappy/package-lock.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/wrappy/package.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/node_modules/wrappy/wrappy.js (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/package-lock.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/npm-lock/package.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/yarn-lock/node_modules/async/LICENSE (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/yarn-lock/node_modules/async/bower.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/yarn-lock/node_modules/async/package.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/yarn-lock/node_modules/merge-objects/LICENSE.md (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/yarn-lock/node_modules/merge-objects/package.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/yarn-lock/node_modules/resize-observer-polyfill/LICENSE (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/yarn-lock/node_modules/resize-observer-polyfill/package.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/yarn-lock/node_modules/should-type/LICENSE (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/yarn-lock/node_modules/should-type/package.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/yarn-lock/package.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/yarn-lock/packages/nested-package/node_modules/async/LICENSE (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/yarn-lock/packages/nested-package/node_modules/async/bower.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/yarn-lock/packages/nested-package/node_modules/async/component.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/yarn-lock/packages/nested-package/node_modules/async/package.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/yarn-lock/packages/nested-package/package.json (100%) rename cmd/syft/internal/test/integration/{test-fixtures => testdata}/yarn-lock/yarn.lock (100%) rename internal/file/{test-fixtures => testdata}/digest.txt (100%) rename internal/file/{test-fixtures => testdata}/empty.txt (100%) rename internal/file/{test-fixtures => testdata}/generate-zip-fixture-from-source-dir.sh (100%) rename internal/file/{test-fixtures => testdata}/zip-source/b-file.txt (100%) rename internal/file/{test-fixtures => testdata}/zip-source/b-file/in-subdir.txt (100%) rename internal/file/{test-fixtures => testdata}/zip-source/some-dir/a-file.txt (100%) rename internal/licenses/{test-fixtures => testdata}/Knuth-CTAN (100%) rename internal/licenses/{test-fixtures => testdata}/apache-license-2.0 (100%) rename internal/licenses/{test-fixtures => testdata}/multi-license (100%) rename internal/licenses/{test-fixtures => testdata}/nvidia-software-and-cuda-supplement (100%) rename internal/os/{test-fixtures => testdata}/not_rhel/Dockerfile (100%) rename internal/os/{test-fixtures => testdata}/not_rhel/etc/os-release (100%) rename internal/os/{test-fixtures => testdata}/not_rhel/root/buildinfo/content_manifests/driver-toolkit-container-v4.16.0-202411210647.p0.g1d5732f.assembly.stream.el9.json (100%) rename internal/os/{test-fixtures => testdata}/rhel_content_manifests/Dockerfile (100%) rename internal/os/{test-fixtures => testdata}/rhel_content_manifests/etc/os-release (100%) rename internal/os/{test-fixtures => testdata}/rhel_content_manifests/root/buildinfo/content_manifests/driver-toolkit-container-v4.16.0-202411210647.p0.g1d5732f.assembly.stream.el9.json (100%) rename internal/os/{test-fixtures => testdata}/rhel_content_manifests/root/buildinfo/content_manifests/openshift-base-rhel9-container-v4.16.0-202411190033.p0.gb45ea65.assembly.stream.el9.json (100%) rename internal/os/{test-fixtures => testdata}/rhel_no_manifests/Dockerfile (100%) rename internal/os/{test-fixtures => testdata}/rhel_no_manifests/etc/os-release (100%) delete mode 120000 internal/relationship/binary/test-fixtures/elf-test-fixtures create mode 120000 internal/relationship/binary/testdata/elf-testdata rename internal/spdxlicense/generate/{test-fixtures => testdata}/licenses.json (100%) create mode 100644 internal/testutils/golden_files.go rename syft/cpe/{test-fixtures => testdata}/cpe-data.json (100%) rename syft/file/cataloger/executable/{test-fixtures => testdata}/.gitignore (100%) rename syft/file/cataloger/executable/{test-fixtures => testdata}/Makefile (100%) rename syft/file/cataloger/executable/{test-fixtures => testdata}/elf/.gitignore (100%) rename syft/file/cataloger/executable/{test-fixtures => testdata}/elf/Dockerfile (100%) rename syft/file/cataloger/executable/{test-fixtures => testdata}/elf/Makefile (100%) rename syft/file/cataloger/executable/{test-fixtures => testdata}/elf/differ/__main__.py (100%) rename syft/file/cataloger/executable/{test-fixtures => testdata}/elf/expected_verify (100%) rename syft/file/cataloger/executable/{test-fixtures => testdata}/elf/project/Makefile (100%) rename syft/file/cataloger/executable/{test-fixtures => testdata}/elf/project/lib.c (100%) rename syft/file/cataloger/executable/{test-fixtures => testdata}/elf/project/lib.h (100%) rename syft/file/cataloger/executable/{test-fixtures => testdata}/elf/project/main.c (100%) rename syft/file/cataloger/executable/{test-fixtures => testdata}/shared-info/.gitignore (100%) rename syft/file/cataloger/executable/{test-fixtures => testdata}/shared-info/Dockerfile (100%) rename syft/file/cataloger/executable/{test-fixtures => testdata}/shared-info/Makefile (100%) rename syft/file/cataloger/executable/{test-fixtures => testdata}/shared-info/project/Makefile (100%) rename syft/file/cataloger/executable/{test-fixtures => testdata}/shared-info/project/hello/Makefile (100%) rename syft/file/cataloger/executable/{test-fixtures => testdata}/shared-info/project/hello/hello.c (100%) rename syft/file/cataloger/executable/{test-fixtures => testdata}/shared-info/project/libhello/Makefile (100%) rename syft/file/cataloger/executable/{test-fixtures => testdata}/shared-info/project/libhello/hello.c (100%) rename syft/file/cataloger/executable/{test-fixtures => testdata}/shared-info/project/libhello/hello.h (100%) rename syft/file/cataloger/filecontent/{test-fixtures => testdata}/a-path.txt (100%) rename syft/file/cataloger/filecontent/{test-fixtures => testdata}/another-path.txt (100%) rename syft/file/cataloger/filecontent/{test-fixtures => testdata}/last/empty/empty (100%) rename syft/file/cataloger/filecontent/{test-fixtures => testdata}/last/path.txt (100%) rename syft/file/cataloger/filedigest/{test-fixtures => testdata}/image-file-type-mix/Dockerfile (100%) rename syft/file/cataloger/filedigest/{test-fixtures => testdata}/image-file-type-mix/file-1.txt (100%) rename syft/file/cataloger/filedigest/{test-fixtures => testdata}/last/empty/empty (100%) rename syft/file/cataloger/filedigest/{test-fixtures => testdata}/last/path.txt (100%) rename syft/file/cataloger/filemetadata/{test-fixtures => testdata}/image-file-type-mix/Dockerfile (100%) rename syft/file/cataloger/filemetadata/{test-fixtures => testdata}/image-file-type-mix/file-1.txt (100%) rename syft/file/cataloger/internal/{test-fixtures => testdata}/image-file-type-mix/Dockerfile (100%) rename syft/file/cataloger/internal/{test-fixtures => testdata}/image-file-type-mix/file-1.txt (100%) rename syft/file/cataloger/internal/{test-fixtures => testdata}/symlinked-root/nested/link-root (100%) rename syft/file/cataloger/internal/{test-fixtures => testdata}/symlinked-root/real-root/file1.txt (100%) rename syft/file/cataloger/internal/{test-fixtures => testdata}/symlinked-root/real-root/nested/file2.txt (100%) rename syft/file/cataloger/internal/{test-fixtures => testdata}/symlinked-root/real-root/nested/linked-file1.txt (100%) rename syft/file/{test-fixtures => testdata}/req-resp/.gitignore (100%) rename syft/file/{test-fixtures => testdata}/req-resp/path/to/rel-inside.txt (100%) rename syft/file/{test-fixtures => testdata}/req-resp/path/to/the/file.txt (100%) rename syft/file/{test-fixtures => testdata}/req-resp/path/to/the/rel-outside.txt (100%) rename syft/file/{test-fixtures => testdata}/req-resp/root-link (100%) rename syft/file/{test-fixtures => testdata}/req-resp/somewhere/outside.txt (100%) rename syft/format/cyclonedxjson/{test-fixtures => testdata}/bad-sbom (100%) rename syft/format/cyclonedxjson/{test-fixtures => testdata}/identify/1.2.json (100%) rename syft/format/cyclonedxjson/{test-fixtures => testdata}/identify/1.3.json (100%) rename syft/format/cyclonedxjson/{test-fixtures => testdata}/identify/1.4.json (100%) rename syft/format/cyclonedxjson/{test-fixtures => testdata}/identify/1.5.json (100%) rename syft/format/cyclonedxjson/{test-fixtures => testdata}/identify/1.6.json (100%) rename syft/format/cyclonedxjson/{test-fixtures => testdata}/identify/micronaut-1.4.json (100%) rename syft/format/cyclonedxjson/{test-fixtures => testdata}/identify/micronaut-1.5.json (100%) rename syft/format/cyclonedxjson/{test-fixtures => testdata}/identify/micronaut-1.6.json (100%) rename syft/format/cyclonedxjson/{test-fixtures => testdata}/snapshot/TestCycloneDxDirectoryEncoder.golden (100%) rename syft/format/cyclonedxjson/{test-fixtures => testdata}/snapshot/TestCycloneDxImageEncoder.golden (100%) rename syft/format/cyclonedxxml/{test-fixtures => testdata}/bad-sbom (100%) rename syft/format/cyclonedxxml/{test-fixtures => testdata}/identify/1.0.xml (100%) rename syft/format/cyclonedxxml/{test-fixtures => testdata}/identify/1.1.xml (100%) rename syft/format/cyclonedxxml/{test-fixtures => testdata}/identify/1.2.xml (100%) rename syft/format/cyclonedxxml/{test-fixtures => testdata}/identify/1.3.xml (100%) rename syft/format/cyclonedxxml/{test-fixtures => testdata}/identify/1.4.xml (100%) rename syft/format/cyclonedxxml/{test-fixtures => testdata}/identify/1.5.xml (100%) rename syft/format/cyclonedxxml/{test-fixtures => testdata}/identify/1.6.xml (100%) rename syft/format/cyclonedxxml/{test-fixtures => testdata}/snapshot/TestCycloneDxDirectoryEncoder.golden (100%) rename syft/format/cyclonedxxml/{test-fixtures => testdata}/snapshot/TestCycloneDxImageEncoder.golden (100%) rename syft/format/github/{test-fixtures => testdata}/snapshot/TestGithubDirectoryEncoder.golden (100%) rename syft/format/github/{test-fixtures => testdata}/snapshot/TestGithubImageEncoder.golden (100%) rename syft/format/internal/testutil/{test-fixtures => testdata}/image-simple/Dockerfile (100%) rename syft/format/internal/testutil/{test-fixtures => testdata}/image-simple/file-1.txt (100%) rename syft/format/internal/testutil/{test-fixtures => testdata}/image-simple/file-2.txt (100%) rename syft/format/internal/testutil/{test-fixtures => testdata}/snapshot/TestImageEncoder.golden (100%) rename syft/format/internal/testutil/{test-fixtures => testdata}/snapshot/TestSPDXTagValueImageEncoder.golden (100%) rename syft/format/internal/testutil/{test-fixtures => testdata}/snapshot/stereoscope-fixture-image-simple.golden (100%) rename syft/format/purls/{test-fixtures => testdata}/snapshot/Test_Encoder.golden (100%) rename syft/format/spdxjson/{test-fixtures => testdata}/identify/2.2.json (100%) rename syft/format/spdxjson/{test-fixtures => testdata}/identify/2.3.json (100%) rename syft/format/spdxjson/{test-fixtures => testdata}/snapshot/TestSPDX22JSONRequredProperties.golden (100%) rename syft/format/spdxjson/{test-fixtures => testdata}/snapshot/TestSPDXJSONDirectoryEncoder.golden (100%) rename syft/format/spdxjson/{test-fixtures => testdata}/snapshot/TestSPDXJSONImageEncoder.golden (100%) rename syft/format/spdxjson/{test-fixtures => testdata}/snapshot/TestSPDXRelationshipOrder.golden (100%) rename syft/format/spdxjson/{test-fixtures => testdata}/spdx/alpine-3.10.syft.spdx.json (100%) rename syft/format/spdxjson/{test-fixtures => testdata}/spdx/alpine-3.10.vendor.spdx.json (100%) rename syft/format/spdxjson/{test-fixtures => testdata}/spdx/bad/bad-sbom (100%) rename syft/format/spdxjson/{test-fixtures => testdata}/spdx/bad/example7-bin.spdx.json (100%) rename syft/format/spdxjson/{test-fixtures => testdata}/spdx/bad/example7-go-module.spdx.json (100%) rename syft/format/spdxjson/{test-fixtures => testdata}/spdx/bad/example7-golang.spdx.json (100%) rename syft/format/spdxjson/{test-fixtures => testdata}/spdx/bad/example7-third-party-modules.spdx.json (100%) rename syft/format/spdxjson/{test-fixtures => testdata}/spdx/example7-bin.spdx.json (100%) rename syft/format/spdxjson/{test-fixtures => testdata}/spdx/example7-go-module.spdx.json (100%) rename syft/format/spdxjson/{test-fixtures => testdata}/spdx/example7-golang.spdx.json (100%) rename syft/format/spdxjson/{test-fixtures => testdata}/spdx/example7-third-party-modules.spdx.json (100%) rename syft/format/spdxtagvalue/{test-fixtures => testdata}/bad-sbom (100%) rename syft/format/spdxtagvalue/{test-fixtures => testdata}/identify/2.1.sbom (100%) rename syft/format/spdxtagvalue/{test-fixtures => testdata}/identify/2.2.sbom (100%) rename syft/format/spdxtagvalue/{test-fixtures => testdata}/identify/2.3.sbom (100%) rename syft/format/spdxtagvalue/{test-fixtures => testdata}/snapshot/TestSPDXJSONSPDXIDs.golden (100%) rename syft/format/spdxtagvalue/{test-fixtures => testdata}/snapshot/TestSPDXRelationshipOrder.golden (100%) rename syft/format/spdxtagvalue/{test-fixtures => testdata}/snapshot/TestSPDXTagValueDirectoryEncoder.golden (100%) rename syft/format/spdxtagvalue/{test-fixtures => testdata}/snapshot/TestSPDXTagValueImageEncoder.golden (100%) rename syft/format/spdxtagvalue/{test-fixtures => testdata}/tag-value.spdx (100%) rename syft/format/syftjson/{test-fixtures => testdata}/identify/11.0.0.json (100%) rename syft/format/syftjson/{test-fixtures => testdata}/image-alpine/Dockerfile (100%) rename syft/format/syftjson/{test-fixtures => testdata}/snapshot/TestDirectoryEncoder.golden (100%) rename syft/format/syftjson/{test-fixtures => testdata}/snapshot/TestEncodeFullJSONDocument.golden (100%) rename syft/format/syftjson/{test-fixtures => testdata}/snapshot/TestImageEncoder.golden (100%) rename syft/format/table/{test-fixtures => testdata}/snapshot/TestTableEncoder.golden (100%) rename syft/format/template/{test-fixtures => testdata}/csv-hasField.template (100%) rename syft/format/template/{test-fixtures => testdata}/csv.template (100%) rename syft/format/template/{test-fixtures => testdata}/legacy/csv-hasField.template (100%) rename syft/format/template/{test-fixtures => testdata}/legacy/csv.template (100%) rename syft/format/template/{test-fixtures => testdata}/snapshot/TestFormatWithOption.golden (100%) rename syft/format/template/{test-fixtures => testdata}/snapshot/TestFormatWithOptionAndHasField.golden (100%) rename syft/format/template/{test-fixtures => testdata}/snapshot/TestFormatWithOptionAndHasField_Legacy.golden (100%) rename syft/format/template/{test-fixtures => testdata}/snapshot/TestFormatWithOption_Legacy.golden (100%) rename syft/format/{test-fixtures => testdata}/alpine-syft.json (100%) rename syft/format/text/{test-fixtures => testdata}/snapshot/TestTextDirectoryEncoder.golden (100%) rename syft/format/text/{test-fixtures => testdata}/snapshot/TestTextImageEncoder.golden (100%) rename syft/format/text/{test-fixtures => testdata}/snapshot/stereoscope-fixture-image-simple.golden (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/bad-symlinks/root/place/fd (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/generate-tar-fixture-from-source-dir.sh (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/image-duplicate-path/Dockerfile (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/image-duplicate-path/file-1.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/image-duplicate-path/file-2.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/image-files-deleted/Dockerfile (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/image-files-deleted/file-1.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/image-files-deleted/file-3.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/image-files-deleted/target/file-2.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/image-simple/Dockerfile (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/image-simple/file-1.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/image-simple/file-2.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/image-simple/target/really/nested/file-3.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/image-symlinks/Dockerfile (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/image-symlinks/file-1.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/image-symlinks/file-2.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/image-symlinks/nested/nested/file-3.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/image-symlinks/new-file-2.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/image-symlinks/new-file-4.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/image-symlinks/parent/file-4.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/path-detected-2/.vimrc (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/path-detected-2/empty (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/path-detected/.vimrc (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/path-detected/empty (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/req-resp/.gitignore (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/req-resp/path/to/rel-inside.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/req-resp/path/to/the/file.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/req-resp/path/to/the/rel-outside.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/req-resp/root-link (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/req-resp/somewhere/outside.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinked-root/nested/link-root (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinked-root/real-root/file1.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinked-root/real-root/nested/file2.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinked-root/real-root/nested/linked-file1.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-base/bar (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-base/base (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-base/baz (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-base/chain (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-base/foo (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-base/sub/item (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-base/sub/link (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-from-image-symlinks-fixture/file-1.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-from-image-symlinks-fixture/file-2.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-from-image-symlinks-fixture/file-3.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-from-image-symlinks-fixture/link-1 (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-from-image-symlinks-fixture/link-2 (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-from-image-symlinks-fixture/link-dead (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-from-image-symlinks-fixture/link-indirect (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-from-image-symlinks-fixture/link-within (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-from-image-symlinks-fixture/parent-link (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-from-image-symlinks-fixture/parent/file-4.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-loop/README.md (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-loop/block/loop0 (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-loop/devices/loop0/file.target (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-loop/devices/loop0/subsystem (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-multiple-roots/outside/link_to_readme (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-multiple-roots/root/link_to_link_to_readme (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-multiple-roots/root/readme (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-prune-indexing/before-path (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-prune-indexing/c-file.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-prune-indexing/c-path (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-prune-indexing/path/1/2/3/4/dont-index-me-twice.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-prune-indexing/path/5/6/7/8/dont-index-me-twice-either.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-prune-indexing/path/file.txt (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-simple/link_to_link_to_new_readme (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-simple/link_to_new_readme (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/symlinks-simple/readme (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/system_paths/outside_root/link_target/place (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/system_paths/target/dev/place (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/system_paths/target/hierarchical-dev/module_1/module_1_1/place (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/system_paths/target/home/place (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/system_paths/target/link/a-symlink (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/system_paths/target/proc/place (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/system_paths/target/symlinks-to-dev (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/system_paths/target/symlinks-to-hierarchical-dev (100%) rename syft/internal/fileresolver/{test-fixtures => testdata}/system_paths/target/sys/place (100%) rename syft/linux/{test-fixtures => testdata}/bad-redhat-release (100%) rename syft/linux/{test-fixtures => testdata}/bad-system-release-cpe (100%) rename syft/linux/{test-fixtures => testdata}/centos-8 (100%) rename syft/linux/{test-fixtures => testdata}/debian-8 (100%) rename syft/linux/{test-fixtures => testdata}/os/almalinux/etc/os-release (100%) rename syft/linux/{test-fixtures => testdata}/os/alpine/etc/os-release (100%) rename syft/linux/{test-fixtures => testdata}/os/amazon/etc/os-release (100%) rename syft/linux/{test-fixtures => testdata}/os/arch/etc/os-release (100%) create mode 100644 syft/linux/testdata/os/busybox/.gitignore create mode 100644 syft/linux/testdata/os/busybox/bin/.gitignore rename syft/linux/{test-fixtures => testdata}/os/busybox/bin/busybox (100%) rename syft/linux/{test-fixtures => testdata}/os/centos/usr/lib/os-release (100%) rename syft/linux/{test-fixtures => testdata}/os/centos5/etc/redhat-release (100%) rename syft/linux/{test-fixtures => testdata}/os/centos6/etc/system-release-cpe (100%) rename syft/linux/{test-fixtures => testdata}/os/custom/etc/os-release (100%) rename syft/linux/{test-fixtures => testdata}/os/debian/from-debian_version/etc/debian_version (100%) rename syft/linux/{test-fixtures => testdata}/os/debian/from-debian_version/etc/os-release (100%) rename syft/linux/{test-fixtures => testdata}/os/debian/from-os-release/usr/lib/os-release (100%) rename syft/linux/{test-fixtures => testdata}/os/empty/etc/os-release (100%) rename syft/linux/{test-fixtures => testdata}/os/fedora/usr/lib/os-release (100%) rename syft/linux/{test-fixtures => testdata}/os/mariner/etc/os-release (100%) rename syft/linux/{test-fixtures => testdata}/os/opensuse-leap/etc/os-release (100%) rename syft/linux/{test-fixtures => testdata}/os/oraclelinux/etc/os-release (100%) rename syft/linux/{test-fixtures => testdata}/os/photon/etc/os-release (100%) rename syft/linux/{test-fixtures => testdata}/os/redhat/from-os-release/usr/lib/os-release (100%) rename syft/linux/{test-fixtures => testdata}/os/redhat/from-redhat-release/etc/redhat-release (100%) rename syft/linux/{test-fixtures => testdata}/os/rockylinux/etc/os-release (100%) rename syft/linux/{test-fixtures => testdata}/os/sles/etc/os-release (100%) rename syft/linux/{test-fixtures => testdata}/os/ubuntu/etc/os-release (100%) rename syft/linux/{test-fixtures => testdata}/os/wolfi/etc/os-release (100%) rename syft/linux/{test-fixtures => testdata}/partial-fields/missing-id/usr/lib/os-release (100%) rename syft/linux/{test-fixtures => testdata}/partial-fields/missing-version/usr/lib/os-release (100%) rename syft/linux/{test-fixtures => testdata}/partial-fields/unknown-id/usr/lib/os-release (100%) rename syft/linux/{test-fixtures => testdata}/rhel-8 (100%) rename syft/linux/{test-fixtures => testdata}/ubuntu-20.04 (100%) rename syft/linux/{test-fixtures => testdata}/unprintable (100%) rename syft/pkg/cataloger/ai/{test-fixtures => testdata}/glob-paths/models/model.gguf (100%) rename syft/pkg/cataloger/alpine/{test-fixtures => testdata}/base (100%) rename syft/pkg/cataloger/alpine/{test-fixtures => testdata}/corrupt/lib/apk/db/installed (100%) rename syft/pkg/cataloger/alpine/{test-fixtures => testdata}/empty-deps-and-provides (100%) rename syft/pkg/cataloger/alpine/{test-fixtures => testdata}/extra-file-attributes (100%) rename syft/pkg/cataloger/alpine/{test-fixtures => testdata}/glob-paths/lib/apk/db/installed (100%) rename syft/pkg/cataloger/alpine/{test-fixtures => testdata}/multiple-1/lib/apk/db/installed (100%) rename syft/pkg/cataloger/alpine/{test-fixtures => testdata}/multiple-2/lib/apk/db/installed (100%) rename syft/pkg/cataloger/alpine/{test-fixtures => testdata}/single (100%) rename syft/pkg/cataloger/alpine/{test-fixtures => testdata}/very-large-entries (100%) rename syft/pkg/cataloger/arch/{test-fixtures => testdata}/files (100%) rename syft/pkg/cataloger/arch/{test-fixtures => testdata}/glob-paths/var/lib/pacman/local/base-1.0/desc (100%) rename syft/pkg/cataloger/arch/{test-fixtures => testdata}/glob-paths/var/lib/pacman/local/base-1.0/files (100%) rename syft/pkg/cataloger/arch/{test-fixtures => testdata}/glob-paths/var/lib/pacman/local/dive-0.10.0/desc (100%) rename syft/pkg/cataloger/arch/{test-fixtures => testdata}/installed/var/lib/pacman/local/corrupt-0.2.1-3/desc (100%) rename syft/pkg/cataloger/arch/{test-fixtures => testdata}/installed/var/lib/pacman/local/emacs-29.3-3/desc (100%) rename syft/pkg/cataloger/arch/{test-fixtures => testdata}/installed/var/lib/pacman/local/fuzzy-1.2-3/desc (100%) rename syft/pkg/cataloger/arch/{test-fixtures => testdata}/installed/var/lib/pacman/local/fuzzy-1.2-3/files (100%) rename syft/pkg/cataloger/arch/{test-fixtures => testdata}/installed/var/lib/pacman/local/gmp-6.2.1-2/desc (100%) rename syft/pkg/cataloger/arch/{test-fixtures => testdata}/installed/var/lib/pacman/local/gmp-6.2.1-2/files (100%) rename syft/pkg/cataloger/arch/{test-fixtures => testdata}/installed/var/lib/pacman/local/gmp-6.2.1-2/mtree (100%) rename syft/pkg/cataloger/arch/{test-fixtures => testdata}/installed/var/lib/pacman/local/madeup-20.30-4/desc (100%) rename syft/pkg/cataloger/arch/{test-fixtures => testdata}/installed/var/lib/pacman/local/tree-sitter-0.22.6-1/desc (100%) rename syft/pkg/cataloger/arch/{test-fixtures => testdata}/mtree (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/cli/cli.go (81%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/cli/commands/add_snippet.go (91%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/cli/commands/download.go (90%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/cli/commands/list.go (94%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/cli/commands/root.go (70%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/cli/commands/write_snippet.go (97%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/config/application.go (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/config/application_test.go (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/config/binary_from_image.go (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/config/binary_from_image_test.go (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/config/testdata/app-configs/bad-image-collision.yaml (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/config/testdata/app-configs/bad-implicit-name-collision.yaml (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/config/testdata/app-configs/bad-missing-image-platform.yaml (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/config/testdata/app-configs/bad-missing-image-ref.yaml (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/config/testdata/app-configs/bad-missing-image.yaml (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/config/testdata/app-configs/bad-missing-paths.yaml (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/config/testdata/app-configs/bad-missing-version.yaml (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/config/testdata/app-configs/bad-no-name.yaml (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/config/testdata/app-configs/valid-1.yaml (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/config/testdata/app-configs/valid-2.yaml (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/download_from_image.go (97%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/download_from_image_test.go (92%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/list_entries.go (98%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/list_entries_test.go (97%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/snippet_metadata.go (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/snippet_metadata_test.go (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/testdata/.gitignore (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/testdata/bin/busybox/1.3.6/linux-amd64/busybox (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/testdata/bin/busybox/1.3.6/linux-arm64/busybox (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/testdata/snippets/busybox/1.3.6/linux-amd64/busybox (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/testdata/snippets/busybox/1.3.6/linux-arm64/busybox (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/testdata/snippets/postgres/9.6.10/linux-amd64/postgres (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/ui/action.go (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/ui/ansi.go (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/ui/binary_list.go (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/ui/error.go (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/ui/title.go (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/utils.go (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/internal/utils_test.go (100%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/main.go (61%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/testutil/snippet_or_binary.go (85%) rename syft/pkg/cataloger/binary/{test-fixtures => internal}/manager/testutil/snippet_or_binary_test.go (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/.gitignore (56%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/Makefile (84%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/capture-snippet.sh (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/negative/.gitignore (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/negative/busybox (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/negative/go (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/negative/libpython2.7.so (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/negative/python2.6 (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/negative/traefik/traefik (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/arangodb/3.11.8/linux-amd64/arangosh (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/arangodb/3.12.0-2/linux-amd64/arangosh (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/bash/5.1.16/linux-amd64/bash (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/busybox/1.36.1/linux-amd64/[ (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/busybox/1.36.1/linux-amd64/busybox (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/chrome/126.0.6478.182/linux-amd64/chrome (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/chrome/127.0.6533.119/linux-amd64/chrome (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/consul/1.15.2/linux-amd64/consul (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/dart/2.12.4/linux-amd64/dart (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/dart/3.0.0/linux-arm/dart (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/dart/3.5.2/linux-amd64/dart (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/dart/3.6.0-216.1.beta/linux-amd64/dart (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/elixir/1.19.1/linux-amd64/elixir (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/elixir/1.19.1/linux-amd64/lib/elixir/ebin/elixir.app (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/envoy/1.11.0/linux-amd64/envoy (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/envoy/1.14.3/linux-amd64/envoy (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/envoy/1.18.6/linux-amd64/envoy (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/envoy/1.20.7/linux-amd64/envoy (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/envoy/1.22.11/linux-amd64/envoy (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/envoy/1.28.7/linux-amd64/envoy (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/envoy/1.34.5/linux-amd64/envoy (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/envoy/1.36.4/linux-amd64/envoy (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/envoy/1.6.0/linux-amd64/envoy (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/erlang/25.3.2.6/linux-amd64/erlexec (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/erlang/26.1.2/linux-arm64/beam.smp (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/erlang/26.2.0.0/linux-amd64/erlexec (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/erlang/26.2.4/linux-amd64/liberts_internal.a (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/erlang/27.0/linux-amd64/beam.smp (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/ffmpeg-shared-libs/5.1.4/linux-amd64/libavcodec-9aae324f.so.59.37.100 (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/ffmpeg/6.1.1/linux-amd64/ffmpeg (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/ffmpeg/7.1.1/darwin-arm64/ffmpeg (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/fluent-bit/1.3.10/linux-arm/fluent-bit (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/fluent-bit/1.7.0-dev-3/linux-amd64/fluent-bit (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/fluent-bit/2.2.1/linux-arm64/fluent-bit (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/fluent-bit/3.0.2/linux-amd64/fluent-bit (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/gcc/12.3.0/linux-amd64/gcc (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/go-version-hint/1.15/any/VERSION (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/go-version-hint/1.15/any/bin/go (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/go-version-hint/1.15w/any/VERSION (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/go-version-hint/1.15w/any/bin/go.exe (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/go-version-hint/1.21/any/VERSION (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/go-version-hint/1.21/any/go (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/go-version-hint/1.25/any/VERSION.cache (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/go-version-hint/1.25/any/bin/go (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/go-version-hint/1.25w/any/VERSION (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/go-version-hint/1.25w/any/go.exe (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/go/1.21.3/linux-amd64/go (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/grafana/10.3.12/linux-amd64/grafana (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/grafana/10.4.19/linux-amd64/grafana (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/grafana/11.0.0-preview/linux-amd64/grafana (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/grafana/11.0.0/linux-amd64/grafana (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/grafana/12.0.0/linux-amd64/grafana (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/grafana/12.2.0-258092/linux-amd64/grafana (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/grafana/12.3.1/linux-amd64/grafana (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/grafana/12.3.2-security-01/linux-amd64/grafana (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/grafana/12.4.0-22081664032/linux-amd64/grafana (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/grafana/6.0.0-beta1/linux-amd64/grafana-server (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/grafana/6.7.0-test/linux-amd64/grafana-server (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/grafana/6.7.6/linux-amd64/grafana-server (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/grafana/7.5.17/linux-amd64/grafana-server (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/grafana/9.0.0/linux-amd64/grafana-server (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/grafana/9.2.13/linux-amd64/grafana (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/grafana/9.2.20/linux-amd64/grafana (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/grafana/9.3.0-beta1/linux-amd64/grafana-server (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/grafana/9.4.0-beta1/linux-amd64/grafana (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/grafana/9.5.21/linux-amd64/grafana (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/gzip/1.12/linux-amd64/gzip (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/haproxy/1.5.14/linux-amd64/haproxy (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/haproxy/1.8.22/linux-amd64/haproxy (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/haproxy/2.0.0/linux-amd64/haproxy (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/haproxy/2.7.3/linux-amd64/haproxy (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/haproxy/3.1-dev0/linux-amd64/haproxy (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/haskell-cabal/3.10.3.0/linux-amd64/cabal (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/haskell-ghc/9.6.5/linux-amd64/ghc-9.6.5 (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/helm/3.10.3/linux-amd64/helm (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/helm/3.11.1/linux-amd64/helm (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/httpd/2.4.54/linux-amd64/httpd (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/istio_pilot-agent/1.1.17/linux-amd64/pilot-agent (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/istio_pilot-agent/1.26.8/linux-amd64/pilot-agent (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/istio_pilot-agent/1.8.0/linux-amd64/pilot-agent (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/istio_pilot-discovery/1.1.17/linux-amd64/pilot-discovery (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/istio_pilot-discovery/1.26.8/linux-amd64/pilot-discovery (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/istio_pilot-discovery/1.3.8/linux-amd64/pilot-discovery (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/istio_pilot-discovery/1.8.0/linux-amd64/pilot-discovery (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/java-graal-openjdk/17.0.3+7-jvmci-22.1-b06/linux-amd64/java (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/java-jdk-openjdk/21.0.2+13-LTS/linux-amd64/jdb (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/java-jdk-oracle/1.8.0_451-b10/linux-amd64/java (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/java-jdk-oracle/1.8.0_451-b10/linux-amd64/jdb (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/java-jre-openjdk-arm64-eclipse/11.0.22/linux-arm64/java (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/java-jre-openjdk-eclipse/11.0.22/linux-amd64/java (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/java-jre-openjdk/1.8.0_352-b08/linux-amd64/java (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/java-jre-openjdk/11.0.17/linux-amd64/java (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/java-jre-oracle-sdk/1.8.0_451-b10/linux-amd64/java (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/java-jre-oracle/1.8.0_451-b10/linux-amd64/java (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/java-jre-oracle/19.0.1/darwin/java (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/java-jre-oracle/19.0.1/linux-amd64/java (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/jq/1.7.1/linux-amd64/jq (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/lighttpd/1.4.76/linux-amd64/lighttpd (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/mariadb/10.6.15/linux-amd64/mariadb (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/memcached/1.6.18/linux-amd64/memcached (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/mongodb/4.4.30/linux-amd64/mongod (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/mongodb/5.0.32/linux-amd64/mongod (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/mongodb/6.0.27/linux-amd64/mongod (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/mongodb/7.0.28/linux-amd64/mongod (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/mongodb/8.0.17/linux-amd64/mongod (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/mysql/5.6.51/linux-amd64/mysql (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/mysql/8.0.34/linux-amd64/mysql (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/mysql/8.0.37/linux-amd64/mysql (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/nginx-openresty/1.21.4.3/linux-amd64/nginx (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/nginx/1.25.1/linux-amd64/nginx (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/node/0.10.48/linux-amd64/node (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/node/0.12.18/linux-amd64/node (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/node/19.2.0/linux-amd64/node (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/node/4.9.1/linux-amd64/node (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/openssl/1.1.1w/linux-arm64/openssl (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/openssl/1.1.1zb/linux-arm64/openssl (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/openssl/3.1.4/linux-amd64/openssl (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/percona-server/8.0.35/linux-amd64/mysql (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/percona-xtrabackup/8.0.35/linux-amd64/xtrabackup (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/percona-xtradb-cluster/8.0.34/linux-amd64/mysql (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/perl/5.12.5/linux-amd64/perl (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/perl/5.20.0/linux-amd64/perl (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/perl/5.37.8/linux-amd64/perl (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/php-apache/8.2.1/linux-amd64/libphp.so (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/postgres/15.1/linux-amd64/postgres (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/postgres/15beta4/linux-amd64/postgres (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/postgres/9.5alpha1/linux-amd64/postgres (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/postgres/9.6.24/linux-amd64/postgres (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/proftpd/1.3.8b/linux-amd64/proftpd (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/pypy-shared-lib/7.3.14/linux-amd64/libpypy3.9-c.so (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/python-duplicates/3.8.16/linux-amd64/dir/python3.8 (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/python-duplicates/3.8.16/linux-amd64/libpython3.8.so (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/python-duplicates/3.8.16/linux-amd64/patchlevel.h (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/python-duplicates/3.8.16/linux-amd64/python3.8 (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/python-shared-lib/3.7.4/linux-amd64/libpython3.7m.so.1.0 (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/python-with-incorrect-match/3.5.3/linux-amd64/python3.5 (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/python/3.6.3/linux-amd64/python3.6 (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/qt/4.8.6/linux-amd64/libQtCore.so.4.8.6 (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/qt/5.15.2/linux-amd64/libQt5Core.so.5.15.2 (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/qt/6.5.0/linux-amd64/libQt6Core.so.6.5.0 (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/redis-server/2.8.23/linux-amd64/redis-server (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/redis-server/4.0.11/linux-amd64/redis-server (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/redis-server/5.0.0/linux-amd64/redis-server (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/redis-server/6.0.16/linux-amd64/redis-server (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/redis-server/7.0.0/linux-amd64/redis-server (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/redis-server/7.0.14/linux-amd64/redis-server (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/redis-server/7.2.3/linux-amd64/redis-server (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/redis-server/7.2.3/linux-arm64/redis-server (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/redis-server/7.2.5/linux-unknown-454d5f333836/redis-server (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/ruby/1.9.3p551/linux-amd64/ruby (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/rust-libstd-musl/1.67.1/linux-amd64/libstd-86aefecbddda356d.so (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/rust-libstd/1.50.0/darwin/libstd-f6f9eec1635e636a.dylib (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/rust-libstd/1.50.0/linux-amd64/libstd-6f77337c1826707d.so (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/rust-libstd/1.67.1/darwin/libstd-16f2b65e77054c42.dylib (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/rust-libstd/1.67.1/linux-amd64/libstd-c6192dd4c4d410ac.so (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/sqlcipher/4.5.5/linux-amd64/sqlcipher (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/swipl/9.3.8/linux-amd64/swipl (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/traefik/1.7.34/linux-amd64/traefik (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/traefik/2.10.7/linux-amd64/traefik (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/traefik/2.9.6/linux-amd64/traefik (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/traefik/3.0.4/linux-riscv64/traefik (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/traefik/3.6.5/linux-amd64/traefik (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/util-linux/2.37.4/linux-amd64/getopt (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/valkey-server/9.0.0/linux-amd64/valkey-server (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/vault/1.19.4/linux-arm64/vault (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/vault/1.20.2/linux-amd64/vault (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/wp/2.9.0/linux-amd64/wp (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/xz/5.6.2/linux-amd64/xz (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/classifiers/snippets/zstd/1.5.6/linux-amd64/zstd (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/config.yaml (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/custom/extra/foo (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/custom/go-1.14/go (100%) rename syft/pkg/cataloger/binary/{test-fixtures/elf-test-fixtures => testdata/elf-testdata}/Dockerfile (100%) rename syft/pkg/cataloger/binary/{test-fixtures/elf-test-fixtures => testdata/elf-testdata}/README.md (98%) rename syft/pkg/cataloger/binary/{test-fixtures/elf-test-fixtures => testdata/elf-testdata}/elfbinwithcorrupt/elfsrc/hello_world.cpp (100%) rename syft/pkg/cataloger/binary/{test-fixtures/elf-test-fixtures => testdata/elf-testdata}/elfbinwithcorrupt/elfsrc/hello_world.h (100%) rename syft/pkg/cataloger/binary/{test-fixtures/elf-test-fixtures => testdata/elf-testdata}/elfbinwithcorrupt/elfsrc/makefile (100%) rename syft/pkg/cataloger/binary/{test-fixtures/elf-test-fixtures => testdata/elf-testdata}/elfbinwithcorrupt/elfsrc/testbin.cpp (100%) rename syft/pkg/cataloger/binary/{test-fixtures/elf-test-fixtures => testdata/elf-testdata}/elfbinwithcorrupt/makefile (100%) rename syft/pkg/cataloger/binary/{test-fixtures/elf-test-fixtures => testdata/elf-testdata}/elfbinwithnestedlib/elfsrc/hello_world.cpp (100%) rename syft/pkg/cataloger/binary/{test-fixtures/elf-test-fixtures => testdata/elf-testdata}/elfbinwithnestedlib/elfsrc/hello_world.h (100%) rename syft/pkg/cataloger/binary/{test-fixtures/elf-test-fixtures => testdata/elf-testdata}/elfbinwithnestedlib/elfsrc/makefile (100%) rename syft/pkg/cataloger/binary/{test-fixtures/elf-test-fixtures => testdata/elf-testdata}/elfbinwithnestedlib/elfsrc/testbin.cpp (100%) rename syft/pkg/cataloger/binary/{test-fixtures/elf-test-fixtures => testdata/elf-testdata}/elfbinwithnestedlib/makefile (100%) rename syft/pkg/cataloger/binary/{test-fixtures/elf-test-fixtures => testdata/elf-testdata}/elfbinwithsisterlib/elfsrc1/hello_world.cpp (100%) rename syft/pkg/cataloger/binary/{test-fixtures/elf-test-fixtures => testdata/elf-testdata}/elfbinwithsisterlib/elfsrc1/hello_world.h (100%) rename syft/pkg/cataloger/binary/{test-fixtures/elf-test-fixtures => testdata/elf-testdata}/elfbinwithsisterlib/elfsrc1/makefile (100%) rename syft/pkg/cataloger/binary/{test-fixtures/elf-test-fixtures => testdata/elf-testdata}/elfbinwithsisterlib/elfsrc1/testbin.cpp (100%) rename syft/pkg/cataloger/binary/{test-fixtures/elf-test-fixtures => testdata/elf-testdata}/elfbinwithsisterlib/elfsrc2/hello_world2.cpp (100%) rename syft/pkg/cataloger/binary/{test-fixtures/elf-test-fixtures => testdata/elf-testdata}/elfbinwithsisterlib/elfsrc2/hello_world2.h (100%) rename syft/pkg/cataloger/binary/{test-fixtures/elf-test-fixtures => testdata/elf-testdata}/elfbinwithsisterlib/elfsrc2/makefile (100%) rename syft/pkg/cataloger/binary/{test-fixtures/elf-test-fixtures => testdata/elf-testdata}/elfbinwithsisterlib/elfsrc2/testbin2.cpp (100%) rename syft/pkg/cataloger/binary/{test-fixtures/elf-test-fixtures => testdata/elf-testdata}/elfbinwithsisterlib/makefile (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/image-busybox/Dockerfile (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/image-dotnet-app/Dockerfile (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/image-fedora-32bit/Dockerfile (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/image-fedora-64bit/Dockerfile (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/image-java-binary/Dockerfile (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/image-java-ibm-8/Dockerfile (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/image-java-ibm-jre-8/Dockerfile (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/image-java-ibm-sdk-8/Dockerfile (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/image-java-zulu-21/Dockerfile (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/image-java-zulu-8/Dockerfile (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/image-jruby/Dockerfile (100%) rename syft/pkg/cataloger/binary/{test-fixtures => testdata}/image-wolfi-64bit-without-version/Dockerfile (100%) rename syft/pkg/cataloger/bitnami/{test-fixtures => testdata}/components-json-mongodb/opt/bitnami/.bitnami_components.json (100%) rename syft/pkg/cataloger/bitnami/{test-fixtures => testdata}/components-json-postgresql/opt/bitnami/.bitnami_components.json (100%) rename syft/pkg/cataloger/bitnami/{test-fixtures => testdata}/invalid/opt/bitnami/redis/.spdx-redis.spdx (100%) rename syft/pkg/cataloger/bitnami/{test-fixtures => testdata}/json/opt/bitnami/postgresql/.spdx-postgresql.spdx (100%) rename syft/pkg/cataloger/bitnami/{test-fixtures => testdata}/json/opt/bitnami/postgresql/readme.txt (100%) rename syft/pkg/cataloger/bitnami/{test-fixtures => testdata}/mix/opt/bitnami/render-template/.spdx-render-template.spdx (100%) create mode 100644 syft/pkg/cataloger/bitnami/testdata/no-rel/opt/bitnami/redis/.gitignore rename syft/pkg/cataloger/bitnami/{test-fixtures => testdata}/no-rel/opt/bitnami/redis/.spdx-redis.spdx (100%) create mode 100644 syft/pkg/cataloger/bitnami/testdata/no-rel/opt/bitnami/redis/bin/.gitignore rename syft/pkg/cataloger/bitnami/{test-fixtures => testdata}/no-rel/opt/bitnami/redis/bin/redis-server (100%) rename syft/pkg/cataloger/bitnami/{test-fixtures => testdata}/tag-value/opt/bitnami/redis/.spdx-apache.spdx (100%) rename syft/pkg/cataloger/conda/{test-fixtures => testdata}/conda-meta-bad-json/conda-meta/package-1.2.3-pyhd8ed1ab_0.json (100%) rename syft/pkg/cataloger/conda/{test-fixtures => testdata}/conda-meta-python-c-etc/conda-meta/jupyterlab-4.4.3-pyhd8ed1ab_0.json (100%) rename syft/pkg/cataloger/conda/{test-fixtures => testdata}/conda-meta-python-c-etc/conda-meta/zlib-1.2.11-h90dfc92_1014.json (100%) rename syft/pkg/cataloger/cpp/{test-fixtures => testdata}/README.md (100%) rename syft/pkg/cataloger/cpp/{test-fixtures => testdata}/conan.lock (100%) rename syft/pkg/cataloger/cpp/{test-fixtures => testdata}/conanfile.txt (100%) rename syft/pkg/cataloger/cpp/{test-fixtures => testdata}/conaninfo/mfast/1.2.2/my_user/my_channel/package/9d1f076b471417647c2022a78d5e2c1f834289ac/conaninfo.txt (100%) rename syft/pkg/cataloger/cpp/{test-fixtures => testdata}/conanlock-v2/conan.lock (100%) rename syft/pkg/cataloger/cpp/{test-fixtures => testdata}/corrupt/conan.lock (100%) rename syft/pkg/cataloger/cpp/{test-fixtures => testdata}/glob-paths/somewhere/src/conan.lock (100%) rename syft/pkg/cataloger/cpp/{test-fixtures => testdata}/glob-paths/somewhere/src/conanfile.txt (100%) rename syft/pkg/cataloger/cpp/{test-fixtures => testdata}/glob-paths/somewhere/src/conaninfo.txt (100%) rename syft/pkg/cataloger/dart/{test-fixtures => testdata}/corrupt/pubspec.lock (100%) rename syft/pkg/cataloger/dart/{test-fixtures => testdata}/glob-paths/lock/src/pubspec.lock (100%) rename syft/pkg/cataloger/dart/{test-fixtures => testdata}/glob-paths/spec/pubspec.yaml (100%) rename syft/pkg/cataloger/dart/{test-fixtures => testdata}/glob-paths/spec/pubspec.yml (100%) rename syft/pkg/cataloger/dart/{test-fixtures => testdata}/invalid-sdk/pubspec.lock (100%) rename syft/pkg/cataloger/dart/{test-fixtures => testdata}/missing-sdk/pubspec.lock (100%) rename syft/pkg/cataloger/dart/{test-fixtures => testdata}/pubspec_locks/pubspec.lock (100%) rename syft/pkg/cataloger/dart/{test-fixtures => testdata}/pubspecs/appainter.pubspec.yaml (100%) rename syft/pkg/cataloger/dart/{test-fixtures => testdata}/pubspecs/macros.pubspec.yaml (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/copyright/cuda (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/copyright/dev-kit (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/copyright/libaudit-common (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/copyright/libc6 (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/copyright/liblzma5 (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/copyright/microsoft (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/copyright/python (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/copyright/trilicense (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/glob-paths/usr/lib/dpkg/info/libpam-runtime.conffiles (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/glob-paths/usr/lib/dpkg/info/libpam-runtime.md5sums (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/glob-paths/usr/lib/dpkg/info/libpam-runtime.preinst (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/glob-paths/usr/lib/dpkg/status (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/glob-paths/usr/lib/dpkg/status.d/pkg-1.0 (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/glob-paths/usr/lib/opkg/info/pkg-1.0.control (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/glob-paths/usr/lib/opkg/status (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/glob-paths/usr/share/doc/libpam-runtime/copyright (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/glob-paths/var/lib/dpkg/status (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/glob-paths/var/lib/dpkg/status.d/pkg-1.0 (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/image-distroless-deb/Dockerfile (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/image-distroless-deb/usr/share/doc/libsqlite3-0/copyright (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/image-distroless-deb/var/lib/dpkg/status.d/libsqlite3-0 (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/image-distroless-deb/var/lib/dpkg/status.d/libsqlite3-0.md5sums (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/image-distroless-deb/var/lib/dpkg/status.d/libsqlite3-0.preinst (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/image-dpkg/Dockerfile (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/image-dpkg/etc/os-release (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/image-dpkg/usr/share/doc/libpam-runtime/copyright (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/image-dpkg/var/lib/dpkg/info/libpam-runtime.conffiles (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/image-dpkg/var/lib/dpkg/info/libpam-runtime.md5sums (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/image-dpkg/var/lib/dpkg/info/libpam-runtime.preinst (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/image-dpkg/var/lib/dpkg/status (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/image-single-dpkg/Dockerfile (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/info/util-linux.conffiles (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/info/zlib1g.md5sums (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/var/lib/dpkg/status.d/coreutils-relationships (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/var/lib/dpkg/status.d/corrupt (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/var/lib/dpkg/status.d/deinstall (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/var/lib/dpkg/status.d/doc-examples (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/var/lib/dpkg/status.d/empty (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/var/lib/dpkg/status.d/installed-size-4KB (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/var/lib/dpkg/status.d/libpam-runtime (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/var/lib/dpkg/status.d/multiple (100%) rename syft/pkg/cataloger/debian/{test-fixtures => testdata}/var/lib/dpkg/status.d/single (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/.gitignore (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/Makefile (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/dir-example-1/TestLibrary.deps.json (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/glob-paths/src/packages.lock.json (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/glob-paths/src/something.deps.json (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/glob-paths/src/something.dll (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/glob-paths/src/something.exe (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net2-app/.gitignore (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net2-app/Dockerfile (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net2-app/src/Program.cs (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net2-app/src/helloworld.csproj (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net6-asp-libman/.dockerignore (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net6-asp-libman/.gitignore (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net6-asp-libman/Dockerfile (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net6-asp-libman/src/.gitignore (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net6-asp-libman/src/LibManSample.csproj (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net6-asp-libman/src/Program.cs (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net6-asp-libman/src/Startup.cs (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net6-asp-libman/src/libman.json (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net6-asp-libman/src/vendor/lodash.js (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net6-asp-libman/src/vendor/lodash.min.js (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-no-depjson/.gitignore (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-no-depjson/Dockerfile (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-no-depjson/src/Program.cs (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-no-depjson/src/dotnetapp.csproj (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-no-depjson/src/packages.lock.json (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-self-contained/.gitignore (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-self-contained/Dockerfile (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-self-contained/src/Program.cs (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-self-contained/src/dotnetapp.csproj (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-self-contained/src/packages.lock.json (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-single-file/.gitignore (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-single-file/Dockerfile (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-single-file/src/Program.cs (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-single-file/src/dotnetapp.csproj (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-single-file/src/packages.lock.json (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-with-runtime-nodepsjson/.gitignore (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-with-runtime-nodepsjson/Dockerfile (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-with-runtime-nodepsjson/src/Program.cs (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-with-runtime-nodepsjson/src/dotnetapp.csproj (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-with-runtime-nodepsjson/src/packages.lock.json (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-with-runtime/.gitignore (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-with-runtime/Dockerfile (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-with-runtime/src/Program.cs (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-with-runtime/src/dotnetapp.csproj (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app-with-runtime/src/packages.lock.json (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app/.gitignore (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app/Dockerfile (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app/src/Program.cs (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app/src/dotnetapp.csproj (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-app/src/packages.lock.json (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-compile-target/.gitignore (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-compile-target/Dockerfile (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-compile-target/src/Program.cs (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-compile-target/src/helloworld.csproj (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-ilrepack/.gitignore (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-ilrepack/Dockerfile (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-ilrepack/src/.gitignore (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-ilrepack/src/Program.cs (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-ilrepack/src/dotnetapp.csproj (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-privateassets/.gitignore (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-privateassets/Dockerfile (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-privateassets/src/.gitignore (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-privateassets/src/Program.cs (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/image-net8-privateassets/src/dotnetapp.csproj (100%) rename syft/pkg/cataloger/dotnet/{test-fixtures => testdata}/packages.lock.json (100%) rename syft/pkg/cataloger/elixir/{test-fixtures => testdata}/glob-paths/src/mix.lock (100%) rename syft/pkg/cataloger/elixir/{test-fixtures => testdata}/mix.lock (100%) rename syft/pkg/cataloger/erlang/{test-fixtures => testdata}/corrupt/rabbitmq.app (100%) rename syft/pkg/cataloger/erlang/{test-fixtures => testdata}/corrupt/rebar.lock (100%) rename syft/pkg/cataloger/erlang/{test-fixtures => testdata}/glob-paths/src/rabbitmq.app (100%) rename syft/pkg/cataloger/erlang/{test-fixtures => testdata}/glob-paths/src/rebar.lock (100%) rename syft/pkg/cataloger/erlang/{test-fixtures => testdata}/rabbitmq.app (100%) rename syft/pkg/cataloger/erlang/{test-fixtures => testdata}/rebar-2.lock (100%) rename syft/pkg/cataloger/erlang/{test-fixtures => testdata}/rebar.lock (100%) delete mode 100644 syft/pkg/cataloger/generic/test-fixtures/a-path.txt delete mode 100644 syft/pkg/cataloger/generic/test-fixtures/another-path.txt delete mode 100644 syft/pkg/cataloger/generic/test-fixtures/last/path.txt create mode 100644 syft/pkg/cataloger/generic/testdata/a-path.txt create mode 100644 syft/pkg/cataloger/generic/testdata/another-path.txt rename syft/pkg/cataloger/generic/{test-fixtures => testdata}/empty.txt (100%) create mode 100644 syft/pkg/cataloger/generic/testdata/last/path.txt rename syft/pkg/cataloger/gentoo/{test-fixtures => testdata}/glob-paths/var/db/pkg/x/y/CONTENTS (100%) rename syft/pkg/cataloger/gentoo/{test-fixtures => testdata}/layout-license-groups/etc/portage/license_groups (100%) rename syft/pkg/cataloger/gentoo/{test-fixtures => testdata}/layout-license-groups/var/db/pkg/app-containers/skopeo-1.5.1/CONTENTS (100%) rename syft/pkg/cataloger/gentoo/{test-fixtures => testdata}/layout-license-groups/var/db/pkg/app-containers/skopeo-1.5.1/LICENSE (100%) rename syft/pkg/cataloger/gentoo/{test-fixtures => testdata}/layout-license-groups/var/db/pkg/app-containers/skopeo-1.5.1/SIZE (100%) rename syft/pkg/cataloger/gentoo/{test-fixtures => testdata}/layout/var/db/pkg/app-containers/skopeo-1.5.1/CONTENTS (100%) rename syft/pkg/cataloger/gentoo/{test-fixtures => testdata}/layout/var/db/pkg/app-containers/skopeo-1.5.1/LICENSE (100%) rename syft/pkg/cataloger/gentoo/{test-fixtures => testdata}/layout/var/db/pkg/app-containers/skopeo-1.5.1/SIZE (100%) rename syft/pkg/cataloger/gentoo/{test-fixtures => testdata}/license-groups/cycle (100%) rename syft/pkg/cataloger/gentoo/{test-fixtures => testdata}/license-groups/example1 (100%) rename syft/pkg/cataloger/gentoo/{test-fixtures => testdata}/license-groups/missing (100%) rename syft/pkg/cataloger/gentoo/{test-fixtures => testdata}/license-groups/self (100%) rename syft/pkg/cataloger/githubactions/{test-fixtures => testdata}/call-shared-workflow.yaml (100%) rename syft/pkg/cataloger/githubactions/{test-fixtures => testdata}/composite-action.yaml (100%) rename syft/pkg/cataloger/githubactions/{test-fixtures => testdata}/corrupt/composite-action.yaml (100%) rename syft/pkg/cataloger/githubactions/{test-fixtures => testdata}/corrupt/workflow-multi-job.yaml (100%) rename syft/pkg/cataloger/githubactions/{test-fixtures => testdata}/glob/.github/actions/bootstrap/action.yaml (100%) rename syft/pkg/cataloger/githubactions/{test-fixtures => testdata}/glob/.github/actions/unbootstrap/action.yml (100%) rename syft/pkg/cataloger/githubactions/{test-fixtures => testdata}/glob/.github/workflows/release.yml (100%) rename syft/pkg/cataloger/githubactions/{test-fixtures => testdata}/glob/.github/workflows/validations.yaml (100%) rename syft/pkg/cataloger/githubactions/{test-fixtures => testdata}/workflow-multi-job.yaml (100%) rename syft/pkg/cataloger/githubactions/{test-fixtures => testdata}/workflow-with-version-comments.yaml (100%) create mode 100644 syft/pkg/cataloger/golang/internal/gotestdata/README.md rename syft/pkg/cataloger/golang/{test-fixtures => internal/gotestdata}/go-source/cmd/bin1/main.go (100%) rename syft/pkg/cataloger/golang/{test-fixtures => internal/gotestdata}/go-source/cmd/bin2/main.go (100%) rename syft/pkg/cataloger/golang/{test-fixtures => internal/gotestdata}/go-source/go.mod (100%) rename syft/pkg/cataloger/golang/{test-fixtures => internal/gotestdata}/go-source/go.sum (100%) rename syft/pkg/cataloger/golang/{test-fixtures => internal/gotestdata}/go-source/pk1/pk1.go (100%) rename syft/pkg/cataloger/golang/{test-fixtures => internal/gotestdata}/go-source/pk1/pk1_test.go (100%) rename syft/pkg/cataloger/golang/{test-fixtures => internal/gotestdata}/go-source/pk2/pk2.go (100%) rename syft/pkg/cataloger/golang/{test-fixtures => internal/gotestdata}/go-source/pk3/pk3.go (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/Makefile (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/archs/.gitignore (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/archs/Makefile (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/archs/src/build.sh (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/archs/src/go.mod (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/archs/src/main.go (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/corrupt/go.mod (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/corrupt/go.sum (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/glob-paths/partial-binary (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/glob-paths/src/go.mod (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/go-mod-fixtures/many-packages/go.mod (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/go-mod-fixtures/one-package/go.mod (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/go-mod-fixtures/one-package/go.sum (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/go-mod-fixtures/relative-replace/go.mod (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/go-sum-hashes/go.mod (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/go-sum-hashes/go.sum (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/image-not-a-module/.gitignore (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/image-not-a-module/Dockerfile (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/image-not-a-module/go.mod (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/image-not-a-module/go.sum (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/image-not-a-module/main.go (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/image-small-upx/.gitignore (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/image-small-upx/Dockerfile (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/image-small-upx/go.mod (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/image-small-upx/go.sum (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/image-small-upx/main.go (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/image-small/.gitignore (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/image-small/Dockerfile (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/image-small/go.mod (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/image-small/go.sum (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/image-small/main.go (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/licenses-vendor/github.com/!cap!o!r!g/!cap!project/LICENSE.txt (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/licenses-vendor/github.com/someorg/somename/LICENSE (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/licenses-vendor/github.com/someorg/strangelicense/LiCeNsE.tXt (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/licenses/pkg/mod/github.com/!cap!o!r!g/!cap!project@v4.111.5/LICENSE.txt (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/licenses/pkg/mod/github.com/someorg/somename@v0.3.2/LICENSE (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/licenses/pkg/mod/github.com/someorg/strangelicense@v1.2.3/LiCeNsE.tXt (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/repo/LICENSE (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/zip-fs/github.com/someorg/somepkg@version/a-file (100%) rename syft/pkg/cataloger/golang/{test-fixtures => testdata}/zip-fs/github.com/someorg/somepkg@version/subdir/subfile (100%) rename syft/pkg/cataloger/haskell/{test-fixtures => testdata}/cabal.project.freeze (100%) rename syft/pkg/cataloger/haskell/{test-fixtures => testdata}/corrupt/stack.yaml (100%) rename syft/pkg/cataloger/haskell/{test-fixtures => testdata}/corrupt/stack.yaml.lock (100%) rename syft/pkg/cataloger/haskell/{test-fixtures => testdata}/glob-paths/src/cabal.project.freeze (100%) rename syft/pkg/cataloger/haskell/{test-fixtures => testdata}/glob-paths/src/stack.yaml (100%) rename syft/pkg/cataloger/haskell/{test-fixtures => testdata}/glob-paths/src/stack.yaml.lock (100%) rename syft/pkg/cataloger/haskell/{test-fixtures => testdata}/stack.yaml (100%) rename syft/pkg/cataloger/haskell/{test-fixtures => testdata}/stack.yaml.lock (100%) rename syft/pkg/cataloger/homebrew/{test-fixtures => testdata}/formulas/crazy/1.0.0/.brew/crazy.rb (100%) rename syft/pkg/cataloger/homebrew/{test-fixtures => testdata}/formulas/syft/1.23.1/.brew/syft.rb (100%) rename syft/pkg/cataloger/homebrew/{test-fixtures => testdata}/install-example/opt/homebrew/Cellar/foo/1.2.3/.brew/foo.rb (100%) rename syft/pkg/cataloger/homebrew/{test-fixtures => testdata}/install-example/opt/homebrew/Library/Taps/testorg/sometap/Formula/bar.rb (100%) rename syft/pkg/cataloger/internal/binutils/{test-fixtures => testdata}/subdir/some-binary (100%) rename syft/pkg/cataloger/internal/binutils/{test-fixtures => testdata}/version-parts.txt (100%) rename syft/pkg/cataloger/internal/binutils/{test-fixtures => testdata}/version.txt (100%) delete mode 120000 syft/pkg/cataloger/internal/pe/test-fixtures/image-net8-app delete mode 120000 syft/pkg/cataloger/internal/pe/test-fixtures/image-net8-app-single-file rename syft/pkg/cataloger/internal/pe/{test-fixtures => testdata}/Makefile (100%) rename syft/pkg/cataloger/internal/pe/{test-fixtures => testdata}/image-dotnet31-single-file/Dockerfile (100%) rename syft/pkg/cataloger/internal/pe/{test-fixtures => testdata}/image-dotnet31-single-file/src/Program.cs (100%) rename syft/pkg/cataloger/internal/pe/{test-fixtures => testdata}/image-dotnet31-single-file/src/hello.csproj (100%) rename syft/pkg/cataloger/internal/pe/{test-fixtures => testdata}/image-dotnet5-single-file/Dockerfile (100%) rename syft/pkg/cataloger/internal/pe/{test-fixtures => testdata}/image-dotnet5-single-file/src/Program.cs (100%) rename syft/pkg/cataloger/internal/pe/{test-fixtures => testdata}/image-dotnet5-single-file/src/hello.csproj (100%) rename syft/pkg/cataloger/internal/pe/{test-fixtures => testdata}/image-dotnet6-single-file/Dockerfile (100%) rename syft/pkg/cataloger/internal/pe/{test-fixtures => testdata}/image-dotnet6-single-file/src/Program.cs (100%) rename syft/pkg/cataloger/internal/pe/{test-fixtures => testdata}/image-dotnet6-single-file/src/hello.csproj (100%) create mode 120000 syft/pkg/cataloger/internal/pe/testdata/image-net8-app create mode 120000 syft/pkg/cataloger/internal/pe/testdata/image-net8-app-single-file rename syft/pkg/cataloger/internal/pe/{test-fixtures => testdata}/net8-app-single-file.deps.json (100%) rename syft/pkg/cataloger/java/internal/maven/{test-fixtures => testdata}/declared-iso-8859-encoded-pom.xml.base64 (100%) rename syft/pkg/cataloger/java/internal/maven/{test-fixtures => testdata}/local-repository-settings/.m2/settings.xml (100%) rename syft/pkg/cataloger/java/internal/maven/{test-fixtures => testdata}/local/child-1/pom.xml (100%) rename syft/pkg/cataloger/java/internal/maven/{test-fixtures => testdata}/local/child-2/pom.xml (100%) rename syft/pkg/cataloger/java/internal/maven/{test-fixtures => testdata}/local/child-3/pom.xml (100%) rename syft/pkg/cataloger/java/internal/maven/{test-fixtures => testdata}/local/circular-1/pom.xml (100%) rename syft/pkg/cataloger/java/internal/maven/{test-fixtures => testdata}/local/circular-2/pom.xml (100%) rename syft/pkg/cataloger/java/internal/maven/{test-fixtures => testdata}/local/contains-child-1/pom.xml (100%) rename syft/pkg/cataloger/java/internal/maven/{test-fixtures => testdata}/local/parent-1/pom.xml (100%) rename syft/pkg/cataloger/java/internal/maven/{test-fixtures => testdata}/local/parent-2/pom.xml (100%) rename syft/pkg/cataloger/java/internal/maven/{test-fixtures => testdata}/local/parent-3/pom.xml (100%) rename syft/pkg/cataloger/java/internal/maven/{test-fixtures => testdata}/maven-repo/my/org/child-one/1.3.6/child-one-1.3.6.pom (100%) rename syft/pkg/cataloger/java/internal/maven/{test-fixtures => testdata}/maven-repo/my/org/child-two/2.1.90/child-two-2.1.90.pom (100%) rename syft/pkg/cataloger/java/internal/maven/{test-fixtures => testdata}/maven-repo/my/org/circular/1.2.3/circular-1.2.3.pom (100%) rename syft/pkg/cataloger/java/internal/maven/{test-fixtures => testdata}/maven-repo/my/org/parent-one/3.11.0/parent-one-3.11.0.pom (100%) rename syft/pkg/cataloger/java/internal/maven/{test-fixtures => testdata}/maven-repo/my/org/parent-two/13.7.8/parent-two-13.7.8.pom (100%) rename syft/pkg/cataloger/java/internal/maven/{test-fixtures => testdata}/maven-repo/net/shibboleth/parent/7.11.2/parent-7.11.2.pom (100%) rename syft/pkg/cataloger/java/internal/maven/{test-fixtures => testdata}/maven-repo/org/apache/commons/commons-parent/54/commons-parent-54.pom (100%) rename syft/pkg/cataloger/java/internal/maven/{test-fixtures => testdata}/maven-repo/org/junit/junit-bom/5.9.0/junit-bom-5.9.0.pom (100%) rename syft/pkg/cataloger/java/internal/maven/{test-fixtures => testdata}/maven-repo/org/junit/junit-bom/5.9.1/junit-bom-5.9.1.pom (100%) rename syft/pkg/cataloger/java/internal/maven/{test-fixtures => testdata}/maven-repo/org/opensaml/opensaml-parent/3.4.6/opensaml-parent-3.4.6.pom (100%) rename syft/pkg/cataloger/java/internal/maven/{test-fixtures => testdata}/undeclared-iso-8859-encoded-pom.xml.base64 (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/Makefile (100%) create mode 100644 syft/pkg/cataloger/java/testdata/corrupt/.gitignore rename syft/pkg/cataloger/java/{test-fixtures => testdata}/corrupt/example.jar (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/corrupt/example.tar (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/corrupt/pom.xml (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/archives/.gitignore (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/archives/example.tar (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/archives/example.tar.br (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/archives/example.tar.bz (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/archives/example.tar.bz2 (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/archives/example.tar.gz (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/archives/example.tar.lz4 (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/archives/example.tar.sz (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/archives/example.tar.xz (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/archives/example.tar.zst (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/archives/example.tar.zstd (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/archives/example.tbr (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/archives/example.tbz (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/archives/example.tbz2 (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/archives/example.tgz (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/archives/example.tlz4 (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/archives/example.tsz (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/archives/example.txz (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/archives/example.tzst (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/archives/example.tzstd (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/archives/example.zip (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/java-archives/.gitignore (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/java-archives/example.ear (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/java-archives/example.far (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/java-archives/example.hpi (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/java-archives/example.jar (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/java-archives/example.jpi (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/java-archives/example.kar (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/java-archives/example.lpkg (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/java-archives/example.nar (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/java-archives/example.par (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/java-archives/example.rar (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/java-archives/example.sar (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/java-archives/example.war (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/glob-paths/src/pom.xml (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/graalvm-sbom/micronaut.json (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/gradle/.gitignore (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/gradle/build.gradle (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/gradle/gradle.lockfile (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/.gitignore (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/Makefile (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/README.md (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/api-all-2.0.0-sources/META-INF/MANIFEST.MF (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/api-all-2.0.0-sources/META-INF/maven/org.apache.directory.api/api-all/pom.properties (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/api-all-2.0.0-sources/META-INF/maven/org.apache.directory.api/api-all/pom.xml (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/api-all-2.0.0-sources/META-INF/maven/org.apache.directory.api/api-asn1-api/pom.properties (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/api-all-2.0.0-sources/META-INF/maven/org.apache.directory.api/api-asn1-api/pom.xml (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/com.fasterxml.jackson.core.jackson-core-2.15.2/META-INF/MANIFEST.MF (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/com.fasterxml.jackson.core.jackson-core-2.15.2/META-INF/maven/com.fasterxml.jackson.core/jackson-core/pom.xml (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/commons-lang3-3.12.0/META-INF/MANIFEST.MF (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/commons-lang3-3.12.0/META-INF/maven/org.apache.commons-lang3/pom.xml (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/jackson-core-2.15.2/META-INF/MANIFEST.MF (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/jackson-core-2.15.2/META-INF/maven/com.fasterxml.jackson.core/jackson-core/pom.xml (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/jenkins-plugins/gradle/2.11/META-INF/MANIFEST.MF (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/micronaut-aop-4.9.11/META-INF/MANIFEST.MF (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/micronaut-aop-4.9.11/META-INF/maven/io.micronaut/micronaut-aop/pom.xml (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/multiple-matching-2.11.5/META-INF/MANIFEST.MF (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-1/pom.properties (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-1/pom.xml (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-2/pom.properties (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-2/pom.xml (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-3/pom.properties (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-3/pom.xml (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/opensaml-core-3.4.6/META-INF/INDEX.LIST (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/opensaml-core-3.4.6/META-INF/MANIFEST.MF (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/opensaml-core-3.4.6/META-INF/maven/org.opensaml/opensaml-core/pom.properties (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/opensaml-core-3.4.6/META-INF/maven/org.opensaml/opensaml-core/pom.xml (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/org.multiple-thename/META-INF/MANIFEST.MF (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/org.multiple-thename/META-INF/maven/com.multiple/thename/pom.properties (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/org.multiple-thename/META-INF/maven/com.multiple/thename/pom.xml (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/org.multiple-thename/META-INF/maven/org.multiple/thename/pom.properties (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/org.multiple-thename/META-INF/maven/org.multiple/thename/pom.xml (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jar-metadata/spring-instrumentation-4.3.0-1.0/META-INF/MANIFEST.MF (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/.gitignore (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/Makefile (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/build-example-java-app-gradle.sh (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/build-example-java-app-maven.sh (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/build-example-java-app-native-image.sh (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/build-example-jenkins-plugin.sh (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/build-example-macho-binary.sh (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/build-example-sb-app-nestedjar.sh (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-java-app/.gitignore (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-java-app/build.gradle (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-java-app/gradle.lockfile (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-java-app/pom.xml (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-java-app/src/main/java/hello/Greeter.java (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-java-app/src/main/java/hello/HelloWorld.java (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-jenkins-plugin/pom.xml (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-jenkins-plugin/src/main/java/io/jenkins/plugins/sample/HelloWorldBuilder.java (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-jenkins-plugin/src/main/resources/index.jelly (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/config.jelly (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/config.properties (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/config_fr.properties (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/help-name.html (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/help-name_fr.html (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/help-useFrench.html (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/help-useFrench_fr.html (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/Messages.properties (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/Messages_fr.properties (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-sb-app/.gitignore (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-sb-app/pom.xml (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-sb-app/src/main/java/com/example/springboot/Application.java (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-sb-app/src/main/java/com/example/springboot/HelloController.java (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-sb-app/src/test/java/com/example/springboot/HelloControllerIT.java (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/java-builds/example-sb-app/src/test/java/com/example/springboot/HelloControllerTest.java (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jvm-installs/oracle-jdk-se-8/usr/lib/jvm/.gitignore (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jvm-installs/oracle-jdk-se-8/usr/lib/jvm/jdk-1.8-oracle-x64/bin/javac (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jvm-installs/oracle-jdk-se-8/usr/lib/jvm/jdk-1.8-oracle-x64/release (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jvm-installs/valid-post-jep223/jvm/openjdk/release (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/jvm-installs/valid-post-jep223/jvm/openjdk/sibling/child/file1.txt (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/manifest/continuation (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/manifest/extra-empty-lines (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/manifest/extra-info (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/manifest/leading-space (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/manifest/small (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/manifest/standard-info (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/manifest/version-with-date (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/pom/colon-delimited-with-equals.pom.properties (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/pom/colon-delimited.pom.properties (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/pom/commons-codec.pom.xml (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/pom/commons-text-1.10.0/pom.xml (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/pom/equals-delimited-with-colons.pom.properties (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/pom/example-java-app-maven/pom.xml (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/pom/extra.pom.properties (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/pom/neo4j-license-maven-plugin.pom.xml (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/pom/small.pom.properties (100%) rename syft/pkg/cataloger/java/{test-fixtures => testdata}/pom/transitive-top-level/pom.xml (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/corrupt/package-lock.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/corrupt/package.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/corrupt/pnpm-lock.yaml (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/glob-paths/src/package-lock.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/glob-paths/src/package.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/glob-paths/src/pnpm-lock.yaml (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/glob-paths/src/yarn.lock (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-json/package-all-author-fields.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-json/package-author-non-standard.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-json/package-authors-array.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-json/package-authors-objects.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-json/package-both-author-and-authors.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-json/package-contributors.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-json/package-license-object.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-json/package-license-objects.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-json/package-maintainers.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-json/package-malformed-license.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-json/package-nested-author.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-json/package-no-license.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-json/package-partial.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-json/package-private.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-json/package-repo-string.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-json/package.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-lock/alias-package-lock-1.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-lock/alias-package-lock-2.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-lock/array-license-package-lock.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-lock/node_modules/@actions/core/package.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-lock/node_modules/cowsay/package.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-lock/package-lock-2.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-lock/package-lock-3.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pkg-lock/package-lock.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pnpm-remote/pnpm-lock.yaml (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pnpm-remote/registry_response.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pnpm-v6/pnpm-lock.yaml (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pnpm-v9-snapshots/pnpm-lock.yaml (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pnpm-v9/pnpm-lock.yaml (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/pnpm/pnpm-lock.yaml (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/yarn-berry-dev-deps/package.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/yarn-berry-dev-deps/yarn.lock (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/yarn-berry/yarn.lock (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/yarn-dev-deps/package.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/yarn-dev-deps/yarn.lock (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/yarn-dups/yarn.lock (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/yarn-remote/registry_response.json (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/yarn-remote/yarn.lock (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/yarn-v1-deps/yarn.lock (100%) rename syft/pkg/cataloger/javascript/{test-fixtures => testdata}/yarn/yarn.lock (100%) rename syft/pkg/cataloger/kernel/{test-fixtures => testdata}/Makefile (100%) rename syft/pkg/cataloger/kernel/{test-fixtures => testdata}/image-kernel-and-modules/Dockerfile (100%) rename syft/pkg/cataloger/lua/{test-fixtures => testdata}/corrupt/bad-1.23.0-0.rockspec (100%) rename syft/pkg/cataloger/lua/{test-fixtures => testdata}/glob-paths/lua/package.rockspec (100%) rename syft/pkg/cataloger/lua/{test-fixtures => testdata}/rockspec/kong-3.7.0-0.rockspec (100%) rename syft/pkg/cataloger/lua/{test-fixtures => testdata}/rockspec/kong-pgmoon-1.16.2-1.rockspec (100%) rename syft/pkg/cataloger/lua/{test-fixtures => testdata}/rockspec/lpeg-1.0.2-1.rockspec (100%) rename syft/pkg/cataloger/lua/{test-fixtures => testdata}/rockspec/luasyslog-2.0.1-1.rockspec (100%) rename syft/pkg/cataloger/nix/{test-fixtures => testdata}/fixture-1/.gitignore (100%) rename syft/pkg/cataloger/nix/{test-fixtures => testdata}/fixture-1/nix/store/5av396z8xa13jg89g9jws145c0k26k2x-glibc-2.34-210.drv (100%) rename syft/pkg/cataloger/nix/{test-fixtures => testdata}/fixture-1/nix/store/h0cnbmfcn93xm5dg2x27ixhag1cwndga-glibc-2.34-210-bin/lib/glibc.so (100%) rename syft/pkg/cataloger/nix/{test-fixtures => testdata}/fixture-1/nix/store/h0cnbmfcn93xm5dg2x27ixhag1cwndga-glibc-2.34-210-bin/share/man/glibc.1 (100%) rename syft/pkg/cataloger/nix/{test-fixtures => testdata}/image-nixos-jq-pkg-db/Dockerfile (100%) rename syft/pkg/cataloger/nix/{test-fixtures => testdata}/image-nixos-jq-pkg-db/clean_db.sql (100%) rename syft/pkg/cataloger/nix/{test-fixtures => testdata}/image-nixos-jq-pkg-store/Dockerfile (100%) rename syft/pkg/cataloger/ocaml/{test-fixtures => testdata}/alcotest.opam (100%) rename syft/pkg/cataloger/ocaml/{test-fixtures => testdata}/glob-paths/opam/alcotest.opam (100%) rename syft/pkg/cataloger/ocaml/{test-fixtures => testdata}/glob-paths/opam/ocaml-base-compiler.4.14.0/opam (100%) rename syft/pkg/cataloger/ocaml/{test-fixtures => testdata}/ocaml-base-compiler.4.14.0/opam (100%) rename syft/pkg/cataloger/php/{test-fixtures => testdata}/composer.lock (100%) rename syft/pkg/cataloger/php/{test-fixtures => testdata}/glob-paths/php/.registry/.channel.pecl.php.net/memcached.reg (100%) rename syft/pkg/cataloger/php/{test-fixtures => testdata}/glob-paths/src/composer.lock (100%) rename syft/pkg/cataloger/php/{test-fixtures => testdata}/glob-paths/src/installed.json (100%) rename syft/pkg/cataloger/php/{test-fixtures => testdata}/image-apache/Dockerfile (100%) rename syft/pkg/cataloger/php/{test-fixtures => testdata}/image-extensions/Dockerfile (100%) rename syft/pkg/cataloger/php/{test-fixtures => testdata}/memcached-v5-format.reg (100%) rename syft/pkg/cataloger/php/{test-fixtures => testdata}/memcached-v6-format.reg (100%) rename syft/pkg/cataloger/php/{test-fixtures => testdata}/vendor/composer_1/installed.json (100%) rename syft/pkg/cataloger/php/{test-fixtures => testdata}/vendor/composer_2/installed.json (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/Python-2.7.egg-info (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/empty-1.0.0-py3.8.egg-info (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/glob-paths/site-packages/v.DIST-INFO/METADATA (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/glob-paths/site-packages/w.EGG-INFO/PKG-INFO (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/glob-paths/site-packages/x.dist-info/METADATA (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/glob-paths/site-packages/y.egg-info/PKG-INFO (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/glob-paths/site-packages/z.egg-info (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/glob-paths/src/1-requirements-dev.txt (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/glob-paths/src/Pipfile.lock (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/glob-paths/src/extra-requirements.txt (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/glob-paths/src/pdm.lock (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/glob-paths/src/poetry.lock (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/glob-paths/src/requirements-dev.txt (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/glob-paths/src/requirements.txt (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/glob-paths/src/setup.py (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/glob-paths/src/uv.lock (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/image-multi-site-package/Dockerfile (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/installed-files/installed-files.txt (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/pdm-lock-extras/pdm.lock (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/pdm-lock-separate-files/pdm.lock (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/pdm-lock/pdm.lock (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/pipfile-lock/Pipfile.lock (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/poetry/case-sensitivity/poetry.lock (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/poetry/conflicting-with-extras/poetry.lock (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/poetry/conflicting-with-extras/pyproject.toml (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/poetry/dev-deps/poetry.lock (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/poetry/multiple-extras/poetry.lock (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/poetry/multiple-extras/pyproject.toml (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/poetry/nested-extras/poetry.lock (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/poetry/nested-extras/pyproject.toml (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/poetry/simple-deps/poetry.lock (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/poetry/simple-deps/pyproject.toml (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/pyenv/good-config (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/pyenv/trixy-config (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/pypi-remote/Pipfile.lock (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/pypi-remote/pdm.lock (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/pypi-remote/poetry.lock (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/pypi-remote/pyproject.toml (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/pypi-remote/registry_response.json (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/pypi-remote/registry_response_bad.json (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/pypi-remote/requirements.txt (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/pypi-remote/setup.py (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/pypi-remote/uv.lock (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/requires/requirements.txt (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/setup/dynamic-setup.py (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/setup/mixed-format-setup.py (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/setup/multiline-split-setup.py (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/setup/setup.py (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/license/with-license-file-declared.dist-info/LICENSE.txt (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/license/with-license-file-declared.dist-info/METADATA (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/license/with-license-file-declared.dist-info/RECORD (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/license/with-license-file-declared.dist-info/direct_url.json (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/license/with-license-file-declared.dist-info/top_level.txt (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/license/without-license-file-declared.dist-info/LICENSE.txt (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/license/without-license-file-declared.dist-info/METADATA (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/license/without-license-file-declared.dist-info/RECORD (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/license/without-license-file-declared.dist-info/direct_url.json (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/license/without-license-file-declared.dist-info/top_level.txt (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/malformed-record/dist-info/METADATA (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/malformed-record/dist-info/RECORD (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/nested/dist-name/dist-info/LICENSE.txt (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/nested/dist-name/dist-info/METADATA (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/nested/dist-name/dist-info/RECORD (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/nested/dist-name/dist-info/direct_url.json (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/nested/dist-name/dist-info/top_level.txt (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/nested/egg-name/egg-info/PKG-INFO (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/nested/egg-name/egg-info/PKG-INFO-INVALID (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/nested/egg-name/egg-info/RECORD (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/nested/egg-name/egg-info/top_level.txt (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/no-version/no-version-py3.8.egg-info (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/partial.dist-info/METADATA (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/test/test.egg-info (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/uppercase/dist-name/DIST-INFO/METADATA (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/uppercase/dist-name/DIST-INFO/RECORD (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/uppercase/dist-name/DIST-INFO/direct_url.json (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/uppercase/dist-name/DIST-INFO/top_level.txt (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/uppercase/egg-name/EGG-INFO/PKG-INFO (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/uppercase/egg-name/EGG-INFO/PKG-INFO-INVALID (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/uppercase/egg-name/EGG-INFO/RECORD (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/site-packages/uppercase/egg-name/EGG-INFO/top_level.txt (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/uv/conflicting-with-extras/pyproject.toml (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/uv/conflicting-with-extras/uv.lock (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/uv/multiple-extras/pyproject.toml (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/uv/multiple-extras/uv.lock (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/uv/nested-extras/pyproject.toml (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/uv/nested-extras/uv.lock (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/uv/simple-deps/pyproject.toml (100%) rename syft/pkg/cataloger/python/{test-fixtures => testdata}/uv/simple-deps/uv.lock (100%) rename syft/pkg/cataloger/r/{test-fixtures => testdata}/DESCRIPTION (100%) rename syft/pkg/cataloger/r/{test-fixtures => testdata}/installed/base/DESCRIPTION (100%) rename syft/pkg/cataloger/r/{test-fixtures => testdata}/installed/stringr/DESCRIPTION (100%) rename syft/pkg/cataloger/r/{test-fixtures => testdata}/map-parse/bad (100%) rename syft/pkg/cataloger/r/{test-fixtures => testdata}/map-parse/eof-multiline (100%) rename syft/pkg/cataloger/r/{test-fixtures => testdata}/map-parse/multiline (100%) rename syft/pkg/cataloger/r/{test-fixtures => testdata}/map-parse/no-name (100%) rename syft/pkg/cataloger/r/{test-fixtures => testdata}/map-parse/no-version (100%) rename syft/pkg/cataloger/r/{test-fixtures => testdata}/map-parse/simple (100%) rename syft/pkg/cataloger/redhat/{test-fixtures => testdata}/.gitignore (100%) rename syft/pkg/cataloger/redhat/{test-fixtures => testdata}/Makefile (100%) rename syft/pkg/cataloger/redhat/{test-fixtures => testdata}/Packages (100%) rename syft/pkg/cataloger/redhat/{test-fixtures => testdata}/bad/bad.rpm (100%) rename syft/pkg/cataloger/redhat/{test-fixtures => testdata}/container-manifest-2 (100%) rename syft/pkg/cataloger/redhat/{test-fixtures => testdata}/generate-fixture.sh (100%) rename syft/pkg/cataloger/redhat/{test-fixtures => testdata}/glob-paths/dive-0.10.0.rpm (100%) rename syft/pkg/cataloger/redhat/{test-fixtures => testdata}/glob-paths/usr/lib/sysimage/rpm/Packages (100%) rename syft/pkg/cataloger/redhat/{test-fixtures => testdata}/glob-paths/usr/lib/sysimage/rpm/Packages.db (100%) rename syft/pkg/cataloger/redhat/{test-fixtures => testdata}/glob-paths/usr/lib/sysimage/rpm/rpmdb.sqlite (100%) rename syft/pkg/cataloger/redhat/{test-fixtures => testdata}/glob-paths/usr/share/rpm/Packages (100%) rename syft/pkg/cataloger/redhat/{test-fixtures => testdata}/glob-paths/usr/share/rpm/Packages.db (100%) rename syft/pkg/cataloger/redhat/{test-fixtures => testdata}/glob-paths/usr/share/rpm/rpmdb.sqlite (100%) rename syft/pkg/cataloger/redhat/{test-fixtures => testdata}/glob-paths/var/lib/rpm/Packages (100%) rename syft/pkg/cataloger/redhat/{test-fixtures => testdata}/glob-paths/var/lib/rpm/Packages.db (100%) rename syft/pkg/cataloger/redhat/{test-fixtures => testdata}/glob-paths/var/lib/rpm/rpmdb.sqlite (100%) rename syft/pkg/cataloger/redhat/{test-fixtures => testdata}/glob-paths/var/lib/rpmmanifest/container-manifest-2 (100%) rename syft/pkg/cataloger/redhat/{test-fixtures => testdata}/image-minimal/Dockerfile (100%) rename syft/pkg/cataloger/redhat/{test-fixtures => testdata}/image-minimal/remove.sh (100%) rename syft/pkg/cataloger/redhat/{test-fixtures => testdata}/image-rpm-archive/Dockerfile (100%) rename syft/pkg/cataloger/ruby/{test-fixtures => testdata}/Gemfile.lock (100%) rename syft/pkg/cataloger/ruby/{test-fixtures => testdata}/bundler.gemspec (100%) rename syft/pkg/cataloger/ruby/{test-fixtures => testdata}/glob-paths/specifications/pkg/nested.gemspec (100%) rename syft/pkg/cataloger/ruby/{test-fixtures => testdata}/glob-paths/specifications/root.gemspec (100%) rename syft/pkg/cataloger/ruby/{test-fixtures => testdata}/glob-paths/src/Gemfile.lock (100%) rename syft/pkg/cataloger/ruby/{test-fixtures => testdata}/glob-paths/src/Gemfile.next.lock (100%) rename syft/pkg/cataloger/rust/{test-fixtures => testdata}/Cargo.lock (100%) rename syft/pkg/cataloger/rust/{test-fixtures => testdata}/Cargo.lock-with-git-deps (100%) rename syft/pkg/cataloger/rust/{test-fixtures => testdata}/glob-paths/partial-binary (100%) rename syft/pkg/cataloger/rust/{test-fixtures => testdata}/glob-paths/src/Cargo.lock (100%) rename syft/pkg/cataloger/rust/{test-fixtures => testdata}/image-audit/Cargo.lock (100%) rename syft/pkg/cataloger/rust/{test-fixtures => testdata}/image-audit/Cargo.toml (100%) rename syft/pkg/cataloger/rust/{test-fixtures => testdata}/image-audit/Dockerfile (100%) rename syft/pkg/cataloger/rust/{test-fixtures => testdata}/image-audit/src/main.rs (100%) rename syft/pkg/cataloger/sbom/{test-fixtures => testdata}/alpine/syft-json/sbom.syft.json (100%) rename syft/pkg/cataloger/sbom/{test-fixtures => testdata}/glob-paths/app.bom (100%) rename syft/pkg/cataloger/sbom/{test-fixtures => testdata}/glob-paths/app.bom.json (100%) rename syft/pkg/cataloger/sbom/{test-fixtures => testdata}/glob-paths/app.cdx (100%) rename syft/pkg/cataloger/sbom/{test-fixtures => testdata}/glob-paths/app.cdx.json (100%) rename syft/pkg/cataloger/sbom/{test-fixtures => testdata}/glob-paths/app.sbom (100%) rename syft/pkg/cataloger/sbom/{test-fixtures => testdata}/glob-paths/app.sbom.json (100%) rename syft/pkg/cataloger/sbom/{test-fixtures => testdata}/glob-paths/app.spdx (100%) rename syft/pkg/cataloger/sbom/{test-fixtures => testdata}/glob-paths/app.spdx.json (100%) rename syft/pkg/cataloger/sbom/{test-fixtures => testdata}/glob-paths/app.syft.json (100%) rename syft/pkg/cataloger/sbom/{test-fixtures => testdata}/glob-paths/bom (100%) rename syft/pkg/cataloger/sbom/{test-fixtures => testdata}/glob-paths/sbom (100%) rename syft/pkg/cataloger/snap/{test-fixtures => testdata}/dpkg.yaml (100%) rename syft/pkg/cataloger/snap/{test-fixtures => testdata}/glob-paths/base/usr/share/snappy/dpkg.yaml (100%) rename syft/pkg/cataloger/snap/{test-fixtures => testdata}/glob-paths/system/snap/manifest.yaml (100%) rename syft/pkg/cataloger/snap/{test-fixtures => testdata}/manifest.yaml (100%) rename syft/pkg/cataloger/snap/{test-fixtures => testdata}/real-dpkg.yaml (100%) rename syft/pkg/cataloger/swift/{test-fixtures => testdata}/Package.resolved (100%) rename syft/pkg/cataloger/swift/{test-fixtures => testdata}/PackageV3.resolved (100%) rename syft/pkg/cataloger/swift/{test-fixtures => testdata}/Podfile.lock (100%) rename syft/pkg/cataloger/swift/{test-fixtures => testdata}/bad-version-packages.resolved (100%) rename syft/pkg/cataloger/swift/{test-fixtures => testdata}/empty-packages.resolved (100%) rename syft/pkg/cataloger/swift/{test-fixtures => testdata}/glob-paths/src/Podfile.lock (100%) rename syft/pkg/cataloger/swipl/{test-fixtures => testdata}/glob-paths/pack.pl (100%) rename syft/pkg/cataloger/swipl/{test-fixtures => testdata}/pack.pl (100%) rename syft/pkg/cataloger/terraform/{test-fixtures => testdata}/two-providers/.terraform.lock.hcl (100%) rename syft/pkg/cataloger/wordpress/{test-fixtures => testdata}/glob-paths/wp-admin/index.php (100%) rename syft/pkg/cataloger/wordpress/{test-fixtures => testdata}/glob-paths/wp-content/plugins/akismet/akismet.php (100%) rename syft/pkg/cataloger/wordpress/{test-fixtures => testdata}/glob-paths/wp-content/plugins/all-in-one-wp-migration/all-in-one-wp-migration.php (100%) rename syft/pkg/cataloger/wordpress/{test-fixtures => testdata}/glob-paths/wp-includes/index.php (100%) rename syft/source/{test-fixtures => testdata}/actual-path/empty (100%) rename syft/source/{test-fixtures => testdata}/file-index-filter/.1/something (100%) rename syft/source/{test-fixtures => testdata}/file-index-filter/.2 (100%) rename syft/source/{test-fixtures => testdata}/file-index-filter/.vimrc (100%) rename syft/source/{test-fixtures => testdata}/file-index-filter/empty (100%) rename syft/source/{test-fixtures => testdata}/generate-tar-fixture-from-source-dir.sh (100%) rename syft/source/{test-fixtures => testdata}/image-simple/Dockerfile (100%) rename syft/source/{test-fixtures => testdata}/image-simple/file-1.txt (100%) rename syft/source/{test-fixtures => testdata}/image-simple/file-2.txt (100%) rename syft/source/{test-fixtures => testdata}/image-simple/target/really/nested/file-3.txt (100%) rename syft/source/{test-fixtures => testdata}/path-detected-2/.vimrc (100%) rename syft/source/{test-fixtures => testdata}/path-detected-2/empty (100%) rename syft/source/{test-fixtures => testdata}/path-detected/.vimrc (100%) rename syft/source/{test-fixtures => testdata}/path-detected/empty (100%) rename syft/source/{test-fixtures => testdata}/symlink (100%) rename syft/source/{test-fixtures => testdata}/system_paths/outside_root/link_target/place (100%) rename syft/source/{test-fixtures => testdata}/system_paths/target/dev/place (100%) rename syft/source/{test-fixtures => testdata}/system_paths/target/home/place (100%) rename syft/source/{test-fixtures => testdata}/system_paths/target/link/a-symlink/place (100%) rename syft/source/{test-fixtures => testdata}/system_paths/target/proc/place (100%) rename syft/source/{test-fixtures => testdata}/system_paths/target/sys/place (100%) delete mode 120000 test/cli/test-fixtures/image-pkg-coverage create mode 100644 test/cli/testdata/.gitignore rename test/cli/{test-fixtures => testdata}/Makefile (100%) rename test/cli/{test-fixtures => testdata}/archive/dist-info/METADATA (100%) rename test/cli/{test-fixtures => testdata}/archive/dist-info/RECORD (100%) rename test/cli/{test-fixtures => testdata}/archive/dist-info/top_level.txt (100%) rename test/cli/{test-fixtures => testdata}/attestation/Dockerfile.ctfe_init (100%) rename test/cli/{test-fixtures => testdata}/attestation/config/config.json (100%) rename test/cli/{test-fixtures => testdata}/attestation/config/ctfe/ct_server.cfg (100%) rename test/cli/{test-fixtures => testdata}/attestation/config/ctfe/privkey.pem (100%) rename test/cli/{test-fixtures => testdata}/attestation/config/ctfe/pubkey.pem (100%) rename test/cli/{test-fixtures => testdata}/attestation/config/dex/docker-compose-config.yaml (100%) rename test/cli/{test-fixtures => testdata}/attestation/config/logid.sh (100%) rename test/cli/{test-fixtures => testdata}/attestation/docker-compose-config.yaml (100%) rename test/cli/{test-fixtures => testdata}/attestation/docker-compose.yaml (100%) rename test/cli/{test-fixtures => testdata}/configs/dir1/.syft.yaml (100%) rename test/cli/{test-fixtures => testdata}/configs/dir2/.syft.yaml (100%) rename test/cli/{test-fixtures => testdata}/csv.template (100%) rename test/cli/{test-fixtures => testdata}/image-bad-binaries/Dockerfile (100%) rename test/cli/{test-fixtures => testdata}/image-bad-binaries/sources.list (100%) rename test/cli/{test-fixtures => testdata}/image-hidden-packages/Dockerfile (100%) rename test/cli/{test-fixtures => testdata}/image-java-spdx-tools/Dockerfile (100%) rename test/cli/{test-fixtures => testdata}/image-java-spdx-tools/Makefile (100%) rename test/cli/{test-fixtures => testdata}/image-node-binary/Dockerfile (100%) create mode 120000 test/cli/testdata/image-pkg-coverage rename test/cli/{test-fixtures => testdata}/image-unknowns/Dockerfile (100%) rename test/cli/{test-fixtures => testdata}/image-unknowns/exe (100%) rename test/cli/{test-fixtures => testdata}/image-unknowns/executable-script (100%) rename test/cli/{test-fixtures => testdata}/image-unknowns/package-lock.json (100%) rename test/cli/{test-fixtures => testdata}/image-unknowns/unextracted.tar.gz (100%) rename test/cli/{test-fixtures => testdata}/image-unknowns/unextracted.zip (100%) rename test/cli/{test-fixtures => testdata}/image-unknowns/unknown-readable.jar (100%) rename test/cli/{test-fixtures => testdata}/image-unknowns/unknown-unreadable.jar (100%) rename test/cli/{test-fixtures => testdata}/registry/.dockerignore (100%) rename test/cli/{test-fixtures => testdata}/registry/Dockerfile (100%) rename test/cli/{test-fixtures => testdata}/registry/Makefile (100%) rename test/compare/{test-fixtures => testdata}/acceptance-centos-8.2.2004.json (100%) rename test/install/{test-fixtures => testdata}/assets/invalid/.gitignore (100%) rename test/install/{test-fixtures => testdata}/assets/invalid/checksums.txt (100%) rename test/install/{test-fixtures => testdata}/assets/invalid/syft_1.5.0_linux_arm64.tar.gz (100%) rename test/install/{test-fixtures => testdata}/assets/valid/.gitignore (100%) rename test/install/{test-fixtures => testdata}/assets/valid/checksums.txt (100%) rename test/install/{test-fixtures => testdata}/assets/valid/syft_1.5.0_linux_arm64.tar.gz (100%) rename test/install/{test-fixtures => testdata}/github-api-syft-v0.36.0-release.json (100%) rename test/install/{test-fixtures => testdata}/syft_0.35.1-SNAPSHOT-d461f63_checksums.txt (100%) rename test/install/{test-fixtures => testdata}/syft_0.36.0_checksums.txt (100%) diff --git a/.github/actions/bootstrap/action.yaml b/.github/actions/bootstrap/action.yaml index 333f59364..10d933da2 100644 --- a/.github/actions/bootstrap/action.yaml +++ b/.github/actions/bootstrap/action.yaml @@ -5,7 +5,7 @@ inputs: go-version: description: "Go version to install" required: true - default: "1.25.x" + default: "1.26.x" go-dependencies: description: "Download go dependencies" required: true diff --git a/.github/scripts/capability-drift-check.sh b/.github/scripts/capability-drift-check.sh index 446508492..3855e40c8 100755 --- a/.github/scripts/capability-drift-check.sh +++ b/.github/scripts/capability-drift-check.sh @@ -6,7 +6,7 @@ if [ "$(git status --porcelain | wc -l)" -ne "0" ]; then exit 1 fi -if ! make generate-capabilities; then +if ! make generate-capabilities REFRESH=false; then echo "Generating capability descriptions failed" exit 1 fi diff --git a/.github/scripts/fingerprint_docker_fixtures.py b/.github/scripts/fingerprint_docker_fixtures.py index 4a74420e0..acb14e6e2 100755 --- a/.github/scripts/fingerprint_docker_fixtures.py +++ b/.github/scripts/fingerprint_docker_fixtures.py @@ -33,9 +33,9 @@ def is_git_tracked_or_untracked(directory): 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): - if 'test-fixtures' in root: + if 'testdata' in root: image_dirs = [d for d in dirs if d.startswith('image-')] if image_dirs: yield os.path.realpath(root) diff --git a/.github/workflows/validations.yaml b/.github/workflows/validations.yaml index a2565d4a0..a793605d1 100644 --- a/.github/workflows/validations.yaml +++ b/.github/workflows/validations.yaml @@ -58,6 +58,9 @@ jobs: - name: Run unit tests run: make unit + - name: Check for capability drift + run: make check-capability-drift + Integration-Test: # Note: changing this job name requires making the same update in the .github/workflows/release.yaml pipeline name: "Integration tests" diff --git a/.gitignore b/.gitignore index b6c7119f6..7fafb7faf 100644 --- a/.gitignore +++ b/.gitignore @@ -37,6 +37,7 @@ VERSION coverage.txt *.log **/test-fixtures/test-observations.json +**/testdata/test-observations.json # probable archives .images diff --git a/Taskfile.yaml b/Taskfile.yaml index 3e5bbe993..f06270d58 100644 --- a/Taskfile.yaml +++ b/Taskfile.yaml @@ -8,7 +8,9 @@ vars: OWNER: anchore 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 TOOL_DIR: .tool @@ -73,7 +75,6 @@ tasks: - task: check-licenses - task: lint - task: check-json-schema-drift - - task: check-capability-drift - task: check-binary-fixture-size test: @@ -199,7 +200,7 @@ tasks: check-binary-fixture-size: desc: Ensure that the binary test fixtures are not too large 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 ################################# @@ -266,9 +267,9 @@ tasks: fingerprints: desc: Generate fingerprints for all non-docker test fixture 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: - - '**/test-fixtures/**/*.fingerprint' + - '**/testdata/**/*.fingerprint' - test/install/cache.fingerprint cmds: - | @@ -277,7 +278,7 @@ tasks: RESET='\033[0m' 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 # for debugging... #echo -e "${YELLOW}• calculating fingerprints in $dir... ${RESET}" @@ -370,7 +371,7 @@ tasks: build-fixtures: desc: Generate all non-docker test fixtures 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: - | # we want to stop on the first build error @@ -381,7 +382,7 @@ tasks: RESET='\033[0m' # 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 echo -e "${YELLOW}${BOLD}generating fixtures in $dir${RESET}" make -C "$dir" fixtures @@ -435,7 +436,7 @@ tasks: - "echo 'Docker daemon cache:'" - "docker images --format '{{`{{.ID}}`}} {{`{{.Repository}}`}}:{{`{{.Tag}}`}}' | grep stereoscope-fixture- | sort" - "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: desc: Ensure docker caches aren't using too much disk space @@ -469,7 +470,7 @@ tasks: - "cd test/install && make ci-test-mac" 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: deps: [tmpdir] @@ -537,11 +538,16 @@ tasks: deps: - tmpdir - fixtures + vars: + # set REFRESH=true to run package tests first and refresh test observations (default: true) + REFRESH: '{{ .REFRESH | default "true" }}' cmds: # remove all test observations prior to regenerating - task: clean-test-observations + if: '{{ eq .REFRESH "true" }}' # 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/..." - "gofmt -s -w ./internal/capabilities" # now that we have the latest capabilities, run completeness tests to ensure this is self-consistent @@ -639,6 +645,15 @@ tasks: ## 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: desc: Remove any snapshot builds cmds: @@ -648,7 +663,7 @@ tasks: clean-docker-cache: desc: Remove all docker cache tars and images from the daemon 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 clean-oras-cache: @@ -665,7 +680,7 @@ tasks: RESET='\033[0m' # 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 echo -e "${YELLOW}${BOLD}deleting ephemeral test fixtures in $dir${RESET}" (make -C "$dir" clean) @@ -675,6 +690,6 @@ tasks: - rm -f {{ .LAST_CACHE_PULL_FILE }} {{ .CACHE_PATHS_FILE }} 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: - - find . -type f -wholename "**/test-fixtures/test-observations.json" | xargs rm -f + - find . -type f -wholename "**/testdata/test-observations.json" | xargs rm -f diff --git a/cmd/syft/internal/clio_setup_config.go b/cmd/syft/internal/clio_setup_config.go index 060c89447..f2a665d12 100644 --- a/cmd/syft/internal/clio_setup_config.go +++ b/cmd/syft/internal/clio_setup_config.go @@ -49,7 +49,7 @@ func AppClioSetupConfig(id clio.Identification, out io.Writer) *clio.SetupConfig }, ). WithPostRuns(func(_ *clio.State, _ error) { - stereoscope.Cleanup() + stereoscope.Cleanup() //nolint:staticcheck // we don't have access to the image object here }) return clioCfg } diff --git a/cmd/syft/internal/commands/scan_test.go b/cmd/syft/internal/commands/scan_test.go index 63f22543f..73174d051 100644 --- a/cmd/syft/internal/commands/scan_test.go +++ b/cmd/syft/internal/commands/scan_test.go @@ -19,30 +19,30 @@ func Test_scanOptions_validateLegacyOptionsNotUsed(t *testing.T) { }, { 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", - 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"), }, { 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"), }, { 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"), }, { 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", - cfg: "test-fixtures/scan-configs/with-base-path.yaml", + cfg: "testdata/scan-configs/with-base-path.yaml", wantErr: assertErrorContains("source.base-path"), }, } diff --git a/cmd/syft/internal/commands/test-fixtures/scan-configs/no-legacy-options.yaml b/cmd/syft/internal/commands/testdata/scan-configs/no-legacy-options.yaml similarity index 100% rename from cmd/syft/internal/commands/test-fixtures/scan-configs/no-legacy-options.yaml rename to cmd/syft/internal/commands/testdata/scan-configs/no-legacy-options.yaml diff --git a/cmd/syft/internal/commands/test-fixtures/scan-configs/with-base-path.yaml b/cmd/syft/internal/commands/testdata/scan-configs/with-base-path.yaml similarity index 100% rename from cmd/syft/internal/commands/test-fixtures/scan-configs/with-base-path.yaml rename to cmd/syft/internal/commands/testdata/scan-configs/with-base-path.yaml diff --git a/cmd/syft/internal/commands/test-fixtures/scan-configs/with-default-pull-source.yaml b/cmd/syft/internal/commands/testdata/scan-configs/with-default-pull-source.yaml similarity index 100% rename from cmd/syft/internal/commands/test-fixtures/scan-configs/with-default-pull-source.yaml rename to cmd/syft/internal/commands/testdata/scan-configs/with-default-pull-source.yaml diff --git a/cmd/syft/internal/commands/test-fixtures/scan-configs/with-exclude-binary-overlap-by-ownership.yaml b/cmd/syft/internal/commands/testdata/scan-configs/with-exclude-binary-overlap-by-ownership.yaml similarity index 100% rename from cmd/syft/internal/commands/test-fixtures/scan-configs/with-exclude-binary-overlap-by-ownership.yaml rename to cmd/syft/internal/commands/testdata/scan-configs/with-exclude-binary-overlap-by-ownership.yaml diff --git a/cmd/syft/internal/commands/test-fixtures/scan-configs/with-file-section.yaml b/cmd/syft/internal/commands/testdata/scan-configs/with-file-section.yaml similarity index 100% rename from cmd/syft/internal/commands/test-fixtures/scan-configs/with-file-section.yaml rename to cmd/syft/internal/commands/testdata/scan-configs/with-file-section.yaml diff --git a/cmd/syft/internal/commands/test-fixtures/scan-configs/with-file-string.yaml b/cmd/syft/internal/commands/testdata/scan-configs/with-file-string.yaml similarity index 100% rename from cmd/syft/internal/commands/test-fixtures/scan-configs/with-file-string.yaml rename to cmd/syft/internal/commands/testdata/scan-configs/with-file-string.yaml diff --git a/cmd/syft/internal/test/integration/catalog_packages_test.go b/cmd/syft/internal/test/integration/catalog_packages_test.go index 8e089c20c..21948340e 100644 --- a/cmd/syft/internal/test/integration/catalog_packages_test.go +++ b/cmd/syft/internal/test/integration/catalog_packages_test.go @@ -125,7 +125,7 @@ func TestPkgCoverageImage(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() definedLanguages := strset.New() @@ -261,7 +261,7 @@ func TestPkgCoverageImage_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 cases = append(cases, commonTestCases...) diff --git a/cmd/syft/internal/test/integration/files_test.go b/cmd/syft/internal/test/integration/files_test.go index 6794eed08..29d90eba0 100644 --- a/cmd/syft/internal/test/integration/files_test.go +++ b/cmd/syft/internal/test/integration/files_test.go @@ -22,7 +22,7 @@ import ( func TestFileCataloging_Default(t *testing.T) { cfg := options.DefaultCatalog().ToSBOMConfig(clio.Identification{}) 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 @@ -48,13 +48,13 @@ func TestFileCataloging_AllFiles(t *testing.T) { SkipFilesAboveSize: 30, }, }) - sbom, _ := catalogDirectoryWithConfig(t, "test-fixtures/files", cfg) + sbom, _ := catalogDirectoryWithConfig(t, "testdata/files", cfg) pwd, err := os.Getwd() require.NoError(t, err) 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{ diff --git a/cmd/syft/internal/test/integration/node_packages_test.go b/cmd/syft/internal/test/integration/node_packages_test.go index 305ff7ca0..7c085abbd 100644 --- a/cmd/syft/internal/test/integration/node_packages_test.go +++ b/cmd/syft/internal/test/integration/node_packages_test.go @@ -11,7 +11,7 @@ import ( ) func TestNpmPackageLockDirectory(t *testing.T) { - sbom, _ := catalogDirectory(t, "test-fixtures/npm-lock") + sbom, _ := catalogDirectory(t, "testdata/npm-lock") foundPackages := strset.New() @@ -32,7 +32,7 @@ func TestNpmPackageLockDirectory(t *testing.T) { } func TestYarnPackageLockDirectory(t *testing.T) { - sbom, _ := catalogDirectory(t, "test-fixtures/yarn-lock") + sbom, _ := catalogDirectory(t, "testdata/yarn-lock") foundPackages := strset.New() // merge-objects and should-type are devDependencies in package.json and are excluded by default diff --git a/cmd/syft/internal/test/integration/package_binary_elf_relationships_test.go b/cmd/syft/internal/test/integration/package_binary_elf_relationships_test.go index a76a30e1e..284265eec 100644 --- a/cmd/syft/internal/test/integration/package_binary_elf_relationships_test.go +++ b/cmd/syft/internal/test/integration/package_binary_elf_relationships_test.go @@ -26,7 +26,7 @@ func TestBinaryElfRelationships(t *testing.T) { } // 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 nameToId := map[string]artifact.ID{} diff --git a/cmd/syft/internal/test/integration/package_cataloger_convention_test.go b/cmd/syft/internal/test/integration/package_cataloger_convention_test.go index 4040dbf68..7b425c470 100644 --- a/cmd/syft/internal/test/integration/package_cataloger_convention_test.go +++ b/cmd/syft/internal/test/integration/package_cataloger_convention_test.go @@ -278,7 +278,7 @@ func packageCatalogerExports(t *testing.T) map[string]exportTokenSet { if info.IsDir() || !strings.HasSuffix(info.Name(), ".go") || strings.HasSuffix(info.Name(), "_test.go") || - strings.Contains(path, "test-fixtures") || + strings.Contains(path, "testdata") || strings.Contains(path, "internal") { return nil } diff --git a/cmd/syft/internal/test/integration/test-fixtures/elf-test-fixtures b/cmd/syft/internal/test/integration/test-fixtures/elf-test-fixtures deleted file mode 120000 index 0f836c1a4..000000000 --- a/cmd/syft/internal/test/integration/test-fixtures/elf-test-fixtures +++ /dev/null @@ -1 +0,0 @@ -../../../../../../syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures \ No newline at end of file diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/java/generate-fixtures.md b/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/java/generate-fixtures.md deleted file mode 100644 index 249a21023..000000000 --- a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/java/generate-fixtures.md +++ /dev/null @@ -1 +0,0 @@ -See the syft/cataloger/java/test-fixtures/java-builds dir to generate test fixtures and copy to here manually. \ No newline at end of file diff --git a/cmd/syft/internal/test/integration/test-fixtures/.gitignore b/cmd/syft/internal/test/integration/testdata/.gitignore similarity index 82% rename from cmd/syft/internal/test/integration/test-fixtures/.gitignore rename to cmd/syft/internal/test/integration/testdata/.gitignore index ea642e713..48c7e0961 100644 --- a/cmd/syft/internal/test/integration/test-fixtures/.gitignore +++ b/cmd/syft/internal/test/integration/testdata/.gitignore @@ -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. -# 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 # 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. diff --git a/cmd/syft/internal/test/integration/test-fixtures/Makefile b/cmd/syft/internal/test/integration/testdata/Makefile similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/Makefile rename to cmd/syft/internal/test/integration/testdata/Makefile diff --git a/cmd/syft/internal/test/integration/testdata/elf-testdata b/cmd/syft/internal/test/integration/testdata/elf-testdata new file mode 120000 index 000000000..734eb31a2 --- /dev/null +++ b/cmd/syft/internal/test/integration/testdata/elf-testdata @@ -0,0 +1 @@ +../../../../../../syft/pkg/cataloger/binary/testdata/elf-testdata \ No newline at end of file diff --git a/cmd/syft/internal/test/integration/test-fixtures/files/somewhere/there/is/a-small-file b/cmd/syft/internal/test/integration/testdata/files/somewhere/there/is/a-small-file similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/files/somewhere/there/is/a-small-file rename to cmd/syft/internal/test/integration/testdata/files/somewhere/there/is/a-small-file diff --git a/cmd/syft/internal/test/integration/test-fixtures/files/somewhere/there/is/a-symlink-to-a-small-file b/cmd/syft/internal/test/integration/testdata/files/somewhere/there/is/a-symlink-to-a-small-file similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/files/somewhere/there/is/a-symlink-to-a-small-file rename to cmd/syft/internal/test/integration/testdata/files/somewhere/there/is/a-symlink-to-a-small-file diff --git a/cmd/syft/internal/test/integration/test-fixtures/files/somewhere/there/is/a-symlink-to-file b/cmd/syft/internal/test/integration/testdata/files/somewhere/there/is/a-symlink-to-file similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/files/somewhere/there/is/a-symlink-to-file rename to cmd/syft/internal/test/integration/testdata/files/somewhere/there/is/a-symlink-to-file diff --git a/cmd/syft/internal/test/integration/test-fixtures/files/somewhere/there/is/a/file b/cmd/syft/internal/test/integration/testdata/files/somewhere/there/is/a/file similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/files/somewhere/there/is/a/file rename to cmd/syft/internal/test/integration/testdata/files/somewhere/there/is/a/file diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-distro-id/Dockerfile b/cmd/syft/internal/test/integration/testdata/image-distro-id/Dockerfile similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-distro-id/Dockerfile rename to cmd/syft/internal/test/integration/testdata/image-distro-id/Dockerfile diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-go-bin-arch-coverage/Dockerfile b/cmd/syft/internal/test/integration/testdata/image-go-bin-arch-coverage/Dockerfile similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-go-bin-arch-coverage/Dockerfile rename to cmd/syft/internal/test/integration/testdata/image-go-bin-arch-coverage/Dockerfile diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-go-bin-arch-coverage/app.go b/cmd/syft/internal/test/integration/testdata/image-go-bin-arch-coverage/app.go similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-go-bin-arch-coverage/app.go rename to cmd/syft/internal/test/integration/testdata/image-go-bin-arch-coverage/app.go diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-go-bin-arch-coverage/go.mod b/cmd/syft/internal/test/integration/testdata/image-go-bin-arch-coverage/go.mod similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-go-bin-arch-coverage/go.mod rename to cmd/syft/internal/test/integration/testdata/image-go-bin-arch-coverage/go.mod diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-go-bin-arch-coverage/go.sum b/cmd/syft/internal/test/integration/testdata/image-go-bin-arch-coverage/go.sum similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-go-bin-arch-coverage/go.sum rename to cmd/syft/internal/test/integration/testdata/image-go-bin-arch-coverage/go.sum diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-go-bin-arch-coverage/test b/cmd/syft/internal/test/integration/testdata/image-go-bin-arch-coverage/test similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-go-bin-arch-coverage/test rename to cmd/syft/internal/test/integration/testdata/image-go-bin-arch-coverage/test diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-golang-compiler/Dockerfile b/cmd/syft/internal/test/integration/testdata/image-golang-compiler/Dockerfile similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-golang-compiler/Dockerfile rename to cmd/syft/internal/test/integration/testdata/image-golang-compiler/Dockerfile diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-java-no-main-package/Dockerfile b/cmd/syft/internal/test/integration/testdata/image-java-no-main-package/Dockerfile similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-java-no-main-package/Dockerfile rename to cmd/syft/internal/test/integration/testdata/image-java-no-main-package/Dockerfile diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-java-virtualpath-regression/Dockerfile b/cmd/syft/internal/test/integration/testdata/image-java-virtualpath-regression/Dockerfile similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-java-virtualpath-regression/Dockerfile rename to cmd/syft/internal/test/integration/testdata/image-java-virtualpath-regression/Dockerfile diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-java-virtualpath-regression/extract.py b/cmd/syft/internal/test/integration/testdata/image-java-virtualpath-regression/extract.py similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-java-virtualpath-regression/extract.py rename to cmd/syft/internal/test/integration/testdata/image-java-virtualpath-regression/extract.py diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-large-apk-data/Dockerfile b/cmd/syft/internal/test/integration/testdata/image-large-apk-data/Dockerfile similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-large-apk-data/Dockerfile rename to cmd/syft/internal/test/integration/testdata/image-large-apk-data/Dockerfile diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-mariner-distroless/Dockerfile b/cmd/syft/internal/test/integration/testdata/image-mariner-distroless/Dockerfile similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-mariner-distroless/Dockerfile rename to cmd/syft/internal/test/integration/testdata/image-mariner-distroless/Dockerfile diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-os-binary-overlap/Dockerfile b/cmd/syft/internal/test/integration/testdata/image-os-binary-overlap/Dockerfile similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-os-binary-overlap/Dockerfile rename to cmd/syft/internal/test/integration/testdata/image-os-binary-overlap/Dockerfile diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-owning-package/Dockerfile b/cmd/syft/internal/test/integration/testdata/image-owning-package/Dockerfile similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-owning-package/Dockerfile rename to cmd/syft/internal/test/integration/testdata/image-owning-package/Dockerfile diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-photon-all-layers/Dockerfile b/cmd/syft/internal/test/integration/testdata/image-photon-all-layers/Dockerfile similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-photon-all-layers/Dockerfile rename to cmd/syft/internal/test/integration/testdata/image-photon-all-layers/Dockerfile diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/Dockerfile b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/Dockerfile similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/Dockerfile rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/Dockerfile diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/cocoapods/Podfile.lock b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/cocoapods/Podfile.lock similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/cocoapods/Podfile.lock rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/cocoapods/Podfile.lock diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/composer/composer.lock b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/composer/composer.lock similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/composer/composer.lock rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/composer/composer.lock diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/conan/conanfile.txt b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/conan/conanfile.txt similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/conan/conanfile.txt rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/conan/conanfile.txt diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/etc/os-release b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/etc/os-release similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/etc/os-release rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/etc/os-release diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/hackage/cabal.project.freeze b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/hackage/cabal.project.freeze similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/hackage/cabal.project.freeze rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/hackage/cabal.project.freeze diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/hackage/stack.yaml b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/hackage/stack.yaml similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/hackage/stack.yaml rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/hackage/stack.yaml diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/hackage/stack.yaml.lock b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/hackage/stack.yaml.lock similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/hackage/stack.yaml.lock rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/hackage/stack.yaml.lock diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/lib/apk/db/installed b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/lib/apk/db/installed similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/lib/apk/db/installed rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/lib/apk/db/installed diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/dart/pubspec.lock b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/dart/pubspec.lock similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/dart/pubspec.lock rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/dart/pubspec.lock diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/dotnet/TestLibrary.deps.json b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/dotnet/TestLibrary.deps.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/dotnet/TestLibrary.deps.json rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/dotnet/TestLibrary.deps.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/elixir/mix.lock b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/elixir/mix.lock similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/elixir/mix.lock rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/elixir/mix.lock diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/erlang/accept.app b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/erlang/accept.app similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/erlang/accept.app rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/erlang/accept.app diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/erlang/rebar.lock b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/erlang/rebar.lock similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/erlang/rebar.lock rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/erlang/rebar.lock diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/github-actions/.github/workflows/validations.yaml b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/github-actions/.github/workflows/validations.yaml similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/github-actions/.github/workflows/validations.yaml rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/github-actions/.github/workflows/validations.yaml diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/go/go.mod b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/go/go.mod similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/go/go.mod rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/go/go.mod diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/homebrew/Cellar/afflib/1.2.3/.brew/afflib.rb b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/homebrew/Cellar/afflib/1.2.3/.brew/afflib.rb similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/homebrew/Cellar/afflib/1.2.3/.brew/afflib.rb rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/homebrew/Cellar/afflib/1.2.3/.brew/afflib.rb diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/java/example-java-app-maven-0.1.0.jar b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/java/example-java-app-maven-0.1.0.jar similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/java/example-java-app-maven-0.1.0.jar rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/java/example-java-app-maven-0.1.0.jar diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/java/example-jenkins-plugin.hpi b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/java/example-jenkins-plugin.hpi similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/java/example-jenkins-plugin.hpi rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/java/example-jenkins-plugin.hpi diff --git a/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/java/generate-fixtures.md b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/java/generate-fixtures.md new file mode 100644 index 000000000..b42cec142 --- /dev/null +++ b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/java/generate-fixtures.md @@ -0,0 +1 @@ +See the syft/cataloger/java/testdata/java-builds dir to generate test fixtures and copy to here manually. \ No newline at end of file diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/java/pom.xml b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/java/pom.xml similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/java/pom.xml rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/java/pom.xml diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/javascript/package-json/package.json b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/javascript/package-json/package.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/javascript/package-json/package.json rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/javascript/package-json/package.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/javascript/package-lock/package-lock.json b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/javascript/package-lock/package-lock.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/javascript/package-lock/package-lock.json rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/javascript/package-lock/package-lock.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/javascript/yarn/yarn.lock b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/javascript/yarn/yarn.lock similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/javascript/yarn/yarn.lock rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/javascript/yarn/yarn.lock diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/lib/apk/db/installed b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/lib/apk/db/installed similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/lib/apk/db/installed rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/lib/apk/db/installed diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/nix/store/h0cnbmfcn93xm5dg2x27ixhag1cwndga-glibc-2.34-210-bin/share/man/glibc.1 b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/nix/store/h0cnbmfcn93xm5dg2x27ixhag1cwndga-glibc-2.34-210-bin/share/man/glibc.1 similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/nix/store/h0cnbmfcn93xm5dg2x27ixhag1cwndga-glibc-2.34-210-bin/share/man/glibc.1 rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/nix/store/h0cnbmfcn93xm5dg2x27ixhag1cwndga-glibc-2.34-210-bin/share/man/glibc.1 diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/opam/ocaml-base-compiler.4.14.0/opam b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/opam/ocaml-base-compiler.4.14.0/opam similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/opam/ocaml-base-compiler.4.14.0/opam rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/opam/ocaml-base-compiler.4.14.0/opam diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/php/.registry/.channel.pecl.php.net/memcached.reg b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/php/.registry/.channel.pecl.php.net/memcached.reg similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/php/.registry/.channel.pecl.php.net/memcached.reg rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/php/.registry/.channel.pecl.php.net/memcached.reg diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/php/vendor/composer/installed.json b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/php/vendor/composer/installed.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/php/vendor/composer/installed.json rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/php/vendor/composer/installed.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/dist-info/METADATA b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/dist-info/METADATA similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/dist-info/METADATA rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/dist-info/METADATA diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/dist-info/RECORD b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/dist-info/RECORD similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/dist-info/RECORD rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/dist-info/RECORD diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/dist-info/top_level.txt b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/dist-info/top_level.txt similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/dist-info/top_level.txt rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/dist-info/top_level.txt diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/egg-info/PKG-INFO b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/egg-info/PKG-INFO similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/egg-info/PKG-INFO rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/egg-info/PKG-INFO diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/egg-info/top_level.txt b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/egg-info/top_level.txt similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/egg-info/top_level.txt rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/egg-info/top_level.txt diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/requires/requirements-dev.txt b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/requires/requirements-dev.txt similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/requires/requirements-dev.txt rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/requires/requirements-dev.txt diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/requires/requirements.txt b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/requires/requirements.txt similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/requires/requirements.txt rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/requires/requirements.txt diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/requires/test-requirements.txt b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/requires/test-requirements.txt similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/requires/test-requirements.txt rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/requires/test-requirements.txt diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/setup/setup.py b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/setup/setup.py similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/setup/setup.py rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/setup/setup.py diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/someotherpkg-3.19.0-py3.8.egg-info/PKG-INFO b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/someotherpkg-3.19.0-py3.8.egg-info/PKG-INFO similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/someotherpkg-3.19.0-py3.8.egg-info/PKG-INFO rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/someotherpkg-3.19.0-py3.8.egg-info/PKG-INFO diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/someotherpkg-3.19.0-py3.8.egg-info/top_level.txt b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/someotherpkg-3.19.0-py3.8.egg-info/top_level.txt similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/someotherpkg-3.19.0-py3.8.egg-info/top_level.txt rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/someotherpkg-3.19.0-py3.8.egg-info/top_level.txt diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/somerequests-3.22.0.dist-info/METADATA b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/somerequests-3.22.0.dist-info/METADATA similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/somerequests-3.22.0.dist-info/METADATA rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/somerequests-3.22.0.dist-info/METADATA diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/somerequests-3.22.0.dist-info/top_level.txt b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/somerequests-3.22.0.dist-info/top_level.txt similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/python/somerequests-3.22.0.dist-info/top_level.txt rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/python/somerequests-3.22.0.dist-info/top_level.txt diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/r/base/DESCRIPTION b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/r/base/DESCRIPTION similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/r/base/DESCRIPTION rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/r/base/DESCRIPTION diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/rockspec/kong-3.7.0-0.rockspec b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/rockspec/kong-3.7.0-0.rockspec similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/rockspec/kong-3.7.0-0.rockspec rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/rockspec/kong-3.7.0-0.rockspec diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/ruby/Gemfile.lock b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/ruby/Gemfile.lock similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/ruby/Gemfile.lock rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/ruby/Gemfile.lock diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/ruby/specifications/bundler.gemspec b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/ruby/specifications/bundler.gemspec similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/ruby/specifications/bundler.gemspec rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/ruby/specifications/bundler.gemspec diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/ruby/specifications/default/unbundler.gemspec b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/ruby/specifications/default/unbundler.gemspec similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/ruby/specifications/default/unbundler.gemspec rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/ruby/specifications/default/unbundler.gemspec diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/rust/Cargo.lock b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/rust/Cargo.lock similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/rust/Cargo.lock rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/rust/Cargo.lock diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/db/pkg/app-containers/skopeo-1.5.1/CONTENTS b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/db/pkg/app-containers/skopeo-1.5.1/CONTENTS similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/db/pkg/app-containers/skopeo-1.5.1/CONTENTS rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/db/pkg/app-containers/skopeo-1.5.1/CONTENTS diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/db/pkg/app-containers/skopeo-1.5.1/LICENSE b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/db/pkg/app-containers/skopeo-1.5.1/LICENSE similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/db/pkg/app-containers/skopeo-1.5.1/LICENSE rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/db/pkg/app-containers/skopeo-1.5.1/LICENSE diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/db/pkg/app-containers/skopeo-1.5.1/SIZE b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/db/pkg/app-containers/skopeo-1.5.1/SIZE similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/db/pkg/app-containers/skopeo-1.5.1/SIZE rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/db/pkg/app-containers/skopeo-1.5.1/SIZE diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/lib/dpkg/status b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/lib/dpkg/status similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/lib/dpkg/status rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/lib/dpkg/status diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/lib/dpkg/status.d/dash b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/lib/dpkg/status.d/dash similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/lib/dpkg/status.d/dash rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/lib/dpkg/status.d/dash diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/lib/dpkg/status.d/netbase b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/lib/dpkg/status.d/netbase similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/lib/dpkg/status.d/netbase rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/lib/dpkg/status.d/netbase diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/lib/pacman/local/ALPM_DB_VERSION b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/lib/pacman/local/ALPM_DB_VERSION similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/lib/pacman/local/ALPM_DB_VERSION rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/lib/pacman/local/ALPM_DB_VERSION diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/lib/pacman/local/pacman-6.0.1-5/desc b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/lib/pacman/local/pacman-6.0.1-5/desc similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/lib/pacman/local/pacman-6.0.1-5/desc rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/lib/pacman/local/pacman-6.0.1-5/desc diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/lib/pacman/local/pacman-6.0.1-5/files b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/lib/pacman/local/pacman-6.0.1-5/files similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/lib/pacman/local/pacman-6.0.1-5/files rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/lib/pacman/local/pacman-6.0.1-5/files diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/lib/pacman/local/pacman-6.0.1-5/mtree b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/lib/pacman/local/pacman-6.0.1-5/mtree similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/lib/pacman/local/pacman-6.0.1-5/mtree rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/lib/pacman/local/pacman-6.0.1-5/mtree diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/lib/rpm/Packages b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/lib/rpm/Packages similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/lib/rpm/Packages rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/lib/rpm/Packages diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/lib/rpm/generate-fixture.sh b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/lib/rpm/generate-fixture.sh similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/var/lib/rpm/generate-fixture.sh rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/var/lib/rpm/generate-fixture.sh diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/wordpress/wp-content/plugins/akismet/akismet.php b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/wordpress/wp-content/plugins/akismet/akismet.php similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/pkgs/wordpress/wp-content/plugins/akismet/akismet.php rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/pkgs/wordpress/wp-content/plugins/akismet/akismet.php diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/swift/Package.resolved b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/swift/Package.resolved similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/swift/Package.resolved rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/swift/Package.resolved diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/swipl/pack/hdt/pack.pl b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/swipl/pack/hdt/pack.pl similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/swipl/pack/hdt/pack.pl rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/swipl/pack/hdt/pack.pl diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/terraform/.terraform.lock.hcl b/cmd/syft/internal/test/integration/testdata/image-pkg-coverage/terraform/.terraform.lock.hcl similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage/terraform/.terraform.lock.hcl rename to cmd/syft/internal/test/integration/testdata/image-pkg-coverage/terraform/.terraform.lock.hcl diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-rust-auditable/Dockerfile b/cmd/syft/internal/test/integration/testdata/image-rust-auditable/Dockerfile similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-rust-auditable/Dockerfile rename to cmd/syft/internal/test/integration/testdata/image-rust-auditable/Dockerfile diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-sbom-cataloger/Dockerfile b/cmd/syft/internal/test/integration/testdata/image-sbom-cataloger/Dockerfile similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-sbom-cataloger/Dockerfile rename to cmd/syft/internal/test/integration/testdata/image-sbom-cataloger/Dockerfile diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-sbom-cataloger/go.mod b/cmd/syft/internal/test/integration/testdata/image-sbom-cataloger/go.mod similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-sbom-cataloger/go.mod rename to cmd/syft/internal/test/integration/testdata/image-sbom-cataloger/go.mod diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-sbom-cataloger/test.spdx.json b/cmd/syft/internal/test/integration/testdata/image-sbom-cataloger/test.spdx.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-sbom-cataloger/test.spdx.json rename to cmd/syft/internal/test/integration/testdata/image-sbom-cataloger/test.spdx.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-sbom-metadata-component/Dockerfile b/cmd/syft/internal/test/integration/testdata/image-sbom-metadata-component/Dockerfile similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-sbom-metadata-component/Dockerfile rename to cmd/syft/internal/test/integration/testdata/image-sbom-metadata-component/Dockerfile diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-sbom-metadata-component/test.cdx.json b/cmd/syft/internal/test/integration/testdata/image-sbom-metadata-component/test.cdx.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-sbom-metadata-component/test.cdx.json rename to cmd/syft/internal/test/integration/testdata/image-sbom-metadata-component/test.cdx.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-sqlite-rpmdb/Dockerfile b/cmd/syft/internal/test/integration/testdata/image-sqlite-rpmdb/Dockerfile similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-sqlite-rpmdb/Dockerfile rename to cmd/syft/internal/test/integration/testdata/image-sqlite-rpmdb/Dockerfile diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-suse-all-layers/Dockerfile b/cmd/syft/internal/test/integration/testdata/image-suse-all-layers/Dockerfile similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-suse-all-layers/Dockerfile rename to cmd/syft/internal/test/integration/testdata/image-suse-all-layers/Dockerfile diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-test-java-purls/Dockerfile b/cmd/syft/internal/test/integration/testdata/image-test-java-purls/Dockerfile similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-test-java-purls/Dockerfile rename to cmd/syft/internal/test/integration/testdata/image-test-java-purls/Dockerfile diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-test-java-purls/extract.py b/cmd/syft/internal/test/integration/testdata/image-test-java-purls/extract.py similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-test-java-purls/extract.py rename to cmd/syft/internal/test/integration/testdata/image-test-java-purls/extract.py diff --git a/cmd/syft/internal/test/integration/test-fixtures/image-vertical-package-dups/Dockerfile b/cmd/syft/internal/test/integration/testdata/image-vertical-package-dups/Dockerfile similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/image-vertical-package-dups/Dockerfile rename to cmd/syft/internal/test/integration/testdata/image-vertical-package-dups/Dockerfile diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/collapse-white-space/index.d.ts b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/collapse-white-space/index.d.ts similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/collapse-white-space/index.d.ts rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/collapse-white-space/index.d.ts diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/collapse-white-space/index.js b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/collapse-white-space/index.js similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/collapse-white-space/index.js rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/collapse-white-space/index.js diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/collapse-white-space/license b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/collapse-white-space/license similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/collapse-white-space/license rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/collapse-white-space/license diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/collapse-white-space/package-lock.json b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/collapse-white-space/package-lock.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/collapse-white-space/package-lock.json rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/collapse-white-space/package-lock.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/collapse-white-space/package.json b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/collapse-white-space/package.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/collapse-white-space/package.json rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/collapse-white-space/package.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/collapse-white-space/readme.md b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/collapse-white-space/readme.md similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/collapse-white-space/readme.md rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/collapse-white-space/readme.md diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/end-of-stream/LICENSE b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/end-of-stream/LICENSE similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/end-of-stream/LICENSE rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/end-of-stream/LICENSE diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/end-of-stream/README.md b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/end-of-stream/README.md similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/end-of-stream/README.md rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/end-of-stream/README.md diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/end-of-stream/index.js b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/end-of-stream/index.js similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/end-of-stream/index.js rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/end-of-stream/index.js diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/end-of-stream/package.json b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/end-of-stream/package.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/end-of-stream/package.json rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/end-of-stream/package.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/insert-css/LICENSE b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/insert-css/LICENSE similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/insert-css/LICENSE rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/insert-css/LICENSE diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/insert-css/example.js b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/insert-css/example.js similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/insert-css/example.js rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/insert-css/example.js diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/insert-css/index.js b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/insert-css/index.js similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/insert-css/index.js rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/insert-css/index.js diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/insert-css/package.json b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/insert-css/package.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/insert-css/package.json rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/insert-css/package.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/insert-css/readme.markdown b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/insert-css/readme.markdown similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/insert-css/readme.markdown rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/insert-css/readme.markdown diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/insert-css/test.js b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/insert-css/test.js similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/insert-css/test.js rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/insert-css/test.js diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/once/LICENSE b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/once/LICENSE similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/once/LICENSE rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/once/LICENSE diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/once/README.md b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/once/README.md similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/once/README.md rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/once/README.md diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/once/once.js b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/once/once.js similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/once/once.js rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/once/once.js diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/once/package.json b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/once/package.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/once/package.json rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/once/package.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/pump/.travis.yml b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/pump/.travis.yml similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/pump/.travis.yml rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/pump/.travis.yml diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/pump/LICENSE b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/pump/LICENSE similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/pump/LICENSE rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/pump/LICENSE diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/pump/README.md b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/pump/README.md similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/pump/README.md rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/pump/README.md diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/pump/index.js b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/pump/index.js similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/pump/index.js rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/pump/index.js diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/pump/package.json b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/pump/package.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/pump/package.json rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/pump/package.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/pump/test-browser.js b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/pump/test-browser.js similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/pump/test-browser.js rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/pump/test-browser.js diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/pump/test-node.js b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/pump/test-node.js similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/pump/test-node.js rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/pump/test-node.js diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/wrappy/LICENSE b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/wrappy/LICENSE similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/wrappy/LICENSE rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/wrappy/LICENSE diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/wrappy/README.md b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/wrappy/README.md similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/wrappy/README.md rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/wrappy/README.md diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/wrappy/package-lock.json b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/wrappy/package-lock.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/wrappy/package-lock.json rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/wrappy/package-lock.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/wrappy/package.json b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/wrappy/package.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/wrappy/package.json rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/wrappy/package.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/wrappy/wrappy.js b/cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/wrappy/wrappy.js similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/node_modules/wrappy/wrappy.js rename to cmd/syft/internal/test/integration/testdata/npm-lock/node_modules/wrappy/wrappy.js diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/package-lock.json b/cmd/syft/internal/test/integration/testdata/npm-lock/package-lock.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/package-lock.json rename to cmd/syft/internal/test/integration/testdata/npm-lock/package-lock.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/npm-lock/package.json b/cmd/syft/internal/test/integration/testdata/npm-lock/package.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/npm-lock/package.json rename to cmd/syft/internal/test/integration/testdata/npm-lock/package.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/yarn-lock/node_modules/async/LICENSE b/cmd/syft/internal/test/integration/testdata/yarn-lock/node_modules/async/LICENSE similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/yarn-lock/node_modules/async/LICENSE rename to cmd/syft/internal/test/integration/testdata/yarn-lock/node_modules/async/LICENSE diff --git a/cmd/syft/internal/test/integration/test-fixtures/yarn-lock/node_modules/async/bower.json b/cmd/syft/internal/test/integration/testdata/yarn-lock/node_modules/async/bower.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/yarn-lock/node_modules/async/bower.json rename to cmd/syft/internal/test/integration/testdata/yarn-lock/node_modules/async/bower.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/yarn-lock/node_modules/async/package.json b/cmd/syft/internal/test/integration/testdata/yarn-lock/node_modules/async/package.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/yarn-lock/node_modules/async/package.json rename to cmd/syft/internal/test/integration/testdata/yarn-lock/node_modules/async/package.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/yarn-lock/node_modules/merge-objects/LICENSE.md b/cmd/syft/internal/test/integration/testdata/yarn-lock/node_modules/merge-objects/LICENSE.md similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/yarn-lock/node_modules/merge-objects/LICENSE.md rename to cmd/syft/internal/test/integration/testdata/yarn-lock/node_modules/merge-objects/LICENSE.md diff --git a/cmd/syft/internal/test/integration/test-fixtures/yarn-lock/node_modules/merge-objects/package.json b/cmd/syft/internal/test/integration/testdata/yarn-lock/node_modules/merge-objects/package.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/yarn-lock/node_modules/merge-objects/package.json rename to cmd/syft/internal/test/integration/testdata/yarn-lock/node_modules/merge-objects/package.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/yarn-lock/node_modules/resize-observer-polyfill/LICENSE b/cmd/syft/internal/test/integration/testdata/yarn-lock/node_modules/resize-observer-polyfill/LICENSE similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/yarn-lock/node_modules/resize-observer-polyfill/LICENSE rename to cmd/syft/internal/test/integration/testdata/yarn-lock/node_modules/resize-observer-polyfill/LICENSE diff --git a/cmd/syft/internal/test/integration/test-fixtures/yarn-lock/node_modules/resize-observer-polyfill/package.json b/cmd/syft/internal/test/integration/testdata/yarn-lock/node_modules/resize-observer-polyfill/package.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/yarn-lock/node_modules/resize-observer-polyfill/package.json rename to cmd/syft/internal/test/integration/testdata/yarn-lock/node_modules/resize-observer-polyfill/package.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/yarn-lock/node_modules/should-type/LICENSE b/cmd/syft/internal/test/integration/testdata/yarn-lock/node_modules/should-type/LICENSE similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/yarn-lock/node_modules/should-type/LICENSE rename to cmd/syft/internal/test/integration/testdata/yarn-lock/node_modules/should-type/LICENSE diff --git a/cmd/syft/internal/test/integration/test-fixtures/yarn-lock/node_modules/should-type/package.json b/cmd/syft/internal/test/integration/testdata/yarn-lock/node_modules/should-type/package.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/yarn-lock/node_modules/should-type/package.json rename to cmd/syft/internal/test/integration/testdata/yarn-lock/node_modules/should-type/package.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/yarn-lock/package.json b/cmd/syft/internal/test/integration/testdata/yarn-lock/package.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/yarn-lock/package.json rename to cmd/syft/internal/test/integration/testdata/yarn-lock/package.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/yarn-lock/packages/nested-package/node_modules/async/LICENSE b/cmd/syft/internal/test/integration/testdata/yarn-lock/packages/nested-package/node_modules/async/LICENSE similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/yarn-lock/packages/nested-package/node_modules/async/LICENSE rename to cmd/syft/internal/test/integration/testdata/yarn-lock/packages/nested-package/node_modules/async/LICENSE diff --git a/cmd/syft/internal/test/integration/test-fixtures/yarn-lock/packages/nested-package/node_modules/async/bower.json b/cmd/syft/internal/test/integration/testdata/yarn-lock/packages/nested-package/node_modules/async/bower.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/yarn-lock/packages/nested-package/node_modules/async/bower.json rename to cmd/syft/internal/test/integration/testdata/yarn-lock/packages/nested-package/node_modules/async/bower.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/yarn-lock/packages/nested-package/node_modules/async/component.json b/cmd/syft/internal/test/integration/testdata/yarn-lock/packages/nested-package/node_modules/async/component.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/yarn-lock/packages/nested-package/node_modules/async/component.json rename to cmd/syft/internal/test/integration/testdata/yarn-lock/packages/nested-package/node_modules/async/component.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/yarn-lock/packages/nested-package/node_modules/async/package.json b/cmd/syft/internal/test/integration/testdata/yarn-lock/packages/nested-package/node_modules/async/package.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/yarn-lock/packages/nested-package/node_modules/async/package.json rename to cmd/syft/internal/test/integration/testdata/yarn-lock/packages/nested-package/node_modules/async/package.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/yarn-lock/packages/nested-package/package.json b/cmd/syft/internal/test/integration/testdata/yarn-lock/packages/nested-package/package.json similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/yarn-lock/packages/nested-package/package.json rename to cmd/syft/internal/test/integration/testdata/yarn-lock/packages/nested-package/package.json diff --git a/cmd/syft/internal/test/integration/test-fixtures/yarn-lock/yarn.lock b/cmd/syft/internal/test/integration/testdata/yarn-lock/yarn.lock similarity index 100% rename from cmd/syft/internal/test/integration/test-fixtures/yarn-lock/yarn.lock rename to cmd/syft/internal/test/integration/testdata/yarn-lock/yarn.lock diff --git a/go.mod b/go.mod index 7e7b55844..03d564fe9 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module github.com/anchore/syft -go 1.25 +go 1.25.6 require ( github.com/BurntSushi/toml v1.6.0 @@ -20,11 +20,9 @@ require ( github.com/anchore/go-macholibre v0.0.0-20220308212642-53e6d0aaf6fb github.com/anchore/go-rpmdb v0.0.0-20250516171929-f77691e1faec github.com/anchore/go-sync v0.0.0-20250326131806-4eda43a485b6 - github.com/anchore/go-testutils v0.0.0-20200925183923-d5f45b0d3c04 github.com/anchore/go-version v1.2.2-0.20200701162849-18adb9c92b9b github.com/anchore/packageurl-go v0.1.1-0.20250220190351-d62adb6e1115 - github.com/anchore/stereoscope v0.1.20 - github.com/anmitsu/go-shlex v0.0.0-20200514113438-38f4b401e2be + github.com/anchore/stereoscope v0.1.21-0.20260306183853-99ed0b625349 github.com/aquasecurity/go-pep440-version v0.0.1 github.com/bitnami/go-version v0.0.0-20250131085805-b1f57a8634ef github.com/blakesmith/ar v0.0.0-20190502131153-809d4375e1fb @@ -40,14 +38,14 @@ require ( github.com/elliotchance/phpserialize v1.4.0 github.com/facebookincubator/nvdtools v0.1.5 github.com/github/go-spdx/v2 v2.3.6 - github.com/gkampitakis/go-snaps v0.5.19 + github.com/gkampitakis/go-snaps v0.5.20 github.com/go-git/go-billy/v5 v5.7.0 github.com/go-git/go-git/v5 v5.16.5 github.com/go-test/deep v1.1.1 github.com/go-viper/mapstructure/v2 v2.5.0 github.com/gohugoio/hashstructure v0.6.0 github.com/google/go-cmp v0.7.0 - github.com/google/go-containerregistry v0.20.7 + github.com/google/go-containerregistry v0.21.1 github.com/google/licensecheck v0.3.1 github.com/google/uuid v1.6.0 github.com/gookit/color v1.6.0 @@ -83,7 +81,7 @@ require ( github.com/vbatts/go-mtree v0.7.0 github.com/vifraa/gopom v1.0.0 github.com/wagoodman/go-partybus v0.0.0-20230516145632-8ccac152c651 - github.com/wagoodman/go-progress v0.0.0-20230925121702-07e42b3cdba0 + github.com/wagoodman/go-progress v0.0.0-20260303201901-10176f79b2c0 github.com/xeipuuv/gojsonschema v1.2.0 github.com/zyedidia/generic v1.2.2-0.20230320175451-4410d2372cb1 go.uber.org/goleak v1.3.0 @@ -134,15 +132,14 @@ require ( github.com/containerd/fifo v1.1.0 // indirect github.com/containerd/log v0.1.0 // indirect github.com/containerd/platforms v1.0.0-rc.2 // indirect - github.com/containerd/stargz-snapshotter/estargz v0.18.1 // indirect + github.com/containerd/stargz-snapshotter/estargz v0.18.2 // indirect github.com/containerd/ttrpc v1.2.7 // indirect github.com/containerd/typeurl/v2 v2.2.3 // indirect github.com/cyphar/filepath-securejoin v0.6.0 // indirect github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect - github.com/docker/cli v29.2.0+incompatible // indirect + github.com/docker/cli v29.2.1+incompatible // indirect github.com/docker/distribution v2.8.3+incompatible // indirect - github.com/docker/docker v28.5.2+incompatible // indirect - github.com/docker/docker-credential-helpers v0.9.4 // indirect + github.com/docker/docker-credential-helpers v0.9.5 // indirect github.com/docker/go-connections v0.6.0 // indirect github.com/docker/go-units v0.5.0 // indirect github.com/dsnet/compress v0.0.2-0.20230904184137-39efe44ab707 // indirect @@ -152,7 +149,7 @@ require ( github.com/felixge/fgprof v0.9.5 // indirect github.com/felixge/httpsnoop v1.0.4 // indirect github.com/fsnotify/fsnotify v1.9.0 // indirect - github.com/gabriel-vasile/mimetype v1.4.12 // indirect + github.com/gabriel-vasile/mimetype v1.4.13 // indirect github.com/gkampitakis/ciinfo v0.3.2 // indirect github.com/go-git/gcfg v1.5.1-0.20230307220236-3a3c6141e376 // indirect github.com/go-logr/logr v1.4.3 // indirect @@ -172,11 +169,10 @@ require ( github.com/inconshreveable/mousetrap v1.1.0 // indirect github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 // indirect github.com/kevinburke/ssh_config v1.2.0 // indirect - github.com/klauspost/compress v1.18.2 // indirect + github.com/klauspost/compress v1.18.4 // indirect github.com/klauspost/pgzip v1.2.6 // indirect github.com/kr/pretty v0.3.1 // indirect github.com/kr/text v0.2.0 // indirect - github.com/logrusorgru/aurora v2.0.3+incompatible // indirect github.com/lucasb-eyer/go-colorful v1.3.0 // indirect github.com/maruel/natural v1.1.1 // indirect github.com/mattn/go-colorable v0.1.14 // indirect @@ -217,16 +213,16 @@ require ( github.com/sagikazarmark/locafero v0.7.0 // indirect github.com/sahilm/fuzzy v0.1.1 // indirect github.com/shopspring/decimal v1.4.0 // indirect - github.com/sirupsen/logrus v1.9.4-0.20230606125235-dd1b4c2e81af // indirect + github.com/sirupsen/logrus v1.9.4 // indirect github.com/skeema/knownhosts v1.3.1 // indirect github.com/sorairolake/lzip-go v0.3.8 // indirect github.com/sourcegraph/conc v0.3.0 // indirect github.com/spf13/cast v1.7.1 // indirect - github.com/spf13/pflag v1.0.9 // indirect + github.com/spf13/pflag v1.0.10 // indirect github.com/spf13/viper v1.20.0 // indirect github.com/stretchr/objx v0.5.2 // indirect github.com/subosito/gotenv v1.6.0 // indirect - github.com/sylabs/sif/v2 v2.22.0 // indirect + github.com/sylabs/sif/v2 v2.23.0 // indirect github.com/sylabs/squashfs v1.0.6 // indirect github.com/therootcompany/xz v1.0.1 // indirect github.com/tidwall/gjson v1.18.0 // indirect @@ -252,7 +248,7 @@ require ( go.uber.org/multierr v1.9.0 // indirect go4.org v0.0.0-20230225012048-214862532bf5 // indirect golang.org/x/crypto v0.48.0 // indirect - golang.org/x/oauth2 v0.33.0 // indirect + golang.org/x/oauth2 v0.35.0 // indirect golang.org/x/sync v0.19.0 // indirect golang.org/x/sys v0.41.0 // indirect golang.org/x/term v0.40.0 // indirect @@ -265,7 +261,7 @@ require ( google.golang.org/genproto/googleapis/api v0.0.0-20251111163417-95abcf5c77ba // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20251111163417-95abcf5c77ba // indirect google.golang.org/grpc v1.76.0 // indirect - google.golang.org/protobuf v1.36.10 // indirect + google.golang.org/protobuf v1.36.11 // indirect gopkg.in/warnings.v0 v0.1.2 // indirect gopkg.in/yaml.v3 v3.0.1 modernc.org/libc v1.67.6 // indirect @@ -274,6 +270,7 @@ require ( ) require ( + github.com/anmitsu/go-shlex v0.0.0-20200514113438-38f4b401e2be github.com/cespare/xxhash/v2 v2.3.0 github.com/gpustack/gguf-parser-go v0.24.0 github.com/wk8/go-ordered-map/v2 v2.1.8 @@ -286,25 +283,25 @@ require ( github.com/GoogleCloudPlatform/opentelemetry-operations-go/detectors/gcp v1.29.0 // indirect github.com/GoogleCloudPlatform/opentelemetry-operations-go/exporter/metric v0.54.0 // indirect github.com/GoogleCloudPlatform/opentelemetry-operations-go/internal/resourcemapping v0.54.0 // indirect - github.com/aws/aws-sdk-go-v2 v1.41.0 // indirect + github.com/aws/aws-sdk-go-v2 v1.41.2 // indirect github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream v1.7.4 // indirect - github.com/aws/aws-sdk-go-v2/config v1.32.6 // indirect - github.com/aws/aws-sdk-go-v2/credentials v1.19.6 // indirect - github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.18.16 // indirect - github.com/aws/aws-sdk-go-v2/internal/configsources v1.4.16 // indirect - github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.7.16 // indirect + github.com/aws/aws-sdk-go-v2/config v1.32.10 // indirect + github.com/aws/aws-sdk-go-v2/credentials v1.19.10 // indirect + github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.18.18 // indirect + github.com/aws/aws-sdk-go-v2/internal/configsources v1.4.18 // indirect + github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.7.18 // indirect github.com/aws/aws-sdk-go-v2/internal/ini v1.8.4 // indirect github.com/aws/aws-sdk-go-v2/internal/v4a v1.4.16 // indirect - github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.13.4 // indirect + github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.13.5 // indirect github.com/aws/aws-sdk-go-v2/service/internal/checksum v1.9.7 // indirect - github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.13.16 // indirect + github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.13.18 // indirect github.com/aws/aws-sdk-go-v2/service/internal/s3shared v1.19.16 // indirect github.com/aws/aws-sdk-go-v2/service/s3 v1.95.0 // indirect - github.com/aws/aws-sdk-go-v2/service/signin v1.0.4 // indirect - github.com/aws/aws-sdk-go-v2/service/sso v1.30.8 // indirect - github.com/aws/aws-sdk-go-v2/service/ssooidc v1.35.12 // indirect - github.com/aws/aws-sdk-go-v2/service/sts v1.41.5 // indirect - github.com/aws/smithy-go v1.24.0 // indirect + github.com/aws/aws-sdk-go-v2/service/signin v1.0.6 // indirect + github.com/aws/aws-sdk-go-v2/service/sso v1.30.11 // indirect + github.com/aws/aws-sdk-go-v2/service/ssooidc v1.35.15 // indirect + github.com/aws/aws-sdk-go-v2/service/sts v1.41.7 // indirect + github.com/aws/smithy-go v1.24.1 // indirect github.com/bahlo/generic-list-go v0.2.0 // indirect github.com/buger/jsonparser v1.1.1 // indirect github.com/clipperhouse/displaywidth v0.9.0 // indirect @@ -321,6 +318,8 @@ require ( github.com/henvic/httpretty v0.1.4 // indirect github.com/json-iterator/go v1.1.12 // indirect github.com/mailru/easyjson v0.7.7 // indirect + github.com/moby/moby/api v1.52.0 // indirect + github.com/moby/moby/client v0.2.1 // indirect github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect github.com/modern-go/reflect2 v1.0.3-0.20250322232337-35a7c28c31ee // indirect github.com/nwaples/rardecode/v2 v2.2.0 // indirect diff --git a/go.sum b/go.sum index 03e1fa0e0..a4992fb14 100644 --- a/go.sum +++ b/go.sum @@ -74,8 +74,6 @@ dario.cat/mergo v1.0.2/go.mod h1:E/hbnu0NxMFBjpMIE34DRGLWqDy0g5FuKDhCb31ngxA= dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= github.com/AdaLogics/go-fuzz-headers v0.0.0-20240806141605-e8a1dd7889d6 h1:He8afgbRMd7mFxO99hRNu+6tazq8nFF9lIwo9JFroBk= github.com/AdaLogics/go-fuzz-headers v0.0.0-20240806141605-e8a1dd7889d6/go.mod h1:8o94RPi1/7XTJvwPpRSzSUedZrtlirdB3r9Z20bi2f8= -github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161 h1:L/gRVlceqvL25UVaW/CKtUDjefjrs0SPonmDGUVOYP0= -github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/BurntSushi/toml v0.4.1/go.mod h1:CxXYINrC8qIiEnFrOxCa7Jy5BFHlXnUU2pbicEuybxQ= github.com/BurntSushi/toml v1.6.0 h1:dRaEfpa2VI55EwlIW72hMRHdWouJeRF7TPYhI+AUQjk= @@ -146,14 +144,12 @@ github.com/anchore/go-struct-converter v0.1.0 h1:2rDRssAl6mgKBSLNiVCMADgZRhoqtw9 github.com/anchore/go-struct-converter v0.1.0/go.mod h1:rYqSE9HbjzpHTI74vwPvae4ZVYZd1lue2ta6xHPdblA= github.com/anchore/go-sync v0.0.0-20250326131806-4eda43a485b6 h1:Ha+LSCVuXYSYGi7wIkJK6G8g6jI3LH7y6LbyEVyp4Io= github.com/anchore/go-sync v0.0.0-20250326131806-4eda43a485b6/go.mod h1:+9oM3XUy8iea/vWj9FhZ9bQGUBN8JpPxxJm5Wbcx9XM= -github.com/anchore/go-testutils v0.0.0-20200925183923-d5f45b0d3c04 h1:VzprUTpc0vW0nnNKJfJieyH/TZ9UYAnTZs5/gHTdAe8= -github.com/anchore/go-testutils v0.0.0-20200925183923-d5f45b0d3c04/go.mod h1:6dK64g27Qi1qGQZ67gFmBFvEHScy0/C8qhQhNe5B5pQ= github.com/anchore/go-version v1.2.2-0.20200701162849-18adb9c92b9b h1:e1bmaoJfZVsCYMrIZBpFxwV26CbsuoEh5muXD5I1Ods= github.com/anchore/go-version v1.2.2-0.20200701162849-18adb9c92b9b/go.mod h1:Bkc+JYWjMCF8OyZ340IMSIi2Ebf3uwByOk6ho4wne1E= github.com/anchore/packageurl-go v0.1.1-0.20250220190351-d62adb6e1115 h1:ZyRCmiEjnoGJZ1+Ah0ZZ/mKKqNhGcUZBl0s7PTTDzvY= github.com/anchore/packageurl-go v0.1.1-0.20250220190351-d62adb6e1115/go.mod h1:KoYIv7tdP5+CC9VGkeZV4/vGCKsY55VvoG+5dadg4YI= -github.com/anchore/stereoscope v0.1.20 h1:32720yZ/YtvzF5tvsoRL/ibdAJzOdIaR444fDXW4arQ= -github.com/anchore/stereoscope v0.1.20/go.mod h1:6Ef0xQAuN2Ito7eV9A9pYjD1x/0cX5fy56MwgEGyrB4= +github.com/anchore/stereoscope v0.1.21-0.20260306183853-99ed0b625349 h1:Py7j3sFG5IHInfwPUjmTYCdT9Q7VKx6wrwJNEu4KV2g= +github.com/anchore/stereoscope v0.1.21-0.20260306183853-99ed0b625349/go.mod h1:z+keXCz+fT2kXYo3GGldZAinhKlwMFpKmN5POXpajSY= github.com/andreyvit/diff v0.0.0-20170406064948-c7f18ee00883/go.mod h1:rCTlJbsFo29Kk6CurOXKm700vrz8f0KW0JNfpkRJY/8= github.com/andybalholm/brotli v1.2.0 h1:ukwgCxwYrmACq68yiUqwIWnGY0cTPox/M94sVwToPjQ= github.com/andybalholm/brotli v1.2.0/go.mod h1:rzTDkvFWvIrjDXZHkuS16NPggd91W3kUSvPlQ1pLaKY= @@ -175,44 +171,44 @@ github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5 h1:0CwZNZbxp69SHPd github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5/go.mod h1:wHh0iHkYZB8zMSxRWpUBQtwG5a7fFgvEO+odwuTv2gs= github.com/atotto/clipboard v0.1.4 h1:EH0zSVneZPSuFR11BlR9YppQTVDbh5+16AmcJi4g1z4= github.com/atotto/clipboard v0.1.4/go.mod h1:ZY9tmq7sm5xIbd9bOK4onWV4S6X0u6GY7Vn0Yu86PYI= -github.com/aws/aws-sdk-go-v2 v1.41.0 h1:tNvqh1s+v0vFYdA1xq0aOJH+Y5cRyZ5upu6roPgPKd4= -github.com/aws/aws-sdk-go-v2 v1.41.0/go.mod h1:MayyLB8y+buD9hZqkCW3kX1AKq07Y5pXxtgB+rRFhz0= +github.com/aws/aws-sdk-go-v2 v1.41.2 h1:LuT2rzqNQsauaGkPK/7813XxcZ3o3yePY0Iy891T2ls= +github.com/aws/aws-sdk-go-v2 v1.41.2/go.mod h1:IvvlAZQXvTXznUPfRVfryiG1fbzE2NGK6m9u39YQ+S4= github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream v1.7.4 h1:489krEF9xIGkOaaX3CE/Be2uWjiXrkCH6gUX+bZA/BU= github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream v1.7.4/go.mod h1:IOAPF6oT9KCsceNTvvYMNHy0+kMF8akOjeDvPENWxp4= -github.com/aws/aws-sdk-go-v2/config v1.32.6 h1:hFLBGUKjmLAekvi1evLi5hVvFQtSo3GYwi+Bx4lpJf8= -github.com/aws/aws-sdk-go-v2/config v1.32.6/go.mod h1:lcUL/gcd8WyjCrMnxez5OXkO3/rwcNmvfno62tnXNcI= -github.com/aws/aws-sdk-go-v2/credentials v1.19.6 h1:F9vWao2TwjV2MyiyVS+duza0NIRtAslgLUM0vTA1ZaE= -github.com/aws/aws-sdk-go-v2/credentials v1.19.6/go.mod h1:SgHzKjEVsdQr6Opor0ihgWtkWdfRAIwxYzSJ8O85VHY= -github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.18.16 h1:80+uETIWS1BqjnN9uJ0dBUaETh+P1XwFy5vwHwK5r9k= -github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.18.16/go.mod h1:wOOsYuxYuB/7FlnVtzeBYRcjSRtQpAW0hCP7tIULMwo= -github.com/aws/aws-sdk-go-v2/internal/configsources v1.4.16 h1:rgGwPzb82iBYSvHMHXc8h9mRoOUBZIGFgKb9qniaZZc= -github.com/aws/aws-sdk-go-v2/internal/configsources v1.4.16/go.mod h1:L/UxsGeKpGoIj6DxfhOWHWQ/kGKcd4I1VncE4++IyKA= -github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.7.16 h1:1jtGzuV7c82xnqOVfx2F0xmJcOw5374L7N6juGW6x6U= -github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.7.16/go.mod h1:M2E5OQf+XLe+SZGmmpaI2yy+J326aFf6/+54PoxSANc= +github.com/aws/aws-sdk-go-v2/config v1.32.10 h1:9DMthfO6XWZYLfzZglAgW5Fyou2nRI5CuV44sTedKBI= +github.com/aws/aws-sdk-go-v2/config v1.32.10/go.mod h1:2rUIOnA2JaiqYmSKYmRJlcMWy6qTj1vuRFscppSBMcw= +github.com/aws/aws-sdk-go-v2/credentials v1.19.10 h1:EEhmEUFCE1Yhl7vDhNOI5OCL/iKMdkkYFTRpZXNw7m8= +github.com/aws/aws-sdk-go-v2/credentials v1.19.10/go.mod h1:RnnlFCAlxQCkN2Q379B67USkBMu1PipEEiibzYN5UTE= +github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.18.18 h1:Ii4s+Sq3yDfaMLpjrJsqD6SmG/Wq/P5L/hw2qa78UAY= +github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.18.18/go.mod h1:6x81qnY++ovptLE6nWQeWrpXxbnlIex+4H4eYYGcqfc= +github.com/aws/aws-sdk-go-v2/internal/configsources v1.4.18 h1:F43zk1vemYIqPAwhjTjYIz0irU2EY7sOb/F5eJ3HuyM= +github.com/aws/aws-sdk-go-v2/internal/configsources v1.4.18/go.mod h1:w1jdlZXrGKaJcNoL+Nnrj+k5wlpGXqnNrKoP22HvAug= +github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.7.18 h1:xCeWVjj0ki0l3nruoyP2slHsGArMxeiiaoPN5QZH6YQ= +github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.7.18/go.mod h1:r/eLGuGCBw6l36ZRWiw6PaZwPXb6YOj+i/7MizNl5/k= github.com/aws/aws-sdk-go-v2/internal/ini v1.8.4 h1:WKuaxf++XKWlHWu9ECbMlha8WOEGm0OUEZqm4K/Gcfk= github.com/aws/aws-sdk-go-v2/internal/ini v1.8.4/go.mod h1:ZWy7j6v1vWGmPReu0iSGvRiise4YI5SkR3OHKTZ6Wuc= github.com/aws/aws-sdk-go-v2/internal/v4a v1.4.16 h1:CjMzUs78RDDv4ROu3JnJn/Ig1r6ZD7/T2DXLLRpejic= github.com/aws/aws-sdk-go-v2/internal/v4a v1.4.16/go.mod h1:uVW4OLBqbJXSHJYA9svT9BluSvvwbzLQ2Crf6UPzR3c= -github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.13.4 h1:0ryTNEdJbzUCEWkVXEXoqlXV72J5keC1GvILMOuD00E= -github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.13.4/go.mod h1:HQ4qwNZh32C3CBeO6iJLQlgtMzqeG17ziAA/3KDJFow= +github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.13.5 h1:CeY9LUdur+Dxoeldqoun6y4WtJ3RQtzk0JMP2gfUay0= +github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.13.5/go.mod h1:AZLZf2fMaahW5s/wMRciu1sYbdsikT/UHwbUjOdEVTc= github.com/aws/aws-sdk-go-v2/service/internal/checksum v1.9.7 h1:DIBqIrJ7hv+e4CmIk2z3pyKT+3B6qVMgRsawHiR3qso= github.com/aws/aws-sdk-go-v2/service/internal/checksum v1.9.7/go.mod h1:vLm00xmBke75UmpNvOcZQ/Q30ZFjbczeLFqGx5urmGo= -github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.13.16 h1:oHjJHeUy0ImIV0bsrX0X91GkV5nJAyv1l1CC9lnO0TI= -github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.13.16/go.mod h1:iRSNGgOYmiYwSCXxXaKb9HfOEj40+oTKn8pTxMlYkRM= +github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.13.18 h1:LTRCYFlnnKFlKsyIQxKhJuDuA3ZkrDQMRYm6rXiHlLY= +github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.13.18/go.mod h1:XhwkgGG6bHSd00nO/mexWTcTjgd6PjuvWQMqSn2UaEk= github.com/aws/aws-sdk-go-v2/service/internal/s3shared v1.19.16 h1:NSbvS17MlI2lurYgXnCOLvCFX38sBW4eiVER7+kkgsU= github.com/aws/aws-sdk-go-v2/service/internal/s3shared v1.19.16/go.mod h1:SwT8Tmqd4sA6G1qaGdzWCJN99bUmPGHfRwwq3G5Qb+A= github.com/aws/aws-sdk-go-v2/service/s3 v1.95.0 h1:MIWra+MSq53CFaXXAywB2qg9YvVZifkk6vEGl/1Qor0= github.com/aws/aws-sdk-go-v2/service/s3 v1.95.0/go.mod h1:79S2BdqCJpScXZA2y+cpZuocWsjGjJINyXnOsf5DTz8= -github.com/aws/aws-sdk-go-v2/service/signin v1.0.4 h1:HpI7aMmJ+mm1wkSHIA2t5EaFFv5EFYXePW30p1EIrbQ= -github.com/aws/aws-sdk-go-v2/service/signin v1.0.4/go.mod h1:C5RdGMYGlfM0gYq/tifqgn4EbyX99V15P2V3R+VHbQU= -github.com/aws/aws-sdk-go-v2/service/sso v1.30.8 h1:aM/Q24rIlS3bRAhTyFurowU8A0SMyGDtEOY/l/s/1Uw= -github.com/aws/aws-sdk-go-v2/service/sso v1.30.8/go.mod h1:+fWt2UHSb4kS7Pu8y+BMBvJF0EWx+4H0hzNwtDNRTrg= -github.com/aws/aws-sdk-go-v2/service/ssooidc v1.35.12 h1:AHDr0DaHIAo8c9t1emrzAlVDFp+iMMKnPdYy6XO4MCE= -github.com/aws/aws-sdk-go-v2/service/ssooidc v1.35.12/go.mod h1:GQ73XawFFiWxyWXMHWfhiomvP3tXtdNar/fi8z18sx0= -github.com/aws/aws-sdk-go-v2/service/sts v1.41.5 h1:SciGFVNZ4mHdm7gpD1dgZYnCuVdX1s+lFTg4+4DOy70= -github.com/aws/aws-sdk-go-v2/service/sts v1.41.5/go.mod h1:iW40X4QBmUxdP+fZNOpfmkdMZqsovezbAeO+Ubiv2pk= -github.com/aws/smithy-go v1.24.0 h1:LpilSUItNPFr1eY85RYgTIg5eIEPtvFbskaFcmmIUnk= -github.com/aws/smithy-go v1.24.0/go.mod h1:LEj2LM3rBRQJxPZTB4KuzZkaZYnZPnvgIhb4pu07mx0= +github.com/aws/aws-sdk-go-v2/service/signin v1.0.6 h1:MzORe+J94I+hYu2a6XmV5yC9huoTv8NRcCrUNedDypQ= +github.com/aws/aws-sdk-go-v2/service/signin v1.0.6/go.mod h1:hXzcHLARD7GeWnifd8j9RWqtfIgxj4/cAtIVIK7hg8g= +github.com/aws/aws-sdk-go-v2/service/sso v1.30.11 h1:7oGD8KPfBOJGXiCoRKrrrQkbvCp8N++u36hrLMPey6o= +github.com/aws/aws-sdk-go-v2/service/sso v1.30.11/go.mod h1:0DO9B5EUJQlIDif+XJRWCljZRKsAFKh3gpFz7UnDtOo= +github.com/aws/aws-sdk-go-v2/service/ssooidc v1.35.15 h1:edCcNp9eGIUDUCrzoCu1jWAXLGFIizeqkdkKgRlJwWc= +github.com/aws/aws-sdk-go-v2/service/ssooidc v1.35.15/go.mod h1:lyRQKED9xWfgkYC/wmmYfv7iVIM68Z5OQ88ZdcV1QbU= +github.com/aws/aws-sdk-go-v2/service/sts v1.41.7 h1:NITQpgo9A5NrDZ57uOWj+abvXSb83BbyggcUBVksN7c= +github.com/aws/aws-sdk-go-v2/service/sts v1.41.7/go.mod h1:sks5UWBhEuWYDPdwlnRFn1w7xWdH29Jcpe+/PJQefEs= +github.com/aws/smithy-go v1.24.1 h1:VbyeNfmYkWoxMVpGUAbQumkODcYmfMRfZ8yQiH30SK0= +github.com/aws/smithy-go v1.24.1/go.mod h1:LEj2LM3rBRQJxPZTB4KuzZkaZYnZPnvgIhb4pu07mx0= github.com/aymanbagabas/go-osc52/v2 v2.0.1 h1:HwpRHbFMcZLEVr42D4p7XBqjyuxQH5SMiErDT4WkJ2k= github.com/aymanbagabas/go-osc52/v2 v2.0.1/go.mod h1:uYgXzlJ7ZpABp8OJ+exZzJJhRNQ2ASbcXHWsFqH8hp8= github.com/aymanbagabas/go-udiff v0.3.1 h1:LV+qyBQ2pqe0u42ZsUEtPiCaUoqgA9gYRDs3vj1nolY= @@ -243,8 +239,6 @@ github.com/bradleyjkemp/cupaloy/v2 v2.8.0 h1:any4BmKE+jGIaMpnU8YgH/I2LPiLBufr6oM github.com/bradleyjkemp/cupaloy/v2 v2.8.0/go.mod h1:bm7JXdkRd4BHJk9HpwqAI8BoAY1lps46Enkdqw6aRX0= github.com/buger/jsonparser v1.1.1 h1:2PnMjfWD7wBILjqQbt530v576A/cAbQvEW9gGIpYMUs= github.com/buger/jsonparser v1.1.1/go.mod h1:6RYKKt7H4d4+iWqouImQ9R2FZql3VbhNgx27UK13J/0= -github.com/cenkalti/backoff/v4 v4.3.0 h1:MyRJ/UdXutAwSAT+s3wNd7MfTIcy71VQueUuFK343L8= -github.com/cenkalti/backoff/v4 v4.3.0/go.mod h1:Y3VNntkOUPxTVeUxJ/G5vcM//AlwfmyYozVcomhLiZE= github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= github.com/census-instrumentation/opencensus-proto v0.3.0/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc= @@ -322,8 +316,8 @@ github.com/containerd/platforms v1.0.0-rc.2 h1:0SPgaNZPVWGEi4grZdV8VRYQn78y+nm6a github.com/containerd/platforms v1.0.0-rc.2/go.mod h1:J71L7B+aiM5SdIEqmd9wp6THLVRzJGXfNuWCZCllLA4= github.com/containerd/plugin v1.0.0 h1:c8Kf1TNl6+e2TtMHZt+39yAPDbouRH9WAToRjex483Y= github.com/containerd/plugin v1.0.0/go.mod h1:hQfJe5nmWfImiqT1q8Si3jLv3ynMUIBB47bQ+KexvO8= -github.com/containerd/stargz-snapshotter/estargz v0.18.1 h1:cy2/lpgBXDA3cDKSyEfNOFMA/c10O1axL69EU7iirO8= -github.com/containerd/stargz-snapshotter/estargz v0.18.1/go.mod h1:ALIEqa7B6oVDsrF37GkGN20SuvG/pIMm7FwP7ZmRb0Q= +github.com/containerd/stargz-snapshotter/estargz v0.18.2 h1:yXkZFYIzz3eoLwlTUZKz2iQ4MrckBxJjkmD16ynUTrw= +github.com/containerd/stargz-snapshotter/estargz v0.18.2/go.mod h1:XyVU5tcJ3PRpkA9XS2T5us6Eg35yM0214Y+wvrZTBrY= github.com/containerd/ttrpc v1.2.7 h1:qIrroQvuOL9HQ1X6KHe2ohc7p+HP/0VE6XPU7elJRqQ= github.com/containerd/ttrpc v1.2.7/go.mod h1:YCXHsb32f+Sq5/72xHubdiJRQY9inL4a4ZQrAbN1q9o= github.com/containerd/typeurl/v2 v2.2.3 h1:yNA/94zxWdvYACdYO8zofhrTVuQY73fFU1y++dYSw40= @@ -351,14 +345,12 @@ github.com/distribution/reference v0.6.0 h1:0IXCQ5g4/QMHHkarYzh5l+u8T3t73zM5Qvfr github.com/distribution/reference v0.6.0/go.mod h1:BbU0aIcezP1/5jX/8MP0YiH4SdvB5Y4f/wlDRiLyi3E= github.com/djherbis/times v1.6.0 h1:w2ctJ92J8fBvWPxugmXIv7Nz7Q3iDMKNx9v5ocVH20c= github.com/djherbis/times v1.6.0/go.mod h1:gOHeRAz2h+VJNZ5Gmc/o7iD9k4wW7NMVqieYCY99oc0= -github.com/docker/cli v29.2.0+incompatible h1:9oBd9+YM7rxjZLfyMGxjraKBKE4/nVyvVfN4qNl9XRM= -github.com/docker/cli v29.2.0+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8= +github.com/docker/cli v29.2.1+incompatible h1:n3Jt0QVCN65eiVBoUTZQM9mcQICCJt3akW4pKAbKdJg= +github.com/docker/cli v29.2.1+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8= github.com/docker/distribution v2.8.3+incompatible h1:AtKxIZ36LoNK51+Z6RpzLpddBirtxJnzDrHLEKxTAYk= github.com/docker/distribution v2.8.3+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= -github.com/docker/docker v28.5.2+incompatible h1:DBX0Y0zAjZbSrm1uzOkdr1onVghKaftjlSWt4AFexzM= -github.com/docker/docker v28.5.2+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= -github.com/docker/docker-credential-helpers v0.9.4 h1:76ItO69/AP/V4yT9V4uuuItG0B1N8hvt0T0c0NN/DzI= -github.com/docker/docker-credential-helpers v0.9.4/go.mod h1:v1S+hepowrQXITkEfw6o4+BMbGot02wiKpzWhGUZK6c= +github.com/docker/docker-credential-helpers v0.9.5 h1:EFNN8DHvaiK8zVqFA2DT6BjXE0GzfLOZ38ggPTKePkY= +github.com/docker/docker-credential-helpers v0.9.5/go.mod h1:v1S+hepowrQXITkEfw6o4+BMbGot02wiKpzWhGUZK6c= github.com/docker/go-connections v0.6.0 h1:LlMG9azAe1TqfR7sO+NJttz1gy6KO7VJBh+pMmjSD94= github.com/docker/go-connections v0.6.0/go.mod h1:AahvXYshr6JgfUJGdDCs2b5EZG/vmaMAntpSFH5BFKE= github.com/docker/go-units v0.5.0 h1:69rxXcBk27SvSaaxTtLh/8llcHD8vYHT7WSdRZ/jvr4= @@ -417,15 +409,15 @@ github.com/frankban/quicktest v1.14.6/go.mod h1:4ptaffx2x8+WTWXmUCuVU6aPUX1/Mz7z github.com/fsnotify/fsnotify v1.5.1/go.mod h1:T3375wBYaZdLLcVNkcVbzGHY7f1l/uK5T5Ai1i3InKU= github.com/fsnotify/fsnotify v1.9.0 h1:2Ml+OJNzbYCTzsxtv8vKSFD9PbJjmhYF14k/jKC7S9k= github.com/fsnotify/fsnotify v1.9.0/go.mod h1:8jBTzvmWwFyi3Pb8djgCCO5IBqzKJ/Jwo8TRcHyHii0= -github.com/gabriel-vasile/mimetype v1.4.12 h1:e9hWvmLYvtp846tLHam2o++qitpguFiYCKbn0w9jyqw= -github.com/gabriel-vasile/mimetype v1.4.12/go.mod h1:d+9Oxyo1wTzWdyVUPMmXFvp4F9tea18J8ufA774AB3s= +github.com/gabriel-vasile/mimetype v1.4.13 h1:46nXokslUBsAJE/wMsp5gtO500a4F3Nkz9Ufpk2AcUM= +github.com/gabriel-vasile/mimetype v1.4.13/go.mod h1:d+9Oxyo1wTzWdyVUPMmXFvp4F9tea18J8ufA774AB3s= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= github.com/github/go-spdx/v2 v2.3.6 h1:9flm625VmmTlWXi0YH5W9V8FdMfulvxalHdYnUfoqxc= github.com/github/go-spdx/v2 v2.3.6/go.mod h1:/5rwgS0txhGtRdUZwc02bTglzg6HK3FfuEbECKlK2Sg= github.com/gkampitakis/ciinfo v0.3.2 h1:JcuOPk8ZU7nZQjdUhctuhQofk7BGHuIy0c9Ez8BNhXs= github.com/gkampitakis/ciinfo v0.3.2/go.mod h1:1NIwaOcFChN4fa/B0hEBdAb6npDlFL8Bwx4dfRLRqAo= -github.com/gkampitakis/go-snaps v0.5.19 h1:hUJlCQOpTt1M+kSisMwioDWZDWpDtdAvUhvWCx1YGW0= -github.com/gkampitakis/go-snaps v0.5.19/go.mod h1:gC3YqxQTPyIXvQrw/Vpt3a8VqR1MO8sVpZFWN4DGwNs= +github.com/gkampitakis/go-snaps v0.5.20 h1:FGKonEeQPJ12t7RQj6cTPa881fl5c8HYarMLv5vP7sg= +github.com/gkampitakis/go-snaps v0.5.20/go.mod h1:gC3YqxQTPyIXvQrw/Vpt3a8VqR1MO8sVpZFWN4DGwNs= github.com/glebarez/go-sqlite v1.20.3 h1:89BkqGOXR9oRmG58ZrzgoY/Fhy5x0M+/WV48U5zVrZ4= github.com/glebarez/go-sqlite v1.20.3/go.mod h1:u3N6D/wftiAzIOJtZl6BmedqxmmkDfH3q+ihjqxC9u0= github.com/gliderlabs/ssh v0.3.8 h1:a4YXD1V7xMF9g5nTkdfnja3Sxy1PVDCj1Zg4Wb8vY6c= @@ -523,8 +515,8 @@ github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/ github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.7.0 h1:wk8382ETsv4JYUZwIsn6YpYiWiBsYLSJiTsyBybVuN8= github.com/google/go-cmp v0.7.0/go.mod h1:pXiqmnSA92OHEEa9HXL2W4E7lf9JzCmGVUdgjX3N/iU= -github.com/google/go-containerregistry v0.20.7 h1:24VGNpS0IwrOZ2ms2P1QE3Xa5X9p4phx0aUgzYzHW6I= -github.com/google/go-containerregistry v0.20.7/go.mod h1:Lx5LCZQjLH1QBaMPeGwsME9biPeo1lPx6lbGj/UmzgM= +github.com/google/go-containerregistry v0.21.1 h1:sOt/o9BS2b87FnR7wxXPvRKU1XVJn2QCwOS5g8zQXlc= +github.com/google/go-containerregistry v0.21.1/go.mod h1:ctO5aCaewH4AK1AumSF5DPW+0+R+d2FmylMJdp5G7p0= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/licensecheck v0.3.1 h1:QoxgoDkaeC4nFrtGN1jV7IPmDCHFNIVh54e5hSt6sPs= github.com/google/licensecheck v0.3.1/go.mod h1:ORkR35t/JjW+emNKtfJDII0zlciG9JgbT7SmsohlHmY= @@ -574,10 +566,7 @@ github.com/gookit/color v1.6.0 h1:JjJXBTk1ETNyqyilJhkTXJYYigHG24TM9Xa2M1xAhRA= github.com/gookit/color v1.6.0/go.mod h1:9ACFc7/1IpHGBW8RwuDm/0YEnhg3dwwXpoMsmtyHfjs= github.com/gpustack/gguf-parser-go v0.24.0 h1:tdJceXYp9e5RhE9RwVYIuUpir72Jz2D68NEtDXkKCKc= github.com/gpustack/gguf-parser-go v0.24.0/go.mod h1:y4TwTtDqFWTK+xvprOjRUh+dowgU2TKCX37vRKvGiZ0= -github.com/grpc-ecosystem/grpc-gateway v1.16.0 h1:gmcG1KaJ57LophUzW0Hy8NmPhnMZb4M0+kPpLofRdBo= github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= -github.com/grpc-ecosystem/grpc-gateway/v2 v2.26.1 h1:e9Rjr40Z98/clHv5Yg79Is0NtosR5LXRvdr7o/6NwbA= -github.com/grpc-ecosystem/grpc-gateway/v2 v2.26.1/go.mod h1:tIxuGz/9mpox++sgp9fJjHO0+q1X9/UOWd798aAm22M= github.com/hashicorp/aws-sdk-go-base/v2 v2.0.0-beta.70 h1:0HADrxxqaQkGycO1JoUUA+B4FnIkuo8d2bz/hSaTFFQ= github.com/hashicorp/aws-sdk-go-base/v2 v2.0.0-beta.70/go.mod h1:fm2FdDCzJdtbXF7WKAMvBb5NEPouXPHFbGNYs9ShFns= github.com/hashicorp/consul/api v1.11.0/go.mod h1:XjsvQN+RJGWI2TWy1/kqaE16HrR2J/FWgkYjdZQsX9M= @@ -661,8 +650,8 @@ github.com/kevinburke/ssh_config v1.2.0/go.mod h1:CT57kijsi8u/K/BOFA39wgDQJ9CxiF github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= github.com/klauspost/compress v1.4.1/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= -github.com/klauspost/compress v1.18.2 h1:iiPHWW0YrcFgpBYhsA6D1+fqHssJscY/Tm/y2Uqnapk= -github.com/klauspost/compress v1.18.2/go.mod h1:R0h/fSBs8DE4ENlcrlib3PsXS61voFxhIs2DeRhCvJ4= +github.com/klauspost/compress v1.18.4 h1:RPhnKRAQ4Fh8zU2FY/6ZFDwTVTxgJ/EMydqSTzE9a2c= +github.com/klauspost/compress v1.18.4/go.mod h1:R0h/fSBs8DE4ENlcrlib3PsXS61voFxhIs2DeRhCvJ4= github.com/klauspost/cpuid v1.2.0/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek= github.com/klauspost/pgzip v1.2.6 h1:8RXeL5crjEUFnR2/Sn6GJNWtSQ3Dk8pq4CL3jvdDyjU= github.com/klauspost/pgzip v1.2.6/go.mod h1:Ch1tH69qFZu15pkjo5kYi6mth2Zzwzt50oCQKQE9RUs= @@ -680,9 +669,6 @@ github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= github.com/kylelemons/godebug v1.1.0 h1:RPNrshWIDI6G2gRW9EHilWtl7Z6Sb1BR0xunSBf0SNc= github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= github.com/ledongthuc/pdf v0.0.0-20220302134840-0c2507a12d80/go.mod h1:imJHygn/1yfhB7XSJJKlFZKl/J+dCPAknuiaGOshXAs= -github.com/logrusorgru/aurora v0.0.0-20200102142835-e9ef32dff381/go.mod h1:7rIyQOR62GCctdiQpZ/zOJlFyk6y+94wXzv6RNZgaR4= -github.com/logrusorgru/aurora v2.0.3+incompatible h1:tOpm7WcpBTn4fjmVfgpQq0EfczGlG91VSDkswnjF5A8= -github.com/logrusorgru/aurora v2.0.3+incompatible/go.mod h1:7rIyQOR62GCctdiQpZ/zOJlFyk6y+94wXzv6RNZgaR4= github.com/lucasb-eyer/go-colorful v1.3.0 h1:2/yBRLdWBZKrf7gB40FoiKfAWYQ0lqNcbuQwVHXptag= github.com/lucasb-eyer/go-colorful v1.3.0/go.mod h1:R4dSotOR9KMtayYi1e77YzuveK+i7ruzyGqttikkLy0= github.com/lyft/protoc-gen-star v0.5.3/go.mod h1:V0xaHgaf5oCCqmcxYcWiDfTiKsZsRc87/1qhoTACD8w= @@ -741,8 +727,10 @@ github.com/moby/docker-image-spec v1.3.1 h1:jMKff3w6PgbfSa69GfNg+zN/XLhfXJGnEx3N github.com/moby/docker-image-spec v1.3.1/go.mod h1:eKmb5VW8vQEh/BAr2yvVNvuiJuY6UIocYsFu/DxxRpo= github.com/moby/locker v1.0.1 h1:fOXqR41zeveg4fFODix+1Ch4mj/gT0NE1XJbp/epuBg= github.com/moby/locker v1.0.1/go.mod h1:S7SDdo5zpBK84bzzVlKr2V0hz+7x9hWbYC/kq7oQppc= -github.com/moby/sys/atomicwriter v0.1.0 h1:kw5D/EqkBwsBFi0ss9v1VG3wIkVhzGvLklJ+w3A14Sw= -github.com/moby/sys/atomicwriter v0.1.0/go.mod h1:Ul8oqv2ZMNHOceF643P6FKPXeCmYtlQMvpizfsSoaWs= +github.com/moby/moby/api v1.52.0 h1:00BtlJY4MXkkt84WhUZPRqt5TvPbgig2FZvTbe3igYg= +github.com/moby/moby/api v1.52.0/go.mod h1:8mb+ReTlisw4pS6BRzCMts5M49W5M7bKt1cJy/YbAqc= +github.com/moby/moby/client v0.2.1 h1:1Grh1552mvv6i+sYOdY+xKKVTvzJegcVMhuXocyDz/k= +github.com/moby/moby/client v0.2.1/go.mod h1:O+/tw5d4a1Ha/ZA/tPxIZJapJRUS6LNZ1wiVRxYHyUE= github.com/moby/sys/mountinfo v0.7.2 h1:1shs6aH5s4o5H2zQLn796ADW1wMrIwHsyJ2v9KouLrg= github.com/moby/sys/mountinfo v0.7.2/go.mod h1:1YOa8w8Ih7uW0wALDUgT1dTTSBrZ+HiBLGws92L2RU4= github.com/moby/sys/sequential v0.6.0 h1:qrx7XFUd/5DxtqcoH1h438hF5TmOvzC/lspjy7zgvCU= @@ -753,8 +741,6 @@ github.com/moby/sys/user v0.4.0 h1:jhcMKit7SA80hivmFJcbB1vqmw//wU61Zdui2eQXuMs= github.com/moby/sys/user v0.4.0/go.mod h1:bG+tYYYJgaMtRKgEmuueC0hJEAZWwtIbZTB+85uoHjs= github.com/moby/sys/userns v0.1.0 h1:tVLXkFOxVu9A64/yh59slHVv9ahO9UIev4JZusOLG/g= github.com/moby/sys/userns v0.1.0/go.mod h1:IHUYgu/kao6N8YZlp9Cf444ySSvCmDlmzUcYfDHOl28= -github.com/moby/term v0.0.0-20221205130635-1aeaba878587 h1:HfkjXDfhgVaN5rmueG8cL8KKeFNecRCXFhaJ2qZ5SKA= -github.com/moby/term v0.0.0-20221205130635-1aeaba878587/go.mod h1:8FzsFHVUBGZdbDsJw/ot+X+d5HLUbvklYLJ9uGfcI3Y= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= @@ -763,8 +749,6 @@ github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3Rllmb github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= github.com/modern-go/reflect2 v1.0.3-0.20250322232337-35a7c28c31ee h1:W5t00kpgFdJifH4BDsTlE89Zl93FEloxaWZfGcifgq8= github.com/modern-go/reflect2 v1.0.3-0.20250322232337-35a7c28c31ee/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= -github.com/morikuni/aec v1.0.0 h1:nP9CBfwrvYnBRgY6qfDQkygYDmYwOilePFkwzv4dU8A= -github.com/morikuni/aec v1.0.0/go.mod h1:BbKIizmSmc5MMPqRYbxO4ZU0S0+P200+tUnFx7PXmsc= github.com/muesli/ansi v0.0.0-20230316100256-276c6243b2f6 h1:ZK8zHtRHOkbHy6Mmr5D264iyp3TiX5OmNcI5cIARiQI= github.com/muesli/ansi v0.0.0-20230316100256-276c6243b2f6/go.mod h1:CJlz5H+gyd6CUWT45Oy4q24RdLyn7Md9Vj2/ldJBSIo= github.com/muesli/cancelreader v0.2.2 h1:3I4Kt4BQjOR54NavqnDogx/MIoWBFa0StPA8ELUXHmA= @@ -874,8 +858,8 @@ github.com/sassoftware/go-rpmutils v0.4.0/go.mod h1:3goNWi7PGAT3/dlql2lv3+MSN5jN github.com/scylladb/go-set v1.0.3-0.20200225121959-cc7b2070d91e h1:7q6NSFZDeGfvvtIRwBrU/aegEYJYmvev0cHAwo17zZQ= github.com/scylladb/go-set v1.0.3-0.20200225121959-cc7b2070d91e/go.mod h1:DkpGd78rljTxKAnTDPFqXSGxvETQnJyuSOQwsHycqfs= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= -github.com/sebdah/goldie/v2 v2.7.1 h1:PkBHymaYdtvEkZV7TmyqKxdmn5/Vcj+8TpATWZjnG5E= -github.com/sebdah/goldie/v2 v2.7.1/go.mod h1:oZ9fp0+se1eapSRjfYbsV/0Hqhbuu3bJVvKI/NNtssI= +github.com/sebdah/goldie/v2 v2.8.0 h1:dZb9wR8q5++oplmEiJT+U/5KyotVD+HNGCAc5gNr8rc= +github.com/sebdah/goldie/v2 v2.8.0/go.mod h1:oZ9fp0+se1eapSRjfYbsV/0Hqhbuu3bJVvKI/NNtssI= github.com/sergi/go-diff v1.1.0/go.mod h1:STckp+ISIX8hZLjrqAeVduY0gWCT9IjLuqbuNXdaHfM= github.com/sergi/go-diff v1.2.0/go.mod h1:STckp+ISIX8hZLjrqAeVduY0gWCT9IjLuqbuNXdaHfM= github.com/sergi/go-diff v1.4.0 h1:n/SP9D5ad1fORl+llWyN+D6qoUETXNZARKjyY2/KVCw= @@ -885,8 +869,8 @@ github.com/shopspring/decimal v1.4.0/go.mod h1:gawqmDU56v4yIKSwfBSFip1HdCCXN8/+D github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= github.com/sirupsen/logrus v1.7.0/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= -github.com/sirupsen/logrus v1.9.4-0.20230606125235-dd1b4c2e81af h1:Sp5TG9f7K39yfB+If0vjp97vuT74F72r8hfRpP8jLU0= -github.com/sirupsen/logrus v1.9.4-0.20230606125235-dd1b4c2e81af/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= +github.com/sirupsen/logrus v1.9.4 h1:TsZE7l11zFCLZnZ+teH4Umoq5BhEIfIzfRDZ1Uzql2w= +github.com/sirupsen/logrus v1.9.4/go.mod h1:ftWc9WdOfJ0a92nsE2jF5u5ZwH8Bv2zdeOC42RjbV2g= github.com/skeema/knownhosts v1.3.1 h1:X2osQ+RAjK76shCbvhHHHVl3ZlgDm8apHEHFqRjnBY8= github.com/skeema/knownhosts v1.3.1/go.mod h1:r7KTdC8l4uxWRyK2TpQZ/1o5HaSzh06ePQNxPwTcfiY= github.com/smallnest/ringbuffer v0.0.0-20241116012123-461381446e3d h1:3VwvTjiRPA7cqtgOWddEL+JrcijMlXUmj99c/6YyZoY= @@ -912,8 +896,9 @@ github.com/spf13/cobra v1.10.2 h1:DMTTonx5m65Ic0GOoRY2c16WCbHxOOw6xxezuLaBpcU= github.com/spf13/cobra v1.10.2/go.mod h1:7C1pvHqHw5A4vrJfjNwvOdzYu0Gml16OCs2GRiTUUS4= github.com/spf13/jwalterweatherman v1.1.0/go.mod h1:aNWZUN0dPAAO/Ljvb5BEdw96iTZ0EXowPYD95IqWIGo= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= -github.com/spf13/pflag v1.0.9 h1:9exaQaMOCwffKiiiYk6/BndUBv+iRViNW+4lEMi0PvY= github.com/spf13/pflag v1.0.9/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= +github.com/spf13/pflag v1.0.10 h1:4EBh2KAYBwaONj6b2Ye1GiHfwjqyROoF4RwYO+vPwFk= +github.com/spf13/pflag v1.0.10/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= github.com/spf13/viper v1.10.0/go.mod h1:SoyBPwAtKDzypXNDFKN5kzH7ppppbGZtls1UpIy5AsM= github.com/spf13/viper v1.20.0 h1:zrxIyR3RQIOsarIrgL8+sAvALXul9jeEPa06Y0Ph6vY= github.com/spf13/viper v1.20.0/go.mod h1:P9Mdzt1zoHIG8m2eZQinpiBjo6kCmZSKBClNNqjJvu4= @@ -940,8 +925,8 @@ github.com/stretchr/testify v1.11.1/go.mod h1:wZwfW3scLgRK+23gO65QZefKpKQRnfz6sD github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw= github.com/subosito/gotenv v1.6.0 h1:9NlTDc1FTs4qu0DDq7AEtTPNw6SVm7uBMsUCUjABIf8= github.com/subosito/gotenv v1.6.0/go.mod h1:Dk4QP5c2W3ibzajGcXpNraDfq2IrhjMIvMSWPKKo0FU= -github.com/sylabs/sif/v2 v2.22.0 h1:Y+xXufp4RdgZe02SR3nWEg7S6q4tPWN237WHYzkDSKA= -github.com/sylabs/sif/v2 v2.22.0/go.mod h1:W1XhWTmG1KcG7j5a3KSYdMcUIFvbs240w/MMVW627hs= +github.com/sylabs/sif/v2 v2.23.0 h1:VWJC7iryINdIgyIK8EdxMCJkx8EDPVlvFaskgY+ruFk= +github.com/sylabs/sif/v2 v2.23.0/go.mod h1:0UJk7MMSQS2n/95yYd+CvAfK7K2mE0aWHRYYybd+ouw= github.com/sylabs/squashfs v1.0.6 h1:PvJcDzxr+vIm2kH56mEMbaOzvGu79gK7P7IX+R7BDZI= github.com/sylabs/squashfs v1.0.6/go.mod h1:DlDeUawVXLWAsSRa085Eo0ZenGzAB32JdAUFaB0LZfE= github.com/terminalstatic/go-xsd-validate v0.1.6 h1:TenYeQ3eY631qNi1/cTmLH/s2slHPRKTTHT+XSHkepo= @@ -970,8 +955,8 @@ github.com/vifraa/gopom v1.0.0 h1:L9XlKbyvid8PAIK8nr0lihMApJQg/12OBvMA28BcWh0= github.com/vifraa/gopom v1.0.0/go.mod h1:oPa1dcrGrtlO37WPDBm5SqHAT+wTgF8An1Q71Z6Vv4o= github.com/wagoodman/go-partybus v0.0.0-20230516145632-8ccac152c651 h1:jIVmlAFIqV3d+DOxazTR9v+zgj8+VYuQBzPgBZvWBHA= github.com/wagoodman/go-partybus v0.0.0-20230516145632-8ccac152c651/go.mod h1:b26F2tHLqaoRQf8DywqzVaV1MQ9yvjb0OMcNl7Nxu20= -github.com/wagoodman/go-progress v0.0.0-20230925121702-07e42b3cdba0 h1:0KGbf+0SMg+UFy4e1A/CPVvXn21f1qtWdeJwxZFoQG8= -github.com/wagoodman/go-progress v0.0.0-20230925121702-07e42b3cdba0/go.mod h1:jLXFoL31zFaHKAAyZUh+sxiTDFe1L1ZHrcK2T1itVKA= +github.com/wagoodman/go-progress v0.0.0-20260303201901-10176f79b2c0 h1:EHsPe0Q0ANoLOZff1dBLAyeWLTA4sbPTpGI+2zb0FnM= +github.com/wagoodman/go-progress v0.0.0-20260303201901-10176f79b2c0/go.mod h1:g/D9uEUFp5YLyciwCpVsSOZOm56hfv4rzGJod6MlqIM= github.com/wk8/go-ordered-map/v2 v2.1.8 h1:5h/BUHu93oj4gIdvHHHGsScSTMijfx5PeYkE/fJgbpc= github.com/wk8/go-ordered-map/v2 v2.1.8/go.mod h1:5nJHM5DyteebpVlHnWMV0rPz6Zp7+xBAnxjb1X5vnTw= github.com/xanzy/ssh-agent v0.3.3 h1:+/15pJfg/RsTxqYcX6fHqOXZwwMP+2VyYWJeWM2qQFM= @@ -1025,10 +1010,6 @@ go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.61.0 h1:F7Jx+6h go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.61.0/go.mod h1:UHB22Z8QsdRDrnAtX4PntOl36ajSxcdUMt1sF7Y6E7Q= go.opentelemetry.io/otel v1.39.0 h1:8yPrr/S0ND9QEfTfdP9V+SiwT4E0G7Y5MO7p85nis48= go.opentelemetry.io/otel v1.39.0/go.mod h1:kLlFTywNWrFyEdH0oj2xK0bFYZtHRYUdv1NklR/tgc8= -go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.35.0 h1:1fTNlAIJZGWLP5FVu0fikVry1IsiUnXjf7QFvoNN3Xw= -go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.35.0/go.mod h1:zjPK58DtkqQFn+YUMbx0M2XV3QgKU0gS9LeGohREyK4= -go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.35.0 h1:xJ2qHD0C1BeYVTLLR9sX12+Qb95kfeD/byKj6Ky1pXg= -go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.35.0/go.mod h1:u5BF1xyjstDowA1R5QAO9JHzqK+ublenEW/dyqTjBVk= go.opentelemetry.io/otel/exporters/stdout/stdoutmetric v1.38.0 h1:wm/Q0GAAykXv83wzcKzGGqAnnfLFyFe7RslekZuv+VI= go.opentelemetry.io/otel/exporters/stdout/stdoutmetric v1.38.0/go.mod h1:ra3Pa40+oKjvYh+ZD3EdxFZZB0xdMfuileHAm4nNN7w= go.opentelemetry.io/otel/metric v1.39.0 h1:d1UzonvEZriVfpNKEVmHXbdf909uGTOQjA0HF0Ls5Q0= @@ -1040,8 +1021,6 @@ go.opentelemetry.io/otel/sdk/metric v1.39.0/go.mod h1:xq9HEVH7qeX69/JnwEfp6fVq5w go.opentelemetry.io/otel/trace v1.39.0 h1:2d2vfpEDmCJ5zVYz7ijaJdOF59xLomrvj7bjt6/qCJI= go.opentelemetry.io/otel/trace v1.39.0/go.mod h1:88w4/PnZSazkGzz/w84VHpQafiU4EtqqlVdxWy+rNOA= go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI= -go.opentelemetry.io/proto/otlp v1.5.0 h1:xJvq7gMzB31/d406fB8U5CBdyQGw4P399D1aQWU/3i4= -go.opentelemetry.io/proto/otlp v1.5.0/go.mod h1:keN8WnHxOy8PG0rQZjJJ5A2ebUoafqWp0eVQ4yIXvJ4= go.uber.org/atomic v1.7.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc= go.uber.org/atomic v1.9.0 h1:ECmE8Bn/WFTYwEW/bpKD3M8VtR/zQVbavAoalC1PYyE= go.uber.org/atomic v1.9.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc= @@ -1173,8 +1152,8 @@ golang.org/x/oauth2 v0.0.0-20210805134026-6f1e6394065a/go.mod h1:KelEdhl1UZF7XfJ golang.org/x/oauth2 v0.0.0-20210819190943-2bc19b11175f/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20211005180243-6b3c2da341f1/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= -golang.org/x/oauth2 v0.33.0 h1:4Q+qn+E5z8gPRJfmRy7C2gGG3T4jIprK6aSYgTXGRpo= -golang.org/x/oauth2 v0.33.0/go.mod h1:lzm5WQJQwKZ3nwavOZ3IS5Aulzxi68dUSgRHujetwEA= +golang.org/x/oauth2 v0.35.0 h1:Mv2mzuHuZuY2+bkyWXIHMfhNdJAdwW3FuWeCPYN5GVQ= +golang.org/x/oauth2 v0.35.0/go.mod h1:lzm5WQJQwKZ3nwavOZ3IS5Aulzxi68dUSgRHujetwEA= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= @@ -1505,8 +1484,8 @@ google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlba google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= google.golang.org/protobuf v1.27.1/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= -google.golang.org/protobuf v1.36.10 h1:AYd7cD/uASjIL6Q9LiTjz8JLcrh/88q5UObnmY3aOOE= -google.golang.org/protobuf v1.36.10/go.mod h1:HTf+CrKn2C3g5S8VImy6tdcUvCska2kB7j23XfzDpco= +google.golang.org/protobuf v1.36.11 h1:fV6ZwhNocDyBLK0dj+fg8ektcVegBBuEolpbTQyBNVE= +google.golang.org/protobuf v1.36.11/go.mod h1:HTf+CrKn2C3g5S8VImy6tdcUvCska2kB7j23XfzDpco= gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= @@ -1528,8 +1507,8 @@ gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -gotest.tools/v3 v3.0.3 h1:4AuOwCGf4lLR9u3YOe2awrHygurzhO/HeQ6laiA6Sx0= -gotest.tools/v3 v3.0.3/go.mod h1:Z7Lb0S5l+klDB31fvDQX8ss/FlKDxtlFlw3Oa8Ymbl8= +gotest.tools/v3 v3.5.2 h1:7koQfIKdy+I8UTetycgUqXWSDwpgv193Ka+qRsmBY8Q= +gotest.tools/v3 v3.5.2/go.mod h1:LtdLGcnqToBH83WByAAi/wiwSFCArdFIUV/xxN4pcjA= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190418001031-e561f6794a2a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= @@ -1565,6 +1544,8 @@ modernc.org/strutil v1.2.1 h1:UneZBkQA+DX2Rp35KcM69cSsNES9ly8mQWD71HKlOA0= modernc.org/strutil v1.2.1/go.mod h1:EHkiggD70koQxjVdSBM3JKM7k6L0FbGE5eymy9i3B9A= modernc.org/token v1.1.0 h1:Xl7Ap9dKaEs5kLoOQeQmPWevfnk/DM5qcLcYlA8ys6Y= modernc.org/token v1.1.0/go.mod h1:UGzOrNV1mAFSEB63lOFHIpNRUVMvYTc6yu1SMY/XTDM= +pgregory.net/rapid v1.2.0 h1:keKAYRcjm+e1F0oAuU5F5+YPAWcyxNNRK2wud503Gnk= +pgregory.net/rapid v1.2.0/go.mod h1:PY5XlDGj0+V1FCq0o192FdRhpKHGTRIWBgqjDBTrq04= rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0= rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA= diff --git a/internal/capabilities/generate/README.md b/internal/capabilities/generate/README.md index a9a7833ce..7657ccd66 100644 --- a/internal/capabilities/generate/README.md +++ b/internal/capabilities/generate/README.md @@ -48,7 +48,7 @@ graph LR end subgraph "Test Inputs" - B1[test-fixtures/
test-observations.json] + B1[testdata/
test-observations.json] end subgraph "Discovery Processes" @@ -400,7 +400,7 @@ func NewGoModuleBinaryCataloger(cfg golang.CatalogerConfig) pkg.Cataloger **What it finds:** metadata types and package types each parser produces **Process:** -1. Find all `test-fixtures/test-observations.json` files +1. Find all `testdata/test-observations.json` files 2. Parse JSON which contains: ```json { @@ -503,7 +503,7 @@ func (c golangConfig) DescribeFields(opts ...options.DescribeFieldsOption) []opt #### test-observations.json Files -**Location:** `syft/pkg/cataloger/*/test-fixtures/test-observations.json` +**Location:** `syft/pkg/cataloger/*/testdata/test-observations.json` **Purpose:** records what metadata and package types each parser produces during test execution @@ -515,7 +515,7 @@ func TestGoModuleCataloger(t *testing.T) { tester := NewGoModuleBinaryCataloger() pkgtest.NewCatalogTester(). - FromDirectory(t, "test-fixtures/go-module-fixture"). + FromDirectory(t, "testdata/go-module-fixture"). TestCataloger(t, tester) // Auto-writes observations on first run } ``` @@ -832,7 +832,7 @@ capabilities: **Fix:** update tests to use `pkgtest.CatalogTester`: ```go pkgtest.NewCatalogTester(). - FromDirectory(t, "test-fixtures/my-fixture"). + FromDirectory(t, "testdata/my-fixture"). TestCataloger(t, myCataloger) ``` @@ -1071,7 +1071,7 @@ SYFT_ENABLE_COMPLETENESS_TESTS=true go test ./internal/capabilities/... # 7. Commit git add syft/pkg/cataloger/mynew/capabilities.yaml -git add syft/pkg/cataloger/mynew/test-fixtures/test-observations.json +git add syft/pkg/cataloger/mynew/testdata/test-observations.json git commit ``` @@ -1129,7 +1129,7 @@ go generate ./internal/capabilities # 5. Commit git add syft/pkg/cataloger/*/capabilities.yaml -git add syft/pkg/cataloger/something/test-fixtures/test-observations.json +git add syft/pkg/cataloger/something/testdata/test-observations.json git commit ``` @@ -1261,7 +1261,7 @@ go generate ./internal/capabilities ```go // Update test to use pkgtest pkgtest.NewCatalogTester(). - FromDirectory(t, "test-fixtures/my-fixture"). + FromDirectory(t, "testdata/my-fixture"). TestCataloger(t, myCataloger) // Run tests @@ -1294,7 +1294,7 @@ func TestMyParser(t *testing.T) { func TestMyParser(t *testing.T) { cataloger := NewMyCataloger() pkgtest.NewCatalogTester(). - FromDirectory(t, "test-fixtures/my-fixture"). + FromDirectory(t, "testdata/my-fixture"). TestCataloger(t, cataloger) } ``` diff --git a/internal/capabilities/generate/discover_metadata.go b/internal/capabilities/generate/discover_metadata.go index 603ad8258..636683edb 100644 --- a/internal/capabilities/generate/discover_metadata.go +++ b/internal/capabilities/generate/discover_metadata.go @@ -83,7 +83,7 @@ func (idx *TestObservationIndex) extractCustomCatalogerData() (map[string][]stri // discoverMetadataTypes searches for test-observations.json files and merges metadata type information // into the discovered catalogers. Returns maps of custom cataloger metadata types and package types. func discoverMetadataTypes(repoRoot string, discovered map[string]DiscoveredCataloger) (map[string][]string, map[string][]string, error) { - testFixtureDirs, err := internal.FindTestFixtureDirs(repoRoot) + testDataDirs, err := internal.FindTestDataDirs(repoRoot) if err != nil { return nil, nil, err } @@ -92,7 +92,7 @@ func discoverMetadataTypes(repoRoot string, discovered map[string]DiscoveredCata index := newTestObservationIndex() // read all test-observations files and merge into index - for _, dir := range testFixtureDirs { + for _, dir := range testDataDirs { observationsFile := filepath.Join(dir, "test-observations.json") if observations, err := internal.ReadTestObservations(observationsFile); err == nil { mergeTestObservations(observations, index) diff --git a/internal/capabilities/internal/fixtures.go b/internal/capabilities/internal/fixtures.go index b6b7a677a..a3472e58a 100644 --- a/internal/capabilities/internal/fixtures.go +++ b/internal/capabilities/internal/fixtures.go @@ -9,17 +9,17 @@ import ( "github.com/anchore/syft/internal/capabilities/pkgtestobservation" ) -// FindTestFixtureDirs walks the cataloger directory tree and returns all test-fixtures directories -func FindTestFixtureDirs(repoRoot string) ([]string, error) { +// FindTestDataDirs walks the cataloger directory tree and returns all testdata directories +func FindTestDataDirs(repoRoot string) ([]string, error) { catalogerRoot := filepath.Join(repoRoot, "syft", "pkg", "cataloger") - var testFixtureDirs []string + var testDataDirs []string err := filepath.Walk(catalogerRoot, func(path string, info os.FileInfo, err error) error { if err != nil { return err } - if info.IsDir() && info.Name() == "test-fixtures" { - testFixtureDirs = append(testFixtureDirs, path) + if info.IsDir() && info.Name() == "testdata" { + testDataDirs = append(testDataDirs, path) } return nil }) @@ -27,7 +27,7 @@ func FindTestFixtureDirs(repoRoot string) ([]string, error) { return nil, fmt.Errorf("failed to walk cataloger directory: %w", err) } - return testFixtureDirs, nil + return testDataDirs, nil } // ReadTestObservations reads and parses a test-observations.json file diff --git a/internal/capabilities/internal/load_capabilities_test.go b/internal/capabilities/internal/load_capabilities_test.go index a7c49a038..80bfbae97 100644 --- a/internal/capabilities/internal/load_capabilities_test.go +++ b/internal/capabilities/internal/load_capabilities_test.go @@ -1233,7 +1233,7 @@ func TestCatalogerDataQuality(t *testing.T) { } // TestCatalogersHaveTestObservations ensures that all custom catalogers (and optionally parsers) have -// test observations recorded in test-fixtures/test-observations.json, which proves they are using the +// test observations recorded in testdata/test-observations.json, which proves they are using the // pkgtest.CatalogTester helpers and have test coverage. func TestCatalogersHaveTestObservations(t *testing.T) { checkCompletenessTestsEnabled(t) @@ -1249,11 +1249,11 @@ func TestCatalogersHaveTestObservations(t *testing.T) { observedCatalogers := strset.New() observedParsers := make(map[string]*strset.Set) // package -> parser set - // walk test-fixtures directories to find test-observations.json files - testFixtureDirs, err := FindTestFixtureDirs(repoRoot) + // walk testdata directories to find test-observations.json files + testDataDirs, err := FindTestDataDirs(repoRoot) require.NoError(t, err) - for _, dir := range testFixtureDirs { + for _, dir := range testDataDirs { observationsFile := filepath.Join(dir, "test-observations.json") if _, err := os.Stat(observationsFile); os.IsNotExist(err) { continue diff --git a/internal/file/digest_test.go b/internal/file/digest_test.go index 87e45af40..f4c0b6b4b 100644 --- a/internal/file/digest_test.go +++ b/internal/file/digest_test.go @@ -43,7 +43,7 @@ func TestNewDigestsFromFile(t *testing.T) { }{ { name: "check supported hash algorithms", - fixture: "test-fixtures/digest.txt", + fixture: "testdata/digest.txt", hashes: supportedHashAlgorithms(), want: []file.Digest{ { @@ -74,7 +74,7 @@ func TestNewDigestsFromFile(t *testing.T) { }, { name: "empty file has valid checksums", - fixture: "test-fixtures/empty.txt", + fixture: "testdata/empty.txt", hashes: supportedHashAlgorithms(), want: []file.Digest{ { diff --git a/internal/file/test-fixtures/digest.txt b/internal/file/testdata/digest.txt similarity index 100% rename from internal/file/test-fixtures/digest.txt rename to internal/file/testdata/digest.txt diff --git a/internal/file/test-fixtures/empty.txt b/internal/file/testdata/empty.txt similarity index 100% rename from internal/file/test-fixtures/empty.txt rename to internal/file/testdata/empty.txt diff --git a/internal/file/test-fixtures/generate-zip-fixture-from-source-dir.sh b/internal/file/testdata/generate-zip-fixture-from-source-dir.sh similarity index 100% rename from internal/file/test-fixtures/generate-zip-fixture-from-source-dir.sh rename to internal/file/testdata/generate-zip-fixture-from-source-dir.sh diff --git a/internal/file/test-fixtures/zip-source/b-file.txt b/internal/file/testdata/zip-source/b-file.txt similarity index 100% rename from internal/file/test-fixtures/zip-source/b-file.txt rename to internal/file/testdata/zip-source/b-file.txt diff --git a/internal/file/test-fixtures/zip-source/b-file/in-subdir.txt b/internal/file/testdata/zip-source/b-file/in-subdir.txt similarity index 100% rename from internal/file/test-fixtures/zip-source/b-file/in-subdir.txt rename to internal/file/testdata/zip-source/b-file/in-subdir.txt diff --git a/internal/file/test-fixtures/zip-source/some-dir/a-file.txt b/internal/file/testdata/zip-source/some-dir/a-file.txt similarity index 100% rename from internal/file/test-fixtures/zip-source/some-dir/a-file.txt rename to internal/file/testdata/zip-source/some-dir/a-file.txt diff --git a/internal/file/zip_file_helpers_test.go b/internal/file/zip_file_helpers_test.go index 22f92e97b..ad15f785c 100644 --- a/internal/file/zip_file_helpers_test.go +++ b/internal/file/zip_file_helpers_test.go @@ -33,7 +33,7 @@ func createZipArchive(t testing.TB, sourceDirPath, destinationArchivePath string } cmd := exec.Command("./generate-zip-fixture-from-source-dir.sh", destinationArchivePath, path.Base(sourceDirPath), zip64Arg) - cmd.Dir = filepath.Join(cwd, "test-fixtures") + cmd.Dir = filepath.Join(cwd, "testdata") if err := cmd.Start(); err != nil { t.Fatalf("unable to start generate zip fixture script: %+v", err) diff --git a/internal/file/zip_file_manifest_test.go b/internal/file/zip_file_manifest_test.go index 339048a1d..e169e475e 100644 --- a/internal/file/zip_file_manifest_test.go +++ b/internal/file/zip_file_manifest_test.go @@ -19,7 +19,7 @@ func TestNewZipFileManifest(t *testing.T) { t.Fatal(err) } - sourceDirPath := path.Join(cwd, "test-fixtures", "zip-source") + sourceDirPath := path.Join(cwd, "testdata", "zip-source") err = ensureNestedZipExists(t, sourceDirPath) if err != nil { t.Fatal(err) @@ -59,7 +59,7 @@ func TestNewZip64FileManifest(t *testing.T) { t.Fatal(err) } - sourceDirPath := path.Join(cwd, "test-fixtures", "zip-source") + sourceDirPath := path.Join(cwd, "testdata", "zip-source") archiveFilePath := setupZipFileTest(t, sourceDirPath, true) actual, err := NewZipFileManifest(context.Background(), archiveFilePath) @@ -94,7 +94,7 @@ func TestZipFileManifest_GlobMatch(t *testing.T) { t.Fatal(err) } - sourceDirPath := path.Join(cwd, "test-fixtures", "zip-source") + sourceDirPath := path.Join(cwd, "testdata", "zip-source") err = ensureNestedZipExists(t, sourceDirPath) if err != nil { t.Fatal(err) diff --git a/internal/file/zip_file_traversal_test.go b/internal/file/zip_file_traversal_test.go index d52a21ced..bed493739 100644 --- a/internal/file/zip_file_traversal_test.go +++ b/internal/file/zip_file_traversal_test.go @@ -47,7 +47,7 @@ func TestUnzipToDir(t *testing.T) { t.Fatal(err) } - goldenRootDir := filepath.Join(cwd, "test-fixtures") + goldenRootDir := filepath.Join(cwd, "testdata") sourceDirPath := path.Join(goldenRootDir, "zip-source") archiveFilePath := setupZipFileTest(t, sourceDirPath, false) diff --git a/internal/licenses/find_evidence_test.go b/internal/licenses/find_evidence_test.go index 6ebf79f4d..0f2f9ba5f 100644 --- a/internal/licenses/find_evidence_test.go +++ b/internal/licenses/find_evidence_test.go @@ -19,13 +19,13 @@ func TestDefaultScanner_FindEvidence(t *testing.T) { }{ { name: "Single licenses are able to be recognized and returned Apache 2.0", - fixture: "test-fixtures/apache-license-2.0", + fixture: "testdata/apache-license-2.0", wantIDs: []string{"Apache-2.0"}, minMatch: 1, }, { name: "Multiple Licenses are returned as evidence with duplicates at different offset", - fixture: "test-fixtures/multi-license", + fixture: "testdata/multi-license", wantIDs: []string{ "MIT", "MIT", diff --git a/internal/licenses/test-fixtures/Knuth-CTAN b/internal/licenses/testdata/Knuth-CTAN similarity index 100% rename from internal/licenses/test-fixtures/Knuth-CTAN rename to internal/licenses/testdata/Knuth-CTAN diff --git a/internal/licenses/test-fixtures/apache-license-2.0 b/internal/licenses/testdata/apache-license-2.0 similarity index 100% rename from internal/licenses/test-fixtures/apache-license-2.0 rename to internal/licenses/testdata/apache-license-2.0 diff --git a/internal/licenses/test-fixtures/multi-license b/internal/licenses/testdata/multi-license similarity index 100% rename from internal/licenses/test-fixtures/multi-license rename to internal/licenses/testdata/multi-license diff --git a/internal/licenses/test-fixtures/nvidia-software-and-cuda-supplement b/internal/licenses/testdata/nvidia-software-and-cuda-supplement similarity index 100% rename from internal/licenses/test-fixtures/nvidia-software-and-cuda-supplement rename to internal/licenses/testdata/nvidia-software-and-cuda-supplement diff --git a/internal/os/test-fixtures/not_rhel/Dockerfile b/internal/os/testdata/not_rhel/Dockerfile similarity index 100% rename from internal/os/test-fixtures/not_rhel/Dockerfile rename to internal/os/testdata/not_rhel/Dockerfile diff --git a/internal/os/test-fixtures/not_rhel/etc/os-release b/internal/os/testdata/not_rhel/etc/os-release similarity index 100% rename from internal/os/test-fixtures/not_rhel/etc/os-release rename to internal/os/testdata/not_rhel/etc/os-release diff --git a/internal/os/test-fixtures/not_rhel/root/buildinfo/content_manifests/driver-toolkit-container-v4.16.0-202411210647.p0.g1d5732f.assembly.stream.el9.json b/internal/os/testdata/not_rhel/root/buildinfo/content_manifests/driver-toolkit-container-v4.16.0-202411210647.p0.g1d5732f.assembly.stream.el9.json similarity index 100% rename from internal/os/test-fixtures/not_rhel/root/buildinfo/content_manifests/driver-toolkit-container-v4.16.0-202411210647.p0.g1d5732f.assembly.stream.el9.json rename to internal/os/testdata/not_rhel/root/buildinfo/content_manifests/driver-toolkit-container-v4.16.0-202411210647.p0.g1d5732f.assembly.stream.el9.json diff --git a/internal/os/test-fixtures/rhel_content_manifests/Dockerfile b/internal/os/testdata/rhel_content_manifests/Dockerfile similarity index 100% rename from internal/os/test-fixtures/rhel_content_manifests/Dockerfile rename to internal/os/testdata/rhel_content_manifests/Dockerfile diff --git a/internal/os/test-fixtures/rhel_content_manifests/etc/os-release b/internal/os/testdata/rhel_content_manifests/etc/os-release similarity index 100% rename from internal/os/test-fixtures/rhel_content_manifests/etc/os-release rename to internal/os/testdata/rhel_content_manifests/etc/os-release diff --git a/internal/os/test-fixtures/rhel_content_manifests/root/buildinfo/content_manifests/driver-toolkit-container-v4.16.0-202411210647.p0.g1d5732f.assembly.stream.el9.json b/internal/os/testdata/rhel_content_manifests/root/buildinfo/content_manifests/driver-toolkit-container-v4.16.0-202411210647.p0.g1d5732f.assembly.stream.el9.json similarity index 100% rename from internal/os/test-fixtures/rhel_content_manifests/root/buildinfo/content_manifests/driver-toolkit-container-v4.16.0-202411210647.p0.g1d5732f.assembly.stream.el9.json rename to internal/os/testdata/rhel_content_manifests/root/buildinfo/content_manifests/driver-toolkit-container-v4.16.0-202411210647.p0.g1d5732f.assembly.stream.el9.json diff --git a/internal/os/test-fixtures/rhel_content_manifests/root/buildinfo/content_manifests/openshift-base-rhel9-container-v4.16.0-202411190033.p0.gb45ea65.assembly.stream.el9.json b/internal/os/testdata/rhel_content_manifests/root/buildinfo/content_manifests/openshift-base-rhel9-container-v4.16.0-202411190033.p0.gb45ea65.assembly.stream.el9.json similarity index 100% rename from internal/os/test-fixtures/rhel_content_manifests/root/buildinfo/content_manifests/openshift-base-rhel9-container-v4.16.0-202411190033.p0.gb45ea65.assembly.stream.el9.json rename to internal/os/testdata/rhel_content_manifests/root/buildinfo/content_manifests/openshift-base-rhel9-container-v4.16.0-202411190033.p0.gb45ea65.assembly.stream.el9.json diff --git a/internal/os/test-fixtures/rhel_no_manifests/Dockerfile b/internal/os/testdata/rhel_no_manifests/Dockerfile similarity index 100% rename from internal/os/test-fixtures/rhel_no_manifests/Dockerfile rename to internal/os/testdata/rhel_no_manifests/Dockerfile diff --git a/internal/os/test-fixtures/rhel_no_manifests/etc/os-release b/internal/os/testdata/rhel_no_manifests/etc/os-release similarity index 100% rename from internal/os/test-fixtures/rhel_no_manifests/etc/os-release rename to internal/os/testdata/rhel_no_manifests/etc/os-release diff --git a/internal/relationship/binary/test-fixtures/elf-test-fixtures b/internal/relationship/binary/test-fixtures/elf-test-fixtures deleted file mode 120000 index 883705cd4..000000000 --- a/internal/relationship/binary/test-fixtures/elf-test-fixtures +++ /dev/null @@ -1 +0,0 @@ -../../../../syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures \ No newline at end of file diff --git a/internal/relationship/binary/testdata/elf-testdata b/internal/relationship/binary/testdata/elf-testdata new file mode 120000 index 000000000..e9ac42346 --- /dev/null +++ b/internal/relationship/binary/testdata/elf-testdata @@ -0,0 +1 @@ +../../../../syft/pkg/cataloger/binary/testdata/elf-testdata \ No newline at end of file diff --git a/internal/spdxlicense/generate/generate_license_list_test.go b/internal/spdxlicense/generate/generate_license_list_test.go index 978f5eaf6..60df78e67 100644 --- a/internal/spdxlicense/generate/generate_license_list_test.go +++ b/internal/spdxlicense/generate/generate_license_list_test.go @@ -55,7 +55,7 @@ func Test_processSPDXLicense(t *testing.T) { want map[string]string }{ { - fixture: "test-fixtures/licenses.json", + fixture: "testdata/licenses.json", want: map[string]string{ "0bsd": "0BSD", "aal": "AAL", diff --git a/internal/spdxlicense/generate/test-fixtures/licenses.json b/internal/spdxlicense/generate/testdata/licenses.json similarity index 100% rename from internal/spdxlicense/generate/test-fixtures/licenses.json rename to internal/spdxlicense/generate/testdata/licenses.json diff --git a/internal/testutils/golden_files.go b/internal/testutils/golden_files.go new file mode 100644 index 000000000..1051f6525 --- /dev/null +++ b/internal/testutils/golden_files.go @@ -0,0 +1,69 @@ +package testutils + +import ( + "io" + "os" + "path" + "path/filepath" + "strings" + "testing" +) + +const ( + TestDataDir = "testdata" + GoldenFileDirName = "snapshot" + GoldenFileExt = ".golden" + GoldenFileDirPath = TestDataDir + string(filepath.Separator) + GoldenFileDirName +) + +func GetGoldenFilePath(t *testing.T) string { + t.Helper() + // when using table-driven-tests, the `t.Name()` results in a string with slashes + // which makes it impossible to reference in a filesystem, producing a "No such file or directory" + filename := strings.ReplaceAll(t.Name(), "/", "_") + return path.Join(GoldenFileDirPath, filename+GoldenFileExt) +} + +func UpdateGoldenFileContents(t *testing.T, contents []byte) { + t.Helper() + + goldenFilePath := GetGoldenFilePath(t) + + t.Log(dangerText("!!! UPDATING GOLDEN FILE !!!"), goldenFilePath) + + err := os.WriteFile(goldenFilePath, contents, 0600) + if err != nil { + t.Fatalf("could not update golden file (%s): %+v", goldenFilePath, err) + } +} + +func GetGoldenFileContents(t *testing.T) []byte { + t.Helper() + + goldenPath := GetGoldenFilePath(t) + if !fileOrDirExists(t, goldenPath) { + t.Fatalf("golden file does not exist: %s", goldenPath) + } + f, err := os.Open(goldenPath) + if err != nil { + t.Fatalf("could not open file (%s): %+v", goldenPath, err) + } + defer f.Close() + + bytes, err := io.ReadAll(f) + if err != nil { + t.Fatalf("could not read file (%s): %+v", goldenPath, err) + } + return bytes +} + +func fileOrDirExists(t *testing.T, filename string) bool { + t.Helper() + _, err := os.Stat(filename) + return !os.IsNotExist(err) +} + +// dangerText wraps text in ANSI escape codes for reverse red to make it highly visible. +func dangerText(s string) string { + return "\033[7;31m" + s + "\033[0m" +} diff --git a/syft/cpe/cpe_test.go b/syft/cpe/cpe_test.go index fd778c9a8..30e00785f 100644 --- a/syft/cpe/cpe_test.go +++ b/syft/cpe/cpe_test.go @@ -94,7 +94,7 @@ func Test_CPEParser(t *testing.T) { CPEUrl string `json:"cpe-url"` WFN Attributes `json:"wfn"` } - out, err := os.ReadFile("test-fixtures/cpe-data.json") + out, err := os.ReadFile("testdata/cpe-data.json") require.NoError(t, err) require.NoError(t, json.Unmarshal(out, &testCases)) diff --git a/syft/cpe/test-fixtures/cpe-data.json b/syft/cpe/testdata/cpe-data.json similarity index 100% rename from syft/cpe/test-fixtures/cpe-data.json rename to syft/cpe/testdata/cpe-data.json diff --git a/syft/file/cataloger/executable/elf_test.go b/syft/file/cataloger/executable/elf_test.go index fd3536cca..a380a5cd6 100644 --- a/syft/file/cataloger/executable/elf_test.go +++ b/syft/file/cataloger/executable/elf_test.go @@ -18,7 +18,7 @@ func Test_findELFSecurityFeatures(t *testing.T) { readerForFixture := func(t *testing.T, fixture string) unionreader.UnionReader { t.Helper() - f, err := os.Open(filepath.Join("test-fixtures/elf", fixture)) + f, err := os.Open(filepath.Join("testdata/elf", fixture)) require.NoError(t, err) return f } @@ -163,7 +163,7 @@ func Test_elfHasEntrypoint(t *testing.T) { readerForFixture := func(t *testing.T, fixture string) unionreader.UnionReader { t.Helper() - f, err := os.Open(filepath.Join("test-fixtures/shared-info", fixture)) + f, err := os.Open(filepath.Join("testdata/shared-info", fixture)) require.NoError(t, err) return f } @@ -196,7 +196,7 @@ func Test_elfHasEntrypoint(t *testing.T) { func Test_elfHasExports(t *testing.T) { readerForFixture := func(t *testing.T, fixture string) unionreader.UnionReader { t.Helper() - f, err := os.Open(filepath.Join("test-fixtures/shared-info", fixture)) + f, err := os.Open(filepath.Join("testdata/shared-info", fixture)) require.NoError(t, err) return f } diff --git a/syft/file/cataloger/executable/macho_test.go b/syft/file/cataloger/executable/macho_test.go index ed8816671..ed6fc5ff8 100644 --- a/syft/file/cataloger/executable/macho_test.go +++ b/syft/file/cataloger/executable/macho_test.go @@ -17,7 +17,7 @@ func Test_machoHasEntrypoint(t *testing.T) { readerForFixture := func(t *testing.T, fixture string) unionreader.UnionReader { t.Helper() - f, err := os.Open(filepath.Join("test-fixtures/shared-info", fixture)) + f, err := os.Open(filepath.Join("testdata/shared-info", fixture)) require.NoError(t, err) return f } @@ -50,7 +50,7 @@ func Test_machoHasEntrypoint(t *testing.T) { func Test_machoHasExports(t *testing.T) { readerForFixture := func(t *testing.T, fixture string) unionreader.UnionReader { t.Helper() - f, err := os.Open(filepath.Join("test-fixtures/shared-info", fixture)) + f, err := os.Open(filepath.Join("testdata/shared-info", fixture)) require.NoError(t, err) return f } @@ -88,7 +88,7 @@ func Test_machoHasExports(t *testing.T) { func Test_machoUniversal(t *testing.T) { readerForFixture := func(t *testing.T, fixture string) unionreader.UnionReader { t.Helper() - f, err := os.Open(filepath.Join("test-fixtures/shared-info", fixture)) + f, err := os.Open(filepath.Join("testdata/shared-info", fixture)) require.NoError(t, err) return f } diff --git a/syft/file/cataloger/executable/pe_test.go b/syft/file/cataloger/executable/pe_test.go index 59ea5bc47..0c4b73584 100644 --- a/syft/file/cataloger/executable/pe_test.go +++ b/syft/file/cataloger/executable/pe_test.go @@ -16,7 +16,7 @@ func Test_peHasEntrypoint(t *testing.T) { readerForFixture := func(t *testing.T, fixture string) unionreader.UnionReader { t.Helper() - f, err := os.Open(filepath.Join("test-fixtures/shared-info", fixture)) + f, err := os.Open(filepath.Join("testdata/shared-info", fixture)) require.NoError(t, err) return f } @@ -49,7 +49,7 @@ func Test_peHasEntrypoint(t *testing.T) { func Test_peHasExports(t *testing.T) { readerForFixture := func(t *testing.T, fixture string) unionreader.UnionReader { t.Helper() - f, err := os.Open(filepath.Join("test-fixtures/shared-info", fixture)) + f, err := os.Open(filepath.Join("testdata/shared-info", fixture)) require.NoError(t, err) return f } diff --git a/syft/file/cataloger/executable/test-fixtures/.gitignore b/syft/file/cataloger/executable/testdata/.gitignore similarity index 100% rename from syft/file/cataloger/executable/test-fixtures/.gitignore rename to syft/file/cataloger/executable/testdata/.gitignore diff --git a/syft/file/cataloger/executable/test-fixtures/Makefile b/syft/file/cataloger/executable/testdata/Makefile similarity index 100% rename from syft/file/cataloger/executable/test-fixtures/Makefile rename to syft/file/cataloger/executable/testdata/Makefile diff --git a/syft/file/cataloger/executable/test-fixtures/elf/.gitignore b/syft/file/cataloger/executable/testdata/elf/.gitignore similarity index 100% rename from syft/file/cataloger/executable/test-fixtures/elf/.gitignore rename to syft/file/cataloger/executable/testdata/elf/.gitignore diff --git a/syft/file/cataloger/executable/test-fixtures/elf/Dockerfile b/syft/file/cataloger/executable/testdata/elf/Dockerfile similarity index 100% rename from syft/file/cataloger/executable/test-fixtures/elf/Dockerfile rename to syft/file/cataloger/executable/testdata/elf/Dockerfile diff --git a/syft/file/cataloger/executable/test-fixtures/elf/Makefile b/syft/file/cataloger/executable/testdata/elf/Makefile similarity index 100% rename from syft/file/cataloger/executable/test-fixtures/elf/Makefile rename to syft/file/cataloger/executable/testdata/elf/Makefile diff --git a/syft/file/cataloger/executable/test-fixtures/elf/differ/__main__.py b/syft/file/cataloger/executable/testdata/elf/differ/__main__.py similarity index 100% rename from syft/file/cataloger/executable/test-fixtures/elf/differ/__main__.py rename to syft/file/cataloger/executable/testdata/elf/differ/__main__.py diff --git a/syft/file/cataloger/executable/test-fixtures/elf/expected_verify b/syft/file/cataloger/executable/testdata/elf/expected_verify similarity index 100% rename from syft/file/cataloger/executable/test-fixtures/elf/expected_verify rename to syft/file/cataloger/executable/testdata/elf/expected_verify diff --git a/syft/file/cataloger/executable/test-fixtures/elf/project/Makefile b/syft/file/cataloger/executable/testdata/elf/project/Makefile similarity index 100% rename from syft/file/cataloger/executable/test-fixtures/elf/project/Makefile rename to syft/file/cataloger/executable/testdata/elf/project/Makefile diff --git a/syft/file/cataloger/executable/test-fixtures/elf/project/lib.c b/syft/file/cataloger/executable/testdata/elf/project/lib.c similarity index 100% rename from syft/file/cataloger/executable/test-fixtures/elf/project/lib.c rename to syft/file/cataloger/executable/testdata/elf/project/lib.c diff --git a/syft/file/cataloger/executable/test-fixtures/elf/project/lib.h b/syft/file/cataloger/executable/testdata/elf/project/lib.h similarity index 100% rename from syft/file/cataloger/executable/test-fixtures/elf/project/lib.h rename to syft/file/cataloger/executable/testdata/elf/project/lib.h diff --git a/syft/file/cataloger/executable/test-fixtures/elf/project/main.c b/syft/file/cataloger/executable/testdata/elf/project/main.c similarity index 100% rename from syft/file/cataloger/executable/test-fixtures/elf/project/main.c rename to syft/file/cataloger/executable/testdata/elf/project/main.c diff --git a/syft/file/cataloger/executable/test-fixtures/shared-info/.gitignore b/syft/file/cataloger/executable/testdata/shared-info/.gitignore similarity index 100% rename from syft/file/cataloger/executable/test-fixtures/shared-info/.gitignore rename to syft/file/cataloger/executable/testdata/shared-info/.gitignore diff --git a/syft/file/cataloger/executable/test-fixtures/shared-info/Dockerfile b/syft/file/cataloger/executable/testdata/shared-info/Dockerfile similarity index 100% rename from syft/file/cataloger/executable/test-fixtures/shared-info/Dockerfile rename to syft/file/cataloger/executable/testdata/shared-info/Dockerfile diff --git a/syft/file/cataloger/executable/test-fixtures/shared-info/Makefile b/syft/file/cataloger/executable/testdata/shared-info/Makefile similarity index 100% rename from syft/file/cataloger/executable/test-fixtures/shared-info/Makefile rename to syft/file/cataloger/executable/testdata/shared-info/Makefile diff --git a/syft/file/cataloger/executable/test-fixtures/shared-info/project/Makefile b/syft/file/cataloger/executable/testdata/shared-info/project/Makefile similarity index 100% rename from syft/file/cataloger/executable/test-fixtures/shared-info/project/Makefile rename to syft/file/cataloger/executable/testdata/shared-info/project/Makefile diff --git a/syft/file/cataloger/executable/test-fixtures/shared-info/project/hello/Makefile b/syft/file/cataloger/executable/testdata/shared-info/project/hello/Makefile similarity index 100% rename from syft/file/cataloger/executable/test-fixtures/shared-info/project/hello/Makefile rename to syft/file/cataloger/executable/testdata/shared-info/project/hello/Makefile diff --git a/syft/file/cataloger/executable/test-fixtures/shared-info/project/hello/hello.c b/syft/file/cataloger/executable/testdata/shared-info/project/hello/hello.c similarity index 100% rename from syft/file/cataloger/executable/test-fixtures/shared-info/project/hello/hello.c rename to syft/file/cataloger/executable/testdata/shared-info/project/hello/hello.c diff --git a/syft/file/cataloger/executable/test-fixtures/shared-info/project/libhello/Makefile b/syft/file/cataloger/executable/testdata/shared-info/project/libhello/Makefile similarity index 100% rename from syft/file/cataloger/executable/test-fixtures/shared-info/project/libhello/Makefile rename to syft/file/cataloger/executable/testdata/shared-info/project/libhello/Makefile diff --git a/syft/file/cataloger/executable/test-fixtures/shared-info/project/libhello/hello.c b/syft/file/cataloger/executable/testdata/shared-info/project/libhello/hello.c similarity index 100% rename from syft/file/cataloger/executable/test-fixtures/shared-info/project/libhello/hello.c rename to syft/file/cataloger/executable/testdata/shared-info/project/libhello/hello.c diff --git a/syft/file/cataloger/executable/test-fixtures/shared-info/project/libhello/hello.h b/syft/file/cataloger/executable/testdata/shared-info/project/libhello/hello.h similarity index 100% rename from syft/file/cataloger/executable/test-fixtures/shared-info/project/libhello/hello.h rename to syft/file/cataloger/executable/testdata/shared-info/project/libhello/hello.h diff --git a/syft/file/cataloger/filecontent/cataloger_test.go b/syft/file/cataloger/filecontent/cataloger_test.go index db8ac1b2c..44f71d15b 100644 --- a/syft/file/cataloger/filecontent/cataloger_test.go +++ b/syft/file/cataloger/filecontent/cataloger_test.go @@ -10,7 +10,7 @@ import ( ) func TestContentsCataloger(t *testing.T) { - allFiles := []string{"test-fixtures/last/path.txt", "test-fixtures/another-path.txt", "test-fixtures/a-path.txt"} + allFiles := []string{"testdata/last/path.txt", "testdata/another-path.txt", "testdata/a-path.txt"} tests := []struct { name string @@ -21,18 +21,18 @@ func TestContentsCataloger(t *testing.T) { }{ { name: "multi-pattern", - globs: []string{"test-fixtures/last/*.txt", "test-fixtures/*.txt"}, + globs: []string{"testdata/last/*.txt", "testdata/*.txt"}, files: allFiles, expected: map[file.Coordinates]string{ - file.NewLocation("test-fixtures/last/path.txt").Coordinates: "dGVzdC1maXh0dXJlcy9sYXN0L3BhdGgudHh0IGZpbGUgY29udGVudHMh", - file.NewLocation("test-fixtures/another-path.txt").Coordinates: "dGVzdC1maXh0dXJlcy9hbm90aGVyLXBhdGgudHh0IGZpbGUgY29udGVudHMh", - file.NewLocation("test-fixtures/a-path.txt").Coordinates: "dGVzdC1maXh0dXJlcy9hLXBhdGgudHh0IGZpbGUgY29udGVudHMh", + file.NewLocation("testdata/last/path.txt").Coordinates: "dGVzdC1maXh0dXJlcy9sYXN0L3BhdGgudHh0IGZpbGUgY29udGVudHMh", + file.NewLocation("testdata/another-path.txt").Coordinates: "dGVzdC1maXh0dXJlcy9hbm90aGVyLXBhdGgudHh0IGZpbGUgY29udGVudHMh", + file.NewLocation("testdata/a-path.txt").Coordinates: "dGVzdC1maXh0dXJlcy9hLXBhdGgudHh0IGZpbGUgY29udGVudHMh", }, }, { name: "no-patterns", globs: []string{}, - files: []string{"test-fixtures/last/path.txt", "test-fixtures/another-path.txt", "test-fixtures/a-path.txt"}, + files: []string{"testdata/last/path.txt", "testdata/another-path.txt", "testdata/a-path.txt"}, expected: map[file.Coordinates]string{}, }, { @@ -40,18 +40,18 @@ func TestContentsCataloger(t *testing.T) { globs: []string{"**/*.txt"}, files: allFiles, expected: map[file.Coordinates]string{ - file.NewLocation("test-fixtures/last/path.txt").Coordinates: "dGVzdC1maXh0dXJlcy9sYXN0L3BhdGgudHh0IGZpbGUgY29udGVudHMh", - file.NewLocation("test-fixtures/another-path.txt").Coordinates: "dGVzdC1maXh0dXJlcy9hbm90aGVyLXBhdGgudHh0IGZpbGUgY29udGVudHMh", - file.NewLocation("test-fixtures/a-path.txt").Coordinates: "dGVzdC1maXh0dXJlcy9hLXBhdGgudHh0IGZpbGUgY29udGVudHMh", + file.NewLocation("testdata/last/path.txt").Coordinates: "dGVzdC1maXh0dXJlcy9sYXN0L3BhdGgudHh0IGZpbGUgY29udGVudHMh", + file.NewLocation("testdata/another-path.txt").Coordinates: "dGVzdC1maXh0dXJlcy9hbm90aGVyLXBhdGgudHh0IGZpbGUgY29udGVudHMh", + file.NewLocation("testdata/a-path.txt").Coordinates: "dGVzdC1maXh0dXJlcy9hLXBhdGgudHh0IGZpbGUgY29udGVudHMh", }, }, { name: "subpath", - globs: []string{"test-fixtures/*.txt"}, + globs: []string{"testdata/*.txt"}, files: allFiles, expected: map[file.Coordinates]string{ - file.NewLocation("test-fixtures/another-path.txt").Coordinates: "dGVzdC1maXh0dXJlcy9hbm90aGVyLXBhdGgudHh0IGZpbGUgY29udGVudHMh", - file.NewLocation("test-fixtures/a-path.txt").Coordinates: "dGVzdC1maXh0dXJlcy9hLXBhdGgudHh0IGZpbGUgY29udGVudHMh", + file.NewLocation("testdata/another-path.txt").Coordinates: "dGVzdC1maXh0dXJlcy9hbm90aGVyLXBhdGgudHh0IGZpbGUgY29udGVudHMh", + file.NewLocation("testdata/a-path.txt").Coordinates: "dGVzdC1maXh0dXJlcy9hLXBhdGgudHh0IGZpbGUgY29udGVudHMh", }, }, { @@ -60,8 +60,8 @@ func TestContentsCataloger(t *testing.T) { globs: []string{"**/*.txt"}, files: allFiles, expected: map[file.Coordinates]string{ - file.NewLocation("test-fixtures/last/path.txt").Coordinates: "dGVzdC1maXh0dXJlcy9sYXN0L3BhdGgudHh0IGZpbGUgY29udGVudHMh", - file.NewLocation("test-fixtures/a-path.txt").Coordinates: "dGVzdC1maXh0dXJlcy9hLXBhdGgudHh0IGZpbGUgY29udGVudHMh", + file.NewLocation("testdata/last/path.txt").Coordinates: "dGVzdC1maXh0dXJlcy9sYXN0L3BhdGgudHh0IGZpbGUgY29udGVudHMh", + file.NewLocation("testdata/a-path.txt").Coordinates: "dGVzdC1maXh0dXJlcy9hLXBhdGgudHh0IGZpbGUgY29udGVudHMh", }, }, } diff --git a/syft/file/cataloger/filecontent/test-fixtures/a-path.txt b/syft/file/cataloger/filecontent/testdata/a-path.txt similarity index 100% rename from syft/file/cataloger/filecontent/test-fixtures/a-path.txt rename to syft/file/cataloger/filecontent/testdata/a-path.txt diff --git a/syft/file/cataloger/filecontent/test-fixtures/another-path.txt b/syft/file/cataloger/filecontent/testdata/another-path.txt similarity index 100% rename from syft/file/cataloger/filecontent/test-fixtures/another-path.txt rename to syft/file/cataloger/filecontent/testdata/another-path.txt diff --git a/syft/file/cataloger/filecontent/test-fixtures/last/empty/empty b/syft/file/cataloger/filecontent/testdata/last/empty/empty similarity index 100% rename from syft/file/cataloger/filecontent/test-fixtures/last/empty/empty rename to syft/file/cataloger/filecontent/testdata/last/empty/empty diff --git a/syft/file/cataloger/filecontent/test-fixtures/last/path.txt b/syft/file/cataloger/filecontent/testdata/last/path.txt similarity index 100% rename from syft/file/cataloger/filecontent/test-fixtures/last/path.txt rename to syft/file/cataloger/filecontent/testdata/last/path.txt diff --git a/syft/file/cataloger/filedigest/cataloger_test.go b/syft/file/cataloger/filedigest/cataloger_test.go index 5b83fb37e..00e72a7d1 100644 --- a/syft/file/cataloger/filedigest/cataloger_test.go +++ b/syft/file/cataloger/filedigest/cataloger_test.go @@ -59,14 +59,14 @@ func TestDigestsCataloger(t *testing.T) { { name: "md5", digests: []crypto.Hash{crypto.MD5}, - files: []string{"test-fixtures/last/empty/empty", "test-fixtures/last/path.txt"}, - expected: testDigests(t, "test-fixtures/last", []string{"empty/empty", "path.txt"}, crypto.MD5), + files: []string{"testdata/last/empty/empty", "testdata/last/path.txt"}, + expected: testDigests(t, "testdata/last", []string{"empty/empty", "path.txt"}, crypto.MD5), }, { name: "md5-sha1-sha256", digests: []crypto.Hash{crypto.MD5, crypto.SHA1, crypto.SHA256}, - files: []string{"test-fixtures/last/empty/empty", "test-fixtures/last/path.txt"}, - expected: testDigests(t, "test-fixtures/last", []string{"empty/empty", "path.txt"}, crypto.MD5, crypto.SHA1, crypto.SHA256), + files: []string{"testdata/last/empty/empty", "testdata/last/path.txt"}, + expected: testDigests(t, "testdata/last", []string{"empty/empty", "path.txt"}, crypto.MD5, crypto.SHA1, crypto.SHA256), }, } @@ -74,7 +74,7 @@ func TestDigestsCataloger(t *testing.T) { t.Run(test.name, func(t *testing.T) { c := NewCataloger(test.digests) - src, err := directorysource.NewFromPath("test-fixtures/last/") + src, err := directorysource.NewFromPath("testdata/last/") require.NoError(t, err) resolver, err := src.FileResolver(source.SquashedScope) diff --git a/syft/file/cataloger/filedigest/test-fixtures/image-file-type-mix/Dockerfile b/syft/file/cataloger/filedigest/testdata/image-file-type-mix/Dockerfile similarity index 100% rename from syft/file/cataloger/filedigest/test-fixtures/image-file-type-mix/Dockerfile rename to syft/file/cataloger/filedigest/testdata/image-file-type-mix/Dockerfile diff --git a/syft/file/cataloger/filedigest/test-fixtures/image-file-type-mix/file-1.txt b/syft/file/cataloger/filedigest/testdata/image-file-type-mix/file-1.txt similarity index 100% rename from syft/file/cataloger/filedigest/test-fixtures/image-file-type-mix/file-1.txt rename to syft/file/cataloger/filedigest/testdata/image-file-type-mix/file-1.txt diff --git a/syft/file/cataloger/filedigest/test-fixtures/last/empty/empty b/syft/file/cataloger/filedigest/testdata/last/empty/empty similarity index 100% rename from syft/file/cataloger/filedigest/test-fixtures/last/empty/empty rename to syft/file/cataloger/filedigest/testdata/last/empty/empty diff --git a/syft/file/cataloger/filedigest/test-fixtures/last/path.txt b/syft/file/cataloger/filedigest/testdata/last/path.txt similarity index 100% rename from syft/file/cataloger/filedigest/test-fixtures/last/path.txt rename to syft/file/cataloger/filedigest/testdata/last/path.txt diff --git a/syft/file/cataloger/filemetadata/test-fixtures/image-file-type-mix/Dockerfile b/syft/file/cataloger/filemetadata/testdata/image-file-type-mix/Dockerfile similarity index 100% rename from syft/file/cataloger/filemetadata/test-fixtures/image-file-type-mix/Dockerfile rename to syft/file/cataloger/filemetadata/testdata/image-file-type-mix/Dockerfile diff --git a/syft/file/cataloger/filemetadata/test-fixtures/image-file-type-mix/file-1.txt b/syft/file/cataloger/filemetadata/testdata/image-file-type-mix/file-1.txt similarity index 100% rename from syft/file/cataloger/filemetadata/test-fixtures/image-file-type-mix/file-1.txt rename to syft/file/cataloger/filemetadata/testdata/image-file-type-mix/file-1.txt diff --git a/syft/file/cataloger/internal/all_regular_files_test.go b/syft/file/cataloger/internal/all_regular_files_test.go index 4a7d4f29f..cec05bf61 100644 --- a/syft/file/cataloger/internal/all_regular_files_test.go +++ b/syft/file/cataloger/internal/all_regular_files_test.go @@ -45,7 +45,7 @@ func Test_allRegularFiles(t *testing.T) { { name: "directory", setup: func() file.Resolver { - s, err := directorysource.NewFromPath("test-fixtures/symlinked-root/nested/link-root") + s, err := directorysource.NewFromPath("testdata/symlinked-root/nested/link-root") require.NoError(t, err) r, err := s.FileResolver(source.SquashedScope) require.NoError(t, err) diff --git a/syft/file/cataloger/internal/test-fixtures/image-file-type-mix/Dockerfile b/syft/file/cataloger/internal/testdata/image-file-type-mix/Dockerfile similarity index 100% rename from syft/file/cataloger/internal/test-fixtures/image-file-type-mix/Dockerfile rename to syft/file/cataloger/internal/testdata/image-file-type-mix/Dockerfile diff --git a/syft/file/cataloger/internal/test-fixtures/image-file-type-mix/file-1.txt b/syft/file/cataloger/internal/testdata/image-file-type-mix/file-1.txt similarity index 100% rename from syft/file/cataloger/internal/test-fixtures/image-file-type-mix/file-1.txt rename to syft/file/cataloger/internal/testdata/image-file-type-mix/file-1.txt diff --git a/syft/file/cataloger/internal/test-fixtures/symlinked-root/nested/link-root b/syft/file/cataloger/internal/testdata/symlinked-root/nested/link-root similarity index 100% rename from syft/file/cataloger/internal/test-fixtures/symlinked-root/nested/link-root rename to syft/file/cataloger/internal/testdata/symlinked-root/nested/link-root diff --git a/syft/file/cataloger/internal/test-fixtures/symlinked-root/real-root/file1.txt b/syft/file/cataloger/internal/testdata/symlinked-root/real-root/file1.txt similarity index 100% rename from syft/file/cataloger/internal/test-fixtures/symlinked-root/real-root/file1.txt rename to syft/file/cataloger/internal/testdata/symlinked-root/real-root/file1.txt diff --git a/syft/file/cataloger/internal/test-fixtures/symlinked-root/real-root/nested/file2.txt b/syft/file/cataloger/internal/testdata/symlinked-root/real-root/nested/file2.txt similarity index 100% rename from syft/file/cataloger/internal/test-fixtures/symlinked-root/real-root/nested/file2.txt rename to syft/file/cataloger/internal/testdata/symlinked-root/real-root/nested/file2.txt diff --git a/syft/file/cataloger/internal/test-fixtures/symlinked-root/real-root/nested/linked-file1.txt b/syft/file/cataloger/internal/testdata/symlinked-root/real-root/nested/linked-file1.txt similarity index 100% rename from syft/file/cataloger/internal/test-fixtures/symlinked-root/real-root/nested/linked-file1.txt rename to syft/file/cataloger/internal/testdata/symlinked-root/real-root/nested/linked-file1.txt diff --git a/syft/file/test-fixtures/req-resp/.gitignore b/syft/file/testdata/req-resp/.gitignore similarity index 100% rename from syft/file/test-fixtures/req-resp/.gitignore rename to syft/file/testdata/req-resp/.gitignore diff --git a/syft/file/test-fixtures/req-resp/path/to/rel-inside.txt b/syft/file/testdata/req-resp/path/to/rel-inside.txt similarity index 100% rename from syft/file/test-fixtures/req-resp/path/to/rel-inside.txt rename to syft/file/testdata/req-resp/path/to/rel-inside.txt diff --git a/syft/file/test-fixtures/req-resp/path/to/the/file.txt b/syft/file/testdata/req-resp/path/to/the/file.txt similarity index 100% rename from syft/file/test-fixtures/req-resp/path/to/the/file.txt rename to syft/file/testdata/req-resp/path/to/the/file.txt diff --git a/syft/file/test-fixtures/req-resp/path/to/the/rel-outside.txt b/syft/file/testdata/req-resp/path/to/the/rel-outside.txt similarity index 100% rename from syft/file/test-fixtures/req-resp/path/to/the/rel-outside.txt rename to syft/file/testdata/req-resp/path/to/the/rel-outside.txt diff --git a/syft/file/test-fixtures/req-resp/root-link b/syft/file/testdata/req-resp/root-link similarity index 100% rename from syft/file/test-fixtures/req-resp/root-link rename to syft/file/testdata/req-resp/root-link diff --git a/syft/file/test-fixtures/req-resp/somewhere/outside.txt b/syft/file/testdata/req-resp/somewhere/outside.txt similarity index 100% rename from syft/file/test-fixtures/req-resp/somewhere/outside.txt rename to syft/file/testdata/req-resp/somewhere/outside.txt diff --git a/syft/format/cpes/decoder_test.go b/syft/format/cpes/decoder_test.go index 19770bb34..d878bdaf1 100644 --- a/syft/format/cpes/decoder_test.go +++ b/syft/format/cpes/decoder_test.go @@ -137,7 +137,7 @@ func TestDecoder_Decode(t *testing.T) { }, { name: "invalid prefix", - userInput: "dir:test-fixtures/cpe", + userInput: "dir:testdata/cpe", sbom: &sbom.SBOM{ Artifacts: sbom.Artifacts{ Packages: pkg.NewCollection(), diff --git a/syft/format/cyclonedxjson/decoder_test.go b/syft/format/cyclonedxjson/decoder_test.go index 90ace0428..53a57b453 100644 --- a/syft/format/cyclonedxjson/decoder_test.go +++ b/syft/format/cyclonedxjson/decoder_test.go @@ -42,7 +42,7 @@ func TestDecoder_Decode(t *testing.T) { } for _, test := range tests { t.Run(test.file, func(t *testing.T) { - reader, err := os.Open(filepath.Join("test-fixtures", test.file)) + reader, err := os.Open(filepath.Join("testdata", test.file)) require.NoError(t, err) reset := func() { _, err = reader.Seek(0, io.SeekStart); require.NoError(t, err) } @@ -101,7 +101,7 @@ func TestDecoder_Identify(t *testing.T) { for _, version := range SupportedVersions() { cases = append(cases, testCase{ name: fmt.Sprintf("v%s schema", version), - file: fmt.Sprintf("test-fixtures/identify/%s.json", version), + file: fmt.Sprintf("testdata/identify/%s.json", version), id: ID, version: version, }) @@ -110,13 +110,13 @@ func TestDecoder_Identify(t *testing.T) { cases = append(cases, []testCase{ { name: "no-schema-1.4", - file: "test-fixtures/identify/micronaut-1.4.json", + file: "testdata/identify/micronaut-1.4.json", id: ID, version: "1.4", }, { name: "no-schema-1.5", - file: "test-fixtures/identify/micronaut-1.5.json", + file: "testdata/identify/micronaut-1.5.json", id: ID, version: "1.5", }, diff --git a/syft/format/cyclonedxjson/test-fixtures/bad-sbom b/syft/format/cyclonedxjson/testdata/bad-sbom similarity index 100% rename from syft/format/cyclonedxjson/test-fixtures/bad-sbom rename to syft/format/cyclonedxjson/testdata/bad-sbom diff --git a/syft/format/cyclonedxjson/test-fixtures/identify/1.2.json b/syft/format/cyclonedxjson/testdata/identify/1.2.json similarity index 100% rename from syft/format/cyclonedxjson/test-fixtures/identify/1.2.json rename to syft/format/cyclonedxjson/testdata/identify/1.2.json diff --git a/syft/format/cyclonedxjson/test-fixtures/identify/1.3.json b/syft/format/cyclonedxjson/testdata/identify/1.3.json similarity index 100% rename from syft/format/cyclonedxjson/test-fixtures/identify/1.3.json rename to syft/format/cyclonedxjson/testdata/identify/1.3.json diff --git a/syft/format/cyclonedxjson/test-fixtures/identify/1.4.json b/syft/format/cyclonedxjson/testdata/identify/1.4.json similarity index 100% rename from syft/format/cyclonedxjson/test-fixtures/identify/1.4.json rename to syft/format/cyclonedxjson/testdata/identify/1.4.json diff --git a/syft/format/cyclonedxjson/test-fixtures/identify/1.5.json b/syft/format/cyclonedxjson/testdata/identify/1.5.json similarity index 100% rename from syft/format/cyclonedxjson/test-fixtures/identify/1.5.json rename to syft/format/cyclonedxjson/testdata/identify/1.5.json diff --git a/syft/format/cyclonedxjson/test-fixtures/identify/1.6.json b/syft/format/cyclonedxjson/testdata/identify/1.6.json similarity index 100% rename from syft/format/cyclonedxjson/test-fixtures/identify/1.6.json rename to syft/format/cyclonedxjson/testdata/identify/1.6.json diff --git a/syft/format/cyclonedxjson/test-fixtures/identify/micronaut-1.4.json b/syft/format/cyclonedxjson/testdata/identify/micronaut-1.4.json similarity index 100% rename from syft/format/cyclonedxjson/test-fixtures/identify/micronaut-1.4.json rename to syft/format/cyclonedxjson/testdata/identify/micronaut-1.4.json diff --git a/syft/format/cyclonedxjson/test-fixtures/identify/micronaut-1.5.json b/syft/format/cyclonedxjson/testdata/identify/micronaut-1.5.json similarity index 100% rename from syft/format/cyclonedxjson/test-fixtures/identify/micronaut-1.5.json rename to syft/format/cyclonedxjson/testdata/identify/micronaut-1.5.json diff --git a/syft/format/cyclonedxjson/test-fixtures/identify/micronaut-1.6.json b/syft/format/cyclonedxjson/testdata/identify/micronaut-1.6.json similarity index 100% rename from syft/format/cyclonedxjson/test-fixtures/identify/micronaut-1.6.json rename to syft/format/cyclonedxjson/testdata/identify/micronaut-1.6.json diff --git a/syft/format/cyclonedxjson/test-fixtures/snapshot/TestCycloneDxDirectoryEncoder.golden b/syft/format/cyclonedxjson/testdata/snapshot/TestCycloneDxDirectoryEncoder.golden similarity index 100% rename from syft/format/cyclonedxjson/test-fixtures/snapshot/TestCycloneDxDirectoryEncoder.golden rename to syft/format/cyclonedxjson/testdata/snapshot/TestCycloneDxDirectoryEncoder.golden diff --git a/syft/format/cyclonedxjson/test-fixtures/snapshot/TestCycloneDxImageEncoder.golden b/syft/format/cyclonedxjson/testdata/snapshot/TestCycloneDxImageEncoder.golden similarity index 100% rename from syft/format/cyclonedxjson/test-fixtures/snapshot/TestCycloneDxImageEncoder.golden rename to syft/format/cyclonedxjson/testdata/snapshot/TestCycloneDxImageEncoder.golden diff --git a/syft/format/cyclonedxxml/decoder_test.go b/syft/format/cyclonedxxml/decoder_test.go index 33f962200..a40644d05 100644 --- a/syft/format/cyclonedxxml/decoder_test.go +++ b/syft/format/cyclonedxxml/decoder_test.go @@ -42,7 +42,7 @@ func TestDecoder_Decode(t *testing.T) { } for _, test := range tests { t.Run(test.file, func(t *testing.T) { - reader, err := os.Open(filepath.Join("test-fixtures", test.file)) + reader, err := os.Open(filepath.Join("testdata", test.file)) require.NoError(t, err) reset := func() { _, err = reader.Seek(0, io.SeekStart); require.NoError(t, err) } @@ -102,7 +102,7 @@ func TestDecoder_Identify(t *testing.T) { for _, version := range SupportedVersions() { cases = append(cases, testCase{ name: fmt.Sprintf("v%s schema", version), - file: fmt.Sprintf("test-fixtures/identify/%s.xml", version), + file: fmt.Sprintf("testdata/identify/%s.xml", version), id: ID, version: version, }) diff --git a/syft/format/cyclonedxxml/test-fixtures/bad-sbom b/syft/format/cyclonedxxml/testdata/bad-sbom similarity index 100% rename from syft/format/cyclonedxxml/test-fixtures/bad-sbom rename to syft/format/cyclonedxxml/testdata/bad-sbom diff --git a/syft/format/cyclonedxxml/test-fixtures/identify/1.0.xml b/syft/format/cyclonedxxml/testdata/identify/1.0.xml similarity index 100% rename from syft/format/cyclonedxxml/test-fixtures/identify/1.0.xml rename to syft/format/cyclonedxxml/testdata/identify/1.0.xml diff --git a/syft/format/cyclonedxxml/test-fixtures/identify/1.1.xml b/syft/format/cyclonedxxml/testdata/identify/1.1.xml similarity index 100% rename from syft/format/cyclonedxxml/test-fixtures/identify/1.1.xml rename to syft/format/cyclonedxxml/testdata/identify/1.1.xml diff --git a/syft/format/cyclonedxxml/test-fixtures/identify/1.2.xml b/syft/format/cyclonedxxml/testdata/identify/1.2.xml similarity index 100% rename from syft/format/cyclonedxxml/test-fixtures/identify/1.2.xml rename to syft/format/cyclonedxxml/testdata/identify/1.2.xml diff --git a/syft/format/cyclonedxxml/test-fixtures/identify/1.3.xml b/syft/format/cyclonedxxml/testdata/identify/1.3.xml similarity index 100% rename from syft/format/cyclonedxxml/test-fixtures/identify/1.3.xml rename to syft/format/cyclonedxxml/testdata/identify/1.3.xml diff --git a/syft/format/cyclonedxxml/test-fixtures/identify/1.4.xml b/syft/format/cyclonedxxml/testdata/identify/1.4.xml similarity index 100% rename from syft/format/cyclonedxxml/test-fixtures/identify/1.4.xml rename to syft/format/cyclonedxxml/testdata/identify/1.4.xml diff --git a/syft/format/cyclonedxxml/test-fixtures/identify/1.5.xml b/syft/format/cyclonedxxml/testdata/identify/1.5.xml similarity index 100% rename from syft/format/cyclonedxxml/test-fixtures/identify/1.5.xml rename to syft/format/cyclonedxxml/testdata/identify/1.5.xml diff --git a/syft/format/cyclonedxxml/test-fixtures/identify/1.6.xml b/syft/format/cyclonedxxml/testdata/identify/1.6.xml similarity index 100% rename from syft/format/cyclonedxxml/test-fixtures/identify/1.6.xml rename to syft/format/cyclonedxxml/testdata/identify/1.6.xml diff --git a/syft/format/cyclonedxxml/test-fixtures/snapshot/TestCycloneDxDirectoryEncoder.golden b/syft/format/cyclonedxxml/testdata/snapshot/TestCycloneDxDirectoryEncoder.golden similarity index 100% rename from syft/format/cyclonedxxml/test-fixtures/snapshot/TestCycloneDxDirectoryEncoder.golden rename to syft/format/cyclonedxxml/testdata/snapshot/TestCycloneDxDirectoryEncoder.golden diff --git a/syft/format/cyclonedxxml/test-fixtures/snapshot/TestCycloneDxImageEncoder.golden b/syft/format/cyclonedxxml/testdata/snapshot/TestCycloneDxImageEncoder.golden similarity index 100% rename from syft/format/cyclonedxxml/test-fixtures/snapshot/TestCycloneDxImageEncoder.golden rename to syft/format/cyclonedxxml/testdata/snapshot/TestCycloneDxImageEncoder.golden diff --git a/syft/format/decoders_collection_test.go b/syft/format/decoders_collection_test.go index 3db3dd897..5a4e7f5f7 100644 --- a/syft/format/decoders_collection_test.go +++ b/syft/format/decoders_collection_test.go @@ -21,7 +21,7 @@ func TestIdentify(t *testing.T) { version string }{ { - fixture: "test-fixtures/alpine-syft.json", + fixture: "testdata/alpine-syft.json", id: syftjson.ID, version: "1.1.0", }, @@ -40,7 +40,7 @@ func TestIdentify(t *testing.T) { } func TestDecodeUnseekable(t *testing.T) { - reader, err := os.Open("spdxjson/test-fixtures/spdx/example7-go-module.spdx.json") + reader, err := os.Open("spdxjson/testdata/spdx/example7-go-module.spdx.json") assert.NoError(t, err) // io.NopCloser wraps the reader in a non-seekable type diff --git a/syft/format/github/test-fixtures/snapshot/TestGithubDirectoryEncoder.golden b/syft/format/github/testdata/snapshot/TestGithubDirectoryEncoder.golden similarity index 100% rename from syft/format/github/test-fixtures/snapshot/TestGithubDirectoryEncoder.golden rename to syft/format/github/testdata/snapshot/TestGithubDirectoryEncoder.golden diff --git a/syft/format/github/test-fixtures/snapshot/TestGithubImageEncoder.golden b/syft/format/github/testdata/snapshot/TestGithubImageEncoder.golden similarity index 100% rename from syft/format/github/test-fixtures/snapshot/TestGithubImageEncoder.golden rename to syft/format/github/testdata/snapshot/TestGithubImageEncoder.golden diff --git a/syft/format/internal/testutil/image_input.go b/syft/format/internal/testutil/image_input.go index d40064e70..f9ab7e06d 100644 --- a/syft/format/internal/testutil/image_input.go +++ b/syft/format/internal/testutil/image_input.go @@ -75,7 +75,7 @@ func changeToDirectoryWithGoldenFixture(t testing.TB, testImage string) func() { // check if test fixture exists... if not, check if there is a shared fixture relative to this dir fn := func() {} - path := filepath.Join("test-fixtures", testImage) + path := filepath.Join("testdata", testImage) if _, err := os.Stat(path); err != nil { // change dir, restore as defer wd, err := os.Getwd() diff --git a/syft/format/internal/testutil/snapshot.go b/syft/format/internal/testutil/snapshot.go index 0d4b6fab7..86b57bb8f 100644 --- a/syft/format/internal/testutil/snapshot.go +++ b/syft/format/internal/testutil/snapshot.go @@ -8,8 +8,8 @@ import ( "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" - "github.com/anchore/go-testutils" "github.com/anchore/stereoscope/pkg/imagetest" + "github.com/anchore/syft/internal/testutils" "github.com/anchore/syft/syft/sbom" ) diff --git a/syft/format/internal/testutil/test-fixtures/image-simple/Dockerfile b/syft/format/internal/testutil/testdata/image-simple/Dockerfile similarity index 100% rename from syft/format/internal/testutil/test-fixtures/image-simple/Dockerfile rename to syft/format/internal/testutil/testdata/image-simple/Dockerfile diff --git a/syft/format/internal/testutil/test-fixtures/image-simple/file-1.txt b/syft/format/internal/testutil/testdata/image-simple/file-1.txt similarity index 100% rename from syft/format/internal/testutil/test-fixtures/image-simple/file-1.txt rename to syft/format/internal/testutil/testdata/image-simple/file-1.txt diff --git a/syft/format/internal/testutil/test-fixtures/image-simple/file-2.txt b/syft/format/internal/testutil/testdata/image-simple/file-2.txt similarity index 100% rename from syft/format/internal/testutil/test-fixtures/image-simple/file-2.txt rename to syft/format/internal/testutil/testdata/image-simple/file-2.txt diff --git a/syft/format/internal/testutil/test-fixtures/snapshot/TestImageEncoder.golden b/syft/format/internal/testutil/testdata/snapshot/TestImageEncoder.golden similarity index 100% rename from syft/format/internal/testutil/test-fixtures/snapshot/TestImageEncoder.golden rename to syft/format/internal/testutil/testdata/snapshot/TestImageEncoder.golden diff --git a/syft/format/internal/testutil/test-fixtures/snapshot/TestSPDXTagValueImageEncoder.golden b/syft/format/internal/testutil/testdata/snapshot/TestSPDXTagValueImageEncoder.golden similarity index 100% rename from syft/format/internal/testutil/test-fixtures/snapshot/TestSPDXTagValueImageEncoder.golden rename to syft/format/internal/testutil/testdata/snapshot/TestSPDXTagValueImageEncoder.golden diff --git a/syft/format/internal/testutil/test-fixtures/snapshot/stereoscope-fixture-image-simple.golden b/syft/format/internal/testutil/testdata/snapshot/stereoscope-fixture-image-simple.golden similarity index 100% rename from syft/format/internal/testutil/test-fixtures/snapshot/stereoscope-fixture-image-simple.golden rename to syft/format/internal/testutil/testdata/snapshot/stereoscope-fixture-image-simple.golden diff --git a/syft/format/purls/test-fixtures/snapshot/Test_Encoder.golden b/syft/format/purls/testdata/snapshot/Test_Encoder.golden similarity index 100% rename from syft/format/purls/test-fixtures/snapshot/Test_Encoder.golden rename to syft/format/purls/testdata/snapshot/Test_Encoder.golden diff --git a/syft/format/spdxjson/decoder_test.go b/syft/format/spdxjson/decoder_test.go index c200f3add..9fb0d05dd 100644 --- a/syft/format/spdxjson/decoder_test.go +++ b/syft/format/spdxjson/decoder_test.go @@ -89,7 +89,7 @@ func TestDecoder_Decode(t *testing.T) { for _, test := range tests { t.Run(test.name, func(t *testing.T) { - reader, err := os.Open(filepath.Join("test-fixtures", "spdx", test.name)) + reader, err := os.Open(filepath.Join("testdata", "spdx", test.name)) require.NoError(t, err) reset := func() { _, err = reader.Seek(0, io.SeekStart); require.NoError(t, err) } @@ -164,7 +164,7 @@ func TestDecoder_Identify(t *testing.T) { for _, version := range SupportedVersions() { cases = append(cases, testCase{ name: fmt.Sprintf("v%s schema", version), - file: fmt.Sprintf("test-fixtures/identify/%s.json", version), + file: fmt.Sprintf("testdata/identify/%s.json", version), id: ID, version: version, }) diff --git a/syft/format/spdxjson/test-fixtures/identify/2.2.json b/syft/format/spdxjson/testdata/identify/2.2.json similarity index 100% rename from syft/format/spdxjson/test-fixtures/identify/2.2.json rename to syft/format/spdxjson/testdata/identify/2.2.json diff --git a/syft/format/spdxjson/test-fixtures/identify/2.3.json b/syft/format/spdxjson/testdata/identify/2.3.json similarity index 100% rename from syft/format/spdxjson/test-fixtures/identify/2.3.json rename to syft/format/spdxjson/testdata/identify/2.3.json diff --git a/syft/format/spdxjson/test-fixtures/snapshot/TestSPDX22JSONRequredProperties.golden b/syft/format/spdxjson/testdata/snapshot/TestSPDX22JSONRequredProperties.golden similarity index 100% rename from syft/format/spdxjson/test-fixtures/snapshot/TestSPDX22JSONRequredProperties.golden rename to syft/format/spdxjson/testdata/snapshot/TestSPDX22JSONRequredProperties.golden diff --git a/syft/format/spdxjson/test-fixtures/snapshot/TestSPDXJSONDirectoryEncoder.golden b/syft/format/spdxjson/testdata/snapshot/TestSPDXJSONDirectoryEncoder.golden similarity index 100% rename from syft/format/spdxjson/test-fixtures/snapshot/TestSPDXJSONDirectoryEncoder.golden rename to syft/format/spdxjson/testdata/snapshot/TestSPDXJSONDirectoryEncoder.golden diff --git a/syft/format/spdxjson/test-fixtures/snapshot/TestSPDXJSONImageEncoder.golden b/syft/format/spdxjson/testdata/snapshot/TestSPDXJSONImageEncoder.golden similarity index 100% rename from syft/format/spdxjson/test-fixtures/snapshot/TestSPDXJSONImageEncoder.golden rename to syft/format/spdxjson/testdata/snapshot/TestSPDXJSONImageEncoder.golden diff --git a/syft/format/spdxjson/test-fixtures/snapshot/TestSPDXRelationshipOrder.golden b/syft/format/spdxjson/testdata/snapshot/TestSPDXRelationshipOrder.golden similarity index 100% rename from syft/format/spdxjson/test-fixtures/snapshot/TestSPDXRelationshipOrder.golden rename to syft/format/spdxjson/testdata/snapshot/TestSPDXRelationshipOrder.golden diff --git a/syft/format/spdxjson/test-fixtures/spdx/alpine-3.10.syft.spdx.json b/syft/format/spdxjson/testdata/spdx/alpine-3.10.syft.spdx.json similarity index 100% rename from syft/format/spdxjson/test-fixtures/spdx/alpine-3.10.syft.spdx.json rename to syft/format/spdxjson/testdata/spdx/alpine-3.10.syft.spdx.json diff --git a/syft/format/spdxjson/test-fixtures/spdx/alpine-3.10.vendor.spdx.json b/syft/format/spdxjson/testdata/spdx/alpine-3.10.vendor.spdx.json similarity index 100% rename from syft/format/spdxjson/test-fixtures/spdx/alpine-3.10.vendor.spdx.json rename to syft/format/spdxjson/testdata/spdx/alpine-3.10.vendor.spdx.json diff --git a/syft/format/spdxjson/test-fixtures/spdx/bad/bad-sbom b/syft/format/spdxjson/testdata/spdx/bad/bad-sbom similarity index 100% rename from syft/format/spdxjson/test-fixtures/spdx/bad/bad-sbom rename to syft/format/spdxjson/testdata/spdx/bad/bad-sbom diff --git a/syft/format/spdxjson/test-fixtures/spdx/bad/example7-bin.spdx.json b/syft/format/spdxjson/testdata/spdx/bad/example7-bin.spdx.json similarity index 100% rename from syft/format/spdxjson/test-fixtures/spdx/bad/example7-bin.spdx.json rename to syft/format/spdxjson/testdata/spdx/bad/example7-bin.spdx.json diff --git a/syft/format/spdxjson/test-fixtures/spdx/bad/example7-go-module.spdx.json b/syft/format/spdxjson/testdata/spdx/bad/example7-go-module.spdx.json similarity index 100% rename from syft/format/spdxjson/test-fixtures/spdx/bad/example7-go-module.spdx.json rename to syft/format/spdxjson/testdata/spdx/bad/example7-go-module.spdx.json diff --git a/syft/format/spdxjson/test-fixtures/spdx/bad/example7-golang.spdx.json b/syft/format/spdxjson/testdata/spdx/bad/example7-golang.spdx.json similarity index 100% rename from syft/format/spdxjson/test-fixtures/spdx/bad/example7-golang.spdx.json rename to syft/format/spdxjson/testdata/spdx/bad/example7-golang.spdx.json diff --git a/syft/format/spdxjson/test-fixtures/spdx/bad/example7-third-party-modules.spdx.json b/syft/format/spdxjson/testdata/spdx/bad/example7-third-party-modules.spdx.json similarity index 100% rename from syft/format/spdxjson/test-fixtures/spdx/bad/example7-third-party-modules.spdx.json rename to syft/format/spdxjson/testdata/spdx/bad/example7-third-party-modules.spdx.json diff --git a/syft/format/spdxjson/test-fixtures/spdx/example7-bin.spdx.json b/syft/format/spdxjson/testdata/spdx/example7-bin.spdx.json similarity index 100% rename from syft/format/spdxjson/test-fixtures/spdx/example7-bin.spdx.json rename to syft/format/spdxjson/testdata/spdx/example7-bin.spdx.json diff --git a/syft/format/spdxjson/test-fixtures/spdx/example7-go-module.spdx.json b/syft/format/spdxjson/testdata/spdx/example7-go-module.spdx.json similarity index 100% rename from syft/format/spdxjson/test-fixtures/spdx/example7-go-module.spdx.json rename to syft/format/spdxjson/testdata/spdx/example7-go-module.spdx.json diff --git a/syft/format/spdxjson/test-fixtures/spdx/example7-golang.spdx.json b/syft/format/spdxjson/testdata/spdx/example7-golang.spdx.json similarity index 100% rename from syft/format/spdxjson/test-fixtures/spdx/example7-golang.spdx.json rename to syft/format/spdxjson/testdata/spdx/example7-golang.spdx.json diff --git a/syft/format/spdxjson/test-fixtures/spdx/example7-third-party-modules.spdx.json b/syft/format/spdxjson/testdata/spdx/example7-third-party-modules.spdx.json similarity index 100% rename from syft/format/spdxjson/test-fixtures/spdx/example7-third-party-modules.spdx.json rename to syft/format/spdxjson/testdata/spdx/example7-third-party-modules.spdx.json diff --git a/syft/format/spdxtagvalue/decoder_test.go b/syft/format/spdxtagvalue/decoder_test.go index edf5b877c..f2aba88fd 100644 --- a/syft/format/spdxtagvalue/decoder_test.go +++ b/syft/format/spdxtagvalue/decoder_test.go @@ -43,7 +43,7 @@ func TestDecoder_Decode(t *testing.T) { } for _, test := range tests { t.Run(test.file, func(t *testing.T) { - reader, err := os.Open(filepath.Join("test-fixtures", test.file)) + reader, err := os.Open(filepath.Join("testdata", test.file)) require.NoError(t, err) dec := NewFormatDecoder() @@ -151,7 +151,7 @@ func TestDecoder_Identify(t *testing.T) { for _, version := range SupportedVersions() { cases = append(cases, testCase{ name: fmt.Sprintf("v%s schema", version), - file: fmt.Sprintf("test-fixtures/identify/%s.sbom", version), + file: fmt.Sprintf("testdata/identify/%s.sbom", version), id: ID, version: version, }) diff --git a/syft/format/spdxtagvalue/test-fixtures/bad-sbom b/syft/format/spdxtagvalue/testdata/bad-sbom similarity index 100% rename from syft/format/spdxtagvalue/test-fixtures/bad-sbom rename to syft/format/spdxtagvalue/testdata/bad-sbom diff --git a/syft/format/spdxtagvalue/test-fixtures/identify/2.1.sbom b/syft/format/spdxtagvalue/testdata/identify/2.1.sbom similarity index 100% rename from syft/format/spdxtagvalue/test-fixtures/identify/2.1.sbom rename to syft/format/spdxtagvalue/testdata/identify/2.1.sbom diff --git a/syft/format/spdxtagvalue/test-fixtures/identify/2.2.sbom b/syft/format/spdxtagvalue/testdata/identify/2.2.sbom similarity index 100% rename from syft/format/spdxtagvalue/test-fixtures/identify/2.2.sbom rename to syft/format/spdxtagvalue/testdata/identify/2.2.sbom diff --git a/syft/format/spdxtagvalue/test-fixtures/identify/2.3.sbom b/syft/format/spdxtagvalue/testdata/identify/2.3.sbom similarity index 100% rename from syft/format/spdxtagvalue/test-fixtures/identify/2.3.sbom rename to syft/format/spdxtagvalue/testdata/identify/2.3.sbom diff --git a/syft/format/spdxtagvalue/test-fixtures/snapshot/TestSPDXJSONSPDXIDs.golden b/syft/format/spdxtagvalue/testdata/snapshot/TestSPDXJSONSPDXIDs.golden similarity index 100% rename from syft/format/spdxtagvalue/test-fixtures/snapshot/TestSPDXJSONSPDXIDs.golden rename to syft/format/spdxtagvalue/testdata/snapshot/TestSPDXJSONSPDXIDs.golden diff --git a/syft/format/spdxtagvalue/test-fixtures/snapshot/TestSPDXRelationshipOrder.golden b/syft/format/spdxtagvalue/testdata/snapshot/TestSPDXRelationshipOrder.golden similarity index 100% rename from syft/format/spdxtagvalue/test-fixtures/snapshot/TestSPDXRelationshipOrder.golden rename to syft/format/spdxtagvalue/testdata/snapshot/TestSPDXRelationshipOrder.golden diff --git a/syft/format/spdxtagvalue/test-fixtures/snapshot/TestSPDXTagValueDirectoryEncoder.golden b/syft/format/spdxtagvalue/testdata/snapshot/TestSPDXTagValueDirectoryEncoder.golden similarity index 100% rename from syft/format/spdxtagvalue/test-fixtures/snapshot/TestSPDXTagValueDirectoryEncoder.golden rename to syft/format/spdxtagvalue/testdata/snapshot/TestSPDXTagValueDirectoryEncoder.golden diff --git a/syft/format/spdxtagvalue/test-fixtures/snapshot/TestSPDXTagValueImageEncoder.golden b/syft/format/spdxtagvalue/testdata/snapshot/TestSPDXTagValueImageEncoder.golden similarity index 100% rename from syft/format/spdxtagvalue/test-fixtures/snapshot/TestSPDXTagValueImageEncoder.golden rename to syft/format/spdxtagvalue/testdata/snapshot/TestSPDXTagValueImageEncoder.golden diff --git a/syft/format/spdxtagvalue/test-fixtures/tag-value.spdx b/syft/format/spdxtagvalue/testdata/tag-value.spdx similarity index 100% rename from syft/format/spdxtagvalue/test-fixtures/tag-value.spdx rename to syft/format/spdxtagvalue/testdata/tag-value.spdx diff --git a/syft/format/syftjson/test-fixtures/identify/11.0.0.json b/syft/format/syftjson/testdata/identify/11.0.0.json similarity index 100% rename from syft/format/syftjson/test-fixtures/identify/11.0.0.json rename to syft/format/syftjson/testdata/identify/11.0.0.json diff --git a/syft/format/syftjson/test-fixtures/image-alpine/Dockerfile b/syft/format/syftjson/testdata/image-alpine/Dockerfile similarity index 100% rename from syft/format/syftjson/test-fixtures/image-alpine/Dockerfile rename to syft/format/syftjson/testdata/image-alpine/Dockerfile diff --git a/syft/format/syftjson/test-fixtures/snapshot/TestDirectoryEncoder.golden b/syft/format/syftjson/testdata/snapshot/TestDirectoryEncoder.golden similarity index 100% rename from syft/format/syftjson/test-fixtures/snapshot/TestDirectoryEncoder.golden rename to syft/format/syftjson/testdata/snapshot/TestDirectoryEncoder.golden diff --git a/syft/format/syftjson/test-fixtures/snapshot/TestEncodeFullJSONDocument.golden b/syft/format/syftjson/testdata/snapshot/TestEncodeFullJSONDocument.golden similarity index 100% rename from syft/format/syftjson/test-fixtures/snapshot/TestEncodeFullJSONDocument.golden rename to syft/format/syftjson/testdata/snapshot/TestEncodeFullJSONDocument.golden diff --git a/syft/format/syftjson/test-fixtures/snapshot/TestImageEncoder.golden b/syft/format/syftjson/testdata/snapshot/TestImageEncoder.golden similarity index 100% rename from syft/format/syftjson/test-fixtures/snapshot/TestImageEncoder.golden rename to syft/format/syftjson/testdata/snapshot/TestImageEncoder.golden diff --git a/syft/format/table/test-fixtures/snapshot/TestTableEncoder.golden b/syft/format/table/testdata/snapshot/TestTableEncoder.golden similarity index 100% rename from syft/format/table/test-fixtures/snapshot/TestTableEncoder.golden rename to syft/format/table/testdata/snapshot/TestTableEncoder.golden diff --git a/syft/format/template/encoder_test.go b/syft/format/template/encoder_test.go index 2ed775a08..4418b20af 100644 --- a/syft/format/template/encoder_test.go +++ b/syft/format/template/encoder_test.go @@ -14,7 +14,7 @@ var updateSnapshot = flag.Bool("update-template", false, "update the *.golden fi func TestFormatWithOption_Legacy(t *testing.T) { f, err := NewFormatEncoder(EncoderConfig{ - TemplatePath: "test-fixtures/legacy/csv.template", + TemplatePath: "testdata/legacy/csv.template", Legacy: true, }) require.NoError(t, err) @@ -32,7 +32,7 @@ func TestFormatWithOption_Legacy(t *testing.T) { func TestFormatWithOptionAndHasField_Legacy(t *testing.T) { f, err := NewFormatEncoder(EncoderConfig{ - TemplatePath: "test-fixtures/legacy/csv-hasField.template", + TemplatePath: "testdata/legacy/csv-hasField.template", Legacy: true, }) require.NoError(t, err) @@ -50,7 +50,7 @@ func TestFormatWithOptionAndHasField_Legacy(t *testing.T) { func TestFormatWithOption(t *testing.T) { f, err := NewFormatEncoder(EncoderConfig{ - TemplatePath: "test-fixtures/csv.template", + TemplatePath: "testdata/csv.template", }) require.NoError(t, err) @@ -67,7 +67,7 @@ func TestFormatWithOption(t *testing.T) { func TestFormatWithOptionAndHasField(t *testing.T) { f, err := NewFormatEncoder(EncoderConfig{ - TemplatePath: "test-fixtures/csv-hasField.template", + TemplatePath: "testdata/csv-hasField.template", }) require.NoError(t, err) diff --git a/syft/format/template/test-fixtures/csv-hasField.template b/syft/format/template/testdata/csv-hasField.template similarity index 100% rename from syft/format/template/test-fixtures/csv-hasField.template rename to syft/format/template/testdata/csv-hasField.template diff --git a/syft/format/template/test-fixtures/csv.template b/syft/format/template/testdata/csv.template similarity index 100% rename from syft/format/template/test-fixtures/csv.template rename to syft/format/template/testdata/csv.template diff --git a/syft/format/template/test-fixtures/legacy/csv-hasField.template b/syft/format/template/testdata/legacy/csv-hasField.template similarity index 100% rename from syft/format/template/test-fixtures/legacy/csv-hasField.template rename to syft/format/template/testdata/legacy/csv-hasField.template diff --git a/syft/format/template/test-fixtures/legacy/csv.template b/syft/format/template/testdata/legacy/csv.template similarity index 100% rename from syft/format/template/test-fixtures/legacy/csv.template rename to syft/format/template/testdata/legacy/csv.template diff --git a/syft/format/template/test-fixtures/snapshot/TestFormatWithOption.golden b/syft/format/template/testdata/snapshot/TestFormatWithOption.golden similarity index 100% rename from syft/format/template/test-fixtures/snapshot/TestFormatWithOption.golden rename to syft/format/template/testdata/snapshot/TestFormatWithOption.golden diff --git a/syft/format/template/test-fixtures/snapshot/TestFormatWithOptionAndHasField.golden b/syft/format/template/testdata/snapshot/TestFormatWithOptionAndHasField.golden similarity index 100% rename from syft/format/template/test-fixtures/snapshot/TestFormatWithOptionAndHasField.golden rename to syft/format/template/testdata/snapshot/TestFormatWithOptionAndHasField.golden diff --git a/syft/format/template/test-fixtures/snapshot/TestFormatWithOptionAndHasField_Legacy.golden b/syft/format/template/testdata/snapshot/TestFormatWithOptionAndHasField_Legacy.golden similarity index 100% rename from syft/format/template/test-fixtures/snapshot/TestFormatWithOptionAndHasField_Legacy.golden rename to syft/format/template/testdata/snapshot/TestFormatWithOptionAndHasField_Legacy.golden diff --git a/syft/format/template/test-fixtures/snapshot/TestFormatWithOption_Legacy.golden b/syft/format/template/testdata/snapshot/TestFormatWithOption_Legacy.golden similarity index 100% rename from syft/format/template/test-fixtures/snapshot/TestFormatWithOption_Legacy.golden rename to syft/format/template/testdata/snapshot/TestFormatWithOption_Legacy.golden diff --git a/syft/format/test-fixtures/alpine-syft.json b/syft/format/testdata/alpine-syft.json similarity index 100% rename from syft/format/test-fixtures/alpine-syft.json rename to syft/format/testdata/alpine-syft.json diff --git a/syft/format/text/test-fixtures/snapshot/TestTextDirectoryEncoder.golden b/syft/format/text/testdata/snapshot/TestTextDirectoryEncoder.golden similarity index 100% rename from syft/format/text/test-fixtures/snapshot/TestTextDirectoryEncoder.golden rename to syft/format/text/testdata/snapshot/TestTextDirectoryEncoder.golden diff --git a/syft/format/text/test-fixtures/snapshot/TestTextImageEncoder.golden b/syft/format/text/testdata/snapshot/TestTextImageEncoder.golden similarity index 100% rename from syft/format/text/test-fixtures/snapshot/TestTextImageEncoder.golden rename to syft/format/text/testdata/snapshot/TestTextImageEncoder.golden diff --git a/syft/format/text/test-fixtures/snapshot/stereoscope-fixture-image-simple.golden b/syft/format/text/testdata/snapshot/stereoscope-fixture-image-simple.golden similarity index 100% rename from syft/format/text/test-fixtures/snapshot/stereoscope-fixture-image-simple.golden rename to syft/format/text/testdata/snapshot/stereoscope-fixture-image-simple.golden diff --git a/syft/internal/fileresolver/chroot_context_test.go b/syft/internal/fileresolver/chroot_context_test.go index 96df93aea..06f6e283a 100644 --- a/syft/internal/fileresolver/chroot_context_test.go +++ b/syft/internal/fileresolver/chroot_context_test.go @@ -26,7 +26,7 @@ func Test_ChrootContext_RequestResponse(t *testing.T) { testDir, err := os.Getwd() require.NoError(t, err) - relative := filepath.Join("test-fixtures", "req-resp") + relative := filepath.Join("testdata", "req-resp") absolute := filepath.Join(testDir, relative) absPathToTheFile := filepath.Join(absolute, "path", "to", "the", "file.txt") @@ -503,7 +503,7 @@ func TestNewChrootContext_BaseValidation(t *testing.T) { testDir, err := os.Getwd() require.NoError(t, err) - relative := filepath.Join("test-fixtures", "req-resp") + relative := filepath.Join("testdata", "req-resp") absolute := filepath.Join(testDir, relative) tests := []struct { diff --git a/syft/internal/fileresolver/directory_indexer_test.go b/syft/internal/fileresolver/directory_indexer_test.go index 6ccfe1f49..ace9aa9ce 100644 --- a/syft/internal/fileresolver/directory_indexer_test.go +++ b/syft/internal/fileresolver/directory_indexer_test.go @@ -176,7 +176,7 @@ func TestDirectoryIndexer_indexPath_skipsNilFileInfo(t *testing.T) { func TestDirectoryIndexer_index(t *testing.T) { // note: this test is testing the effects from NewFromDirectory, indexTree, and addPathToIndex - indexer := newDirectoryIndexer("test-fixtures/system_paths/target", "") + indexer := newDirectoryIndexer("testdata/system_paths/target", "") tree, index, err := indexer.build() require.NoError(t, err) @@ -186,19 +186,19 @@ func TestDirectoryIndexer_index(t *testing.T) { }{ { name: "has dir", - path: "test-fixtures/system_paths/target/home", + path: "testdata/system_paths/target/home", }, { name: "has path", - path: "test-fixtures/system_paths/target/home/place", + path: "testdata/system_paths/target/home/place", }, { name: "has symlink", - path: "test-fixtures/system_paths/target/link/a-symlink", + path: "testdata/system_paths/target/link/a-symlink", }, { name: "has symlink target", - path: "test-fixtures/system_paths/outside_root/link_target/place", + path: "testdata/system_paths/outside_root/link_target/place", }, } for _, test := range tests { @@ -238,18 +238,18 @@ func TestDirectoryIndexer_index_for_AncestorSymlinks(t *testing.T) { }{ { name: "the parent directory has symlink target", - path: "test-fixtures/system_paths/target/symlinks-to-dev", - relative_base: "test-fixtures/system_paths/target/symlinks-to-dev", + path: "testdata/system_paths/target/symlinks-to-dev", + relative_base: "testdata/system_paths/target/symlinks-to-dev", }, { name: "the ancestor directory has symlink target", - path: "test-fixtures/system_paths/target/symlinks-to-hierarchical-dev", - relative_base: "test-fixtures/system_paths/target/symlinks-to-hierarchical-dev/module_1/module_1_1", + path: "testdata/system_paths/target/symlinks-to-hierarchical-dev", + relative_base: "testdata/system_paths/target/symlinks-to-hierarchical-dev/module_1/module_1_1", }, } for _, test := range tests { t.Run(test.name, func(t *testing.T) { - indexer := newDirectoryIndexer("test-fixtures/system_paths/target", + indexer := newDirectoryIndexer("testdata/system_paths/target", fmt.Sprintf("%v/%v", dir, test.relative_base)) tree, index, err := indexer.build() require.NoError(t, err) @@ -275,13 +275,13 @@ func TestDirectoryIndexer_index_for_AncestorSymlinks(t *testing.T) { } } func TestDirectoryIndexer_index_survive_badSymlink(t *testing.T) { - // test-fixtures/bad-symlinks + // testdata/bad-symlinks // ├── root // │ ├── place // │ │ └── fd -> ../somewhere/self/fd // │ └── somewhere // ... - indexer := newDirectoryIndexer("test-fixtures/bad-symlinks/root/place/fd", "test-fixtures/bad-symlinks/root/place/fd") + indexer := newDirectoryIndexer("testdata/bad-symlinks/root/place/fd", "testdata/bad-symlinks/root/place/fd") _, _, err := indexer.build() require.NoError(t, err) } @@ -289,7 +289,7 @@ func TestDirectoryIndexer_index_survive_badSymlink(t *testing.T) { func TestDirectoryIndexer_SkipsAlreadyVisitedLinkDestinations(t *testing.T) { var observedPaths []string pathObserver := func(_, p string, _ os.FileInfo, _ error) error { - fields := strings.Split(p, "test-fixtures/symlinks-prune-indexing") + fields := strings.Split(p, "testdata/symlinks-prune-indexing") if len(fields) < 2 { return nil } @@ -299,7 +299,7 @@ func TestDirectoryIndexer_SkipsAlreadyVisitedLinkDestinations(t *testing.T) { } return nil } - resolver := newDirectoryIndexer("./test-fixtures/symlinks-prune-indexing", "") + resolver := newDirectoryIndexer("./testdata/symlinks-prune-indexing", "") // we want to cut ahead of any possible filters to see what paths are considered for indexing (closest to walking) resolver.pathIndexVisitors = append([]PathIndexVisitor{pathObserver}, resolver.pathIndexVisitors...) @@ -337,7 +337,7 @@ func TestDirectoryIndexer_SkipsAlreadyVisitedLinkDestinations(t *testing.T) { } func TestDirectoryIndexer_IndexesAllTypes(t *testing.T) { - indexer := newDirectoryIndexer("./test-fixtures/symlinks-prune-indexing", "") + indexer := newDirectoryIndexer("./testdata/symlinks-prune-indexing", "") tree, index, err := indexer.build() require.NoError(t, err) @@ -346,7 +346,7 @@ func TestDirectoryIndexer_IndexesAllTypes(t *testing.T) { var pathRefs []file.Reference paths := strset.New() for _, ref := range allRefs { - fields := strings.Split(string(ref.RealPath), "test-fixtures/symlinks-prune-indexing") + fields := strings.Split(string(ref.RealPath), "testdata/symlinks-prune-indexing") if len(fields) != 2 { continue } diff --git a/syft/internal/fileresolver/file_indexer_test.go b/syft/internal/fileresolver/file_indexer_test.go index 165bc39d0..d9ba1d8c9 100644 --- a/syft/internal/fileresolver/file_indexer_test.go +++ b/syft/internal/fileresolver/file_indexer_test.go @@ -14,7 +14,7 @@ import ( // - Verify that both the parent and the path are indexed func Test_index(t *testing.T) { - testPath := "test-fixtures/system_paths/target/home/place" + testPath := "testdata/system_paths/target/home/place" indexer := newFileIndexer(testPath, "", make([]PathIndexVisitor, 0)...) tree, index, err := indexer.build() require.NoError(t, err) @@ -25,11 +25,11 @@ func Test_index(t *testing.T) { }{ { name: "has path", - path: "test-fixtures/system_paths/target/home/place", + path: "testdata/system_paths/target/home/place", }, { name: "has parent dir", - path: "test-fixtures/system_paths/target/home", + path: "testdata/system_paths/target/home", }, } @@ -60,7 +60,7 @@ func Test_index(t *testing.T) { // - Verify that directories are rejected func Test_indexRejectsDirectory(t *testing.T) { - dirPath := "test-fixtures/system_paths/target/home" + dirPath := "testdata/system_paths/target/home" indexer := newFileIndexer(dirPath, "", make([]PathIndexVisitor, 0)...) _, _, err := indexer.build() require.Error(t, err) @@ -68,7 +68,7 @@ func Test_indexRejectsDirectory(t *testing.T) { // - Verify ignores if filterAndIndex sets up a filter for the filepath func Test_ignoresPathIfFiltered(t *testing.T) { - testPath := "test-fixtures/system_paths/target/home/place" + testPath := "testdata/system_paths/target/home/place" cwd, cwdErr := os.Getwd() require.NoError(t, cwdErr) ignorePath := path.Join(cwd, testPath) @@ -86,8 +86,8 @@ func Test_ignoresPathIfFiltered(t *testing.T) { // - Verify ignores if filterAndIndex sets up a filter for the directory func Test_ignoresPathIfParentFiltered(t *testing.T) { - testPath := "test-fixtures/system_paths/target/home/place" - parentPath := "test-fixtures/system_paths/target/home" + testPath := "testdata/system_paths/target/home/place" + parentPath := "testdata/system_paths/target/home" cwd, cwdErr := os.Getwd() require.NoError(t, cwdErr) diff --git a/syft/internal/fileresolver/filetree_resolver_test.go b/syft/internal/fileresolver/filetree_resolver_test.go index 400a696f5..48af879bb 100644 --- a/syft/internal/fileresolver/filetree_resolver_test.go +++ b/syft/internal/fileresolver/filetree_resolver_test.go @@ -42,7 +42,7 @@ func TestDirectoryResolver_FilesByPath_request_response(t *testing.T) { testDir, err := os.Getwd() require.NoError(t, err) - relative := filepath.Join("test-fixtures", "req-resp") + relative := filepath.Join("testdata", "req-resp") absolute := filepath.Join(testDir, relative) absInsidePath := filepath.Join(absolute, "path", "to", "abs-inside.txt") @@ -532,7 +532,7 @@ func TestDirectoryResolver_FilesByPath_relativeRoot(t *testing.T) { }{ { name: "should find a file from an absolute input", - relativeRoot: "./test-fixtures/", + relativeRoot: "./testdata/", input: "/image-symlinks/file-1.txt", expected: []string{ "image-symlinks/file-1.txt", @@ -540,7 +540,7 @@ func TestDirectoryResolver_FilesByPath_relativeRoot(t *testing.T) { }, { name: "should find a file from a relative path", - relativeRoot: "./test-fixtures/", + relativeRoot: "./testdata/", input: "image-symlinks/file-1.txt", expected: []string{ "image-symlinks/file-1.txt", @@ -582,7 +582,7 @@ func TestDirectoryResolver_FilesByPath_absoluteRoot(t *testing.T) { }{ { name: "should find a file from an absolute input", - relativeRoot: "./test-fixtures/", + relativeRoot: "./testdata/", input: "/image-symlinks/file-1.txt", expected: []string{ "image-symlinks/file-1.txt", @@ -590,7 +590,7 @@ func TestDirectoryResolver_FilesByPath_absoluteRoot(t *testing.T) { }, { name: "should find a file from a relative path", - relativeRoot: "./test-fixtures/", + relativeRoot: "./testdata/", input: "image-symlinks/file-1.txt", expected: []string{ "image-symlinks/file-1.txt", @@ -639,34 +639,34 @@ func TestDirectoryResolver_FilesByPath(t *testing.T) { }{ { name: "finds a file (relative)", - root: "./test-fixtures/", + root: "./testdata/", input: "image-symlinks/file-1.txt", expected: "image-symlinks/file-1.txt", refCount: 1, }, { name: "finds a file with relative indirection", - root: "./test-fixtures/../test-fixtures", + root: "./testdata/../testdata", input: "image-symlinks/file-1.txt", expected: "image-symlinks/file-1.txt", refCount: 1, }, { name: "managed non-existing files (relative)", - root: "./test-fixtures/", - input: "test-fixtures/image-symlinks/bogus.txt", + root: "./testdata/", + input: "testdata/image-symlinks/bogus.txt", refCount: 0, }, { name: "finds a file (absolute)", - root: "./test-fixtures/", + root: "./testdata/", input: "/image-symlinks/file-1.txt", expected: "image-symlinks/file-1.txt", refCount: 1, }, { name: "directories ignored", - root: "./test-fixtures/", + root: "./testdata/", input: "/image-symlinks", refCount: 0, forcePositiveHasPath: true, @@ -722,7 +722,7 @@ func TestDirectoryResolver_MultipleFilesByPath(t *testing.T) { } for _, c := range cases { t.Run(c.name, func(t *testing.T) { - resolver, err := NewFromDirectory("./test-fixtures", "") + resolver, err := NewFromDirectory("./testdata", "") assert.NoError(t, err) refs, err := resolver.FilesByPath(c.input...) assert.NoError(t, err) @@ -735,7 +735,7 @@ func TestDirectoryResolver_MultipleFilesByPath(t *testing.T) { } func TestDirectoryResolver_FilesByGlobMultiple(t *testing.T) { - resolver, err := NewFromDirectory("./test-fixtures", "") + resolver, err := NewFromDirectory("./testdata", "") assert.NoError(t, err) refs, err := resolver.FilesByGlob("**/image-symlinks/file*") assert.NoError(t, err) @@ -744,7 +744,7 @@ func TestDirectoryResolver_FilesByGlobMultiple(t *testing.T) { } func TestDirectoryResolver_FilesByGlobRecursive(t *testing.T) { - resolver, err := NewFromDirectory("./test-fixtures/image-symlinks", "") + resolver, err := NewFromDirectory("./testdata/image-symlinks", "") assert.NoError(t, err) refs, err := resolver.FilesByGlob("**/*.txt") assert.NoError(t, err) @@ -752,7 +752,7 @@ func TestDirectoryResolver_FilesByGlobRecursive(t *testing.T) { } func TestDirectoryResolver_FilesByGlobSingle(t *testing.T) { - resolver, err := NewFromDirectory("./test-fixtures", "") + resolver, err := NewFromDirectory("./testdata", "") assert.NoError(t, err) refs, err := resolver.FilesByGlob("**/image-symlinks/*1.txt") assert.NoError(t, err) @@ -779,7 +779,7 @@ func TestDirectoryResolver_FilesByPath_ResolvesSymlinks(t *testing.T) { for _, test := range tests { t.Run(test.name, func(t *testing.T) { - resolver, err := NewFromDirectory("./test-fixtures/symlinks-simple", "") + resolver, err := NewFromDirectory("./testdata/symlinks-simple", "") assert.NoError(t, err) refs, err := resolver.FilesByPath(test.fixture) @@ -792,7 +792,7 @@ func TestDirectoryResolver_FilesByPath_ResolvesSymlinks(t *testing.T) { actual, err := io.ReadAll(reader) require.NoError(t, err) - expected, err := os.ReadFile("test-fixtures/symlinks-simple/readme") + expected, err := os.ReadFile("testdata/symlinks-simple/readme") require.NoError(t, err) assert.Equal(t, string(expected), string(actual)) @@ -802,7 +802,7 @@ func TestDirectoryResolver_FilesByPath_ResolvesSymlinks(t *testing.T) { func TestDirectoryResolverDoesNotIgnoreRelativeSystemPaths(t *testing.T) { // let's make certain that "dev/place" is not ignored, since it is not "/dev/place" - resolver, err := NewFromDirectory("test-fixtures/system_paths/target", "") + resolver, err := NewFromDirectory("testdata/system_paths/target", "") assert.NoError(t, err) // all paths should be found (non filtering matches a path) @@ -814,7 +814,7 @@ func TestDirectoryResolverDoesNotIgnoreRelativeSystemPaths(t *testing.T) { assert.Len(t, locations, 6) // ensure that symlink indexing outside of root worked - testLocation := "test-fixtures/system_paths/outside_root/link_target/place" + testLocation := "testdata/system_paths/outside_root/link_target/place" ok := false for _, location := range locations { if strings.HasSuffix(location.RealPath, testLocation) { @@ -834,7 +834,7 @@ func Test_directoryResolver_FilesByMIMEType(t *testing.T) { expectedPaths *strset.Set }{ { - fixturePath: "./test-fixtures/image-simple", + fixturePath: "./testdata/image-simple", mimeType: "text/plain", expectedPaths: strset.New("file-1.txt", "file-2.txt", "target/really/nested/file-3.txt", "Dockerfile"), }, @@ -854,7 +854,7 @@ func Test_directoryResolver_FilesByMIMEType(t *testing.T) { } func Test_IndexingNestedSymLinks(t *testing.T) { - resolver, err := NewFromDirectory("./test-fixtures/symlinks-simple", "") + resolver, err := NewFromDirectory("./testdata/symlinks-simple", "") require.NoError(t, err) // check that we can get the real path @@ -910,7 +910,7 @@ func Test_IndexingNestedSymLinks_ignoredIndexes(t *testing.T) { return nil } - resolver, err := NewFromDirectory("./test-fixtures/symlinks-simple", "", filterFn) + resolver, err := NewFromDirectory("./testdata/symlinks-simple", "", filterFn) require.NoError(t, err) // the path to the real file is PRUNED from the index, so we should NOT expect a location returned @@ -930,7 +930,7 @@ func Test_IndexingNestedSymLinks_ignoredIndexes(t *testing.T) { } func Test_IndexingNestedSymLinksOutsideOfRoot(t *testing.T) { - resolver, err := NewFromDirectory("./test-fixtures/symlinks-multiple-roots/root", "") + resolver, err := NewFromDirectory("./testdata/symlinks-multiple-roots/root", "") require.NoError(t, err) // check that we can get the real path @@ -948,7 +948,7 @@ func Test_IndexingNestedSymLinksOutsideOfRoot(t *testing.T) { } func Test_RootViaSymlink(t *testing.T) { - resolver, err := NewFromDirectory("./test-fixtures/symlinked-root/nested/link-root", "") + resolver, err := NewFromDirectory("./testdata/symlinked-root/nested/link-root", "") require.NoError(t, err) locations, err := resolver.FilesByPath("./file1.txt") @@ -971,7 +971,7 @@ func Test_directoryResolver_FileContentsByLocation(t *testing.T) { r, err := NewFromDirectory(".", "") require.NoError(t, err) - exists, existingPath, err := r.Tree.File(stereoscopeFile.Path(filepath.Join(cwd, "test-fixtures/image-simple/file-1.txt"))) + exists, existingPath, err := r.Tree.File(stereoscopeFile.Path(filepath.Join(cwd, "testdata/image-simple/file-1.txt"))) require.True(t, exists) require.NoError(t, err) require.True(t, existingPath.HasReference()) @@ -1014,7 +1014,7 @@ func Test_directoryResolver_FileContentsByLocation(t *testing.T) { func Test_SymlinkLoopWithGlobsShouldResolve(t *testing.T) { test := func(t *testing.T) { - resolver, err := NewFromDirectory("./test-fixtures/symlinks-loop", "") + resolver, err := NewFromDirectory("./testdata/symlinks-loop", "") require.NoError(t, err) locations, err := resolver.FilesByGlob("**/file.target") @@ -1036,7 +1036,7 @@ func TestDirectoryResolver_FilesByPath_baseRoot(t *testing.T) { }{ { name: "should find the base file", - root: "./test-fixtures/symlinks-base/", + root: "./testdata/symlinks-base/", input: "./base", expected: []string{ "/base", @@ -1044,7 +1044,7 @@ func TestDirectoryResolver_FilesByPath_baseRoot(t *testing.T) { }, { name: "should follow a link with a pivoted root", - root: "./test-fixtures/symlinks-base/", + root: "./testdata/symlinks-base/", input: "./foo", expected: []string{ "/base", @@ -1052,7 +1052,7 @@ func TestDirectoryResolver_FilesByPath_baseRoot(t *testing.T) { }, { name: "should follow a relative link with extra parents", - root: "./test-fixtures/symlinks-base/", + root: "./testdata/symlinks-base/", input: "./bar", expected: []string{ "/base", @@ -1060,7 +1060,7 @@ func TestDirectoryResolver_FilesByPath_baseRoot(t *testing.T) { }, { name: "should follow an absolute link with extra parents", - root: "./test-fixtures/symlinks-base/", + root: "./testdata/symlinks-base/", input: "./baz", expected: []string{ "/base", @@ -1068,7 +1068,7 @@ func TestDirectoryResolver_FilesByPath_baseRoot(t *testing.T) { }, { name: "should follow an absolute link with extra parents", - root: "./test-fixtures/symlinks-base/", + root: "./testdata/symlinks-base/", input: "./sub/link", expected: []string{ "/sub/item", @@ -1076,7 +1076,7 @@ func TestDirectoryResolver_FilesByPath_baseRoot(t *testing.T) { }, { name: "should follow chained pivoted link", - root: "./test-fixtures/symlinks-base/", + root: "./testdata/symlinks-base/", input: "./chain", expected: []string{ "/base", @@ -1229,7 +1229,7 @@ func Test_directoryResolver_resolvesLinks(t *testing.T) { for _, test := range tests { t.Run(test.name, func(t *testing.T) { - resolver, err := NewFromDirectory("./test-fixtures/symlinks-from-image-symlinks-fixture", "") + resolver, err := NewFromDirectory("./testdata/symlinks-from-image-symlinks-fixture", "") require.NoError(t, err) assert.NoError(t, err) @@ -1241,7 +1241,7 @@ func Test_directoryResolver_resolvesLinks(t *testing.T) { } func TestDirectoryResolver_DoNotAddVirtualPathsToTree(t *testing.T) { - resolver, err := NewFromDirectory("./test-fixtures/symlinks-prune-indexing", "") + resolver, err := NewFromDirectory("./testdata/symlinks-prune-indexing", "") require.NoError(t, err) var allRealPaths []stereoscopeFile.Path @@ -1264,7 +1264,7 @@ func TestDirectoryResolver_DoNotAddVirtualPathsToTree(t *testing.T) { func TestDirectoryResolver_FilesContents_errorOnDirRequest(t *testing.T) { defer goleak.VerifyNone(t) - resolver, err := NewFromDirectory("./test-fixtures/system_paths", "") + resolver, err := NewFromDirectory("./testdata/system_paths", "") assert.NoError(t, err) var dirLoc *file.Location @@ -1287,7 +1287,7 @@ func TestDirectoryResolver_FilesContents_errorOnDirRequest(t *testing.T) { } func TestDirectoryResolver_AllLocations(t *testing.T) { - resolver, err := NewFromDirectory("./test-fixtures/symlinks-from-image-symlinks-fixture", "") + resolver, err := NewFromDirectory("./testdata/symlinks-from-image-symlinks-fixture", "") assert.NoError(t, err) paths := strset.New() @@ -1320,7 +1320,7 @@ func TestDirectoryResolver_AllLocations(t *testing.T) { func TestAllLocationsDoesNotLeakGoRoutine(t *testing.T) { defer goleak.VerifyNone(t) - resolver, err := NewFromDirectory("./test-fixtures/symlinks-from-image-symlinks-fixture", "") + resolver, err := NewFromDirectory("./testdata/symlinks-from-image-symlinks-fixture", "") require.NoError(t, err) ctx, cancel := context.WithCancel(context.Background()) for range resolver.AllLocations(ctx) { @@ -1371,7 +1371,7 @@ func TestFileResolver_FilesByPath(t *testing.T) { }{ { description: "Finds file if searched by filepath", - filePath: "./test-fixtures/req-resp/path/to/the/file.txt", + filePath: "./testdata/req-resp/path/to/the/file.txt", fileByPathInput: "file.txt", expectedRealPath: "/file.txt", expectedAccessPath: "/file.txt", @@ -1427,7 +1427,7 @@ func TestFileResolver_MultipleFilesByPath(t *testing.T) { for _, tt := range tests { t.Run(tt.description, func(t *testing.T) { - filePath := "./test-fixtures/req-resp/path/to/the/file.txt" + filePath := "./testdata/req-resp/path/to/the/file.txt" parentPath, err := absoluteSymlinkFreePathToParent(filePath) require.NoError(t, err) require.NotNil(t, parentPath) @@ -1448,7 +1448,7 @@ func TestFileResolver_MultipleFilesByPath(t *testing.T) { } func TestFileResolver_FilesByGlob(t *testing.T) { - filePath := "./test-fixtures/req-resp/path/to/the/file.txt" + filePath := "./testdata/req-resp/path/to/the/file.txt" parentPath, err := absoluteSymlinkFreePathToParent(filePath) require.NoError(t, err) require.NotNil(t, parentPath) @@ -1471,14 +1471,14 @@ func Test_fileResolver_FilesByMIMEType(t *testing.T) { expectedPaths *strset.Set }{ { - fixturePath: "./test-fixtures/image-simple/file-1.txt", + fixturePath: "./testdata/image-simple/file-1.txt", mimeType: "text/plain", expectedPaths: strset.New("/file-1.txt"), }, } for _, test := range tests { t.Run(test.fixturePath, func(t *testing.T) { - filePath := "./test-fixtures/image-simple/file-1.txt" + filePath := "./testdata/image-simple/file-1.txt" parentPath, err := absoluteSymlinkFreePathToParent(filePath) require.NoError(t, err) require.NotNil(t, parentPath) @@ -1502,7 +1502,7 @@ func Test_fileResolver_FileContentsByLocation(t *testing.T) { cwd, err := os.Getwd() require.NoError(t, err) - filePath := "./test-fixtures/image-simple/file-1.txt" + filePath := "./testdata/image-simple/file-1.txt" parentPath, err := absoluteSymlinkFreePathToParent(filePath) require.NoError(t, err) require.NotNil(t, parentPath) @@ -1512,7 +1512,7 @@ func Test_fileResolver_FileContentsByLocation(t *testing.T) { require.NotNil(t, resolver) assert.Equal(t, resolver.Chroot.Base(), parentPath) - exists, existingPath, err := resolver.Tree.File(stereoscopeFile.Path(filepath.Join(cwd, "test-fixtures/image-simple/file-1.txt"))) + exists, existingPath, err := resolver.Tree.File(stereoscopeFile.Path(filepath.Join(cwd, "testdata/image-simple/file-1.txt"))) require.True(t, exists) require.NoError(t, err) require.True(t, existingPath.HasReference()) @@ -1554,7 +1554,7 @@ func Test_fileResolver_FileContentsByLocation(t *testing.T) { } func TestFileResolver_AllLocations_errorOnDirRequest(t *testing.T) { - filePath := "./test-fixtures/system_paths/target/home/place" + filePath := "./testdata/system_paths/target/home/place" parentPath, err := absoluteSymlinkFreePathToParent(filePath) require.NoError(t, err) require.NotNil(t, parentPath) @@ -1586,7 +1586,7 @@ func TestFileResolver_AllLocations_errorOnDirRequest(t *testing.T) { func TestFileResolver_AllLocations(t *testing.T) { // Verify both the parent and the file itself are indexed - filePath := "./test-fixtures/system_paths/target/home/place" + filePath := "./testdata/system_paths/target/home/place" parentPath, err := absoluteSymlinkFreePathToParent(filePath) require.NoError(t, err) require.NotNil(t, parentPath) @@ -1614,7 +1614,7 @@ func TestFileResolver_AllLocations(t *testing.T) { } func Test_FileResolver_AllLocationsDoesNotLeakGoRoutine(t *testing.T) { - filePath := "./test-fixtures/system_paths/target/home/place" + filePath := "./testdata/system_paths/target/home/place" parentPath, err := absoluteSymlinkFreePathToParent(filePath) require.NoError(t, err) require.NotNil(t, parentPath) diff --git a/syft/internal/fileresolver/metadata_test.go b/syft/internal/fileresolver/metadata_test.go index ccb68d65f..298c9887a 100644 --- a/syft/internal/fileresolver/metadata_test.go +++ b/syft/internal/fileresolver/metadata_test.go @@ -18,22 +18,22 @@ func TestFileMetadataFromPath(t *testing.T) { expectedMIMEType string }{ { - path: "test-fixtures/symlinks-simple/readme", + path: "testdata/symlinks-simple/readme", expectedType: file.TypeRegular, expectedMIMEType: "text/plain", }, { - path: "test-fixtures/symlinks-simple/link_to_new_readme", + path: "testdata/symlinks-simple/link_to_new_readme", expectedType: file.TypeSymLink, expectedMIMEType: "", }, { - path: "test-fixtures/symlinks-simple/link_to_link_to_new_readme", + path: "testdata/symlinks-simple/link_to_link_to_new_readme", expectedType: file.TypeSymLink, expectedMIMEType: "", }, { - path: "test-fixtures/symlinks-simple", + path: "testdata/symlinks-simple", expectedType: file.TypeDirectory, expectedMIMEType: "", }, diff --git a/syft/internal/fileresolver/test-fixtures/bad-symlinks/root/place/fd b/syft/internal/fileresolver/testdata/bad-symlinks/root/place/fd similarity index 100% rename from syft/internal/fileresolver/test-fixtures/bad-symlinks/root/place/fd rename to syft/internal/fileresolver/testdata/bad-symlinks/root/place/fd diff --git a/syft/internal/fileresolver/test-fixtures/generate-tar-fixture-from-source-dir.sh b/syft/internal/fileresolver/testdata/generate-tar-fixture-from-source-dir.sh similarity index 100% rename from syft/internal/fileresolver/test-fixtures/generate-tar-fixture-from-source-dir.sh rename to syft/internal/fileresolver/testdata/generate-tar-fixture-from-source-dir.sh diff --git a/syft/internal/fileresolver/test-fixtures/image-duplicate-path/Dockerfile b/syft/internal/fileresolver/testdata/image-duplicate-path/Dockerfile similarity index 100% rename from syft/internal/fileresolver/test-fixtures/image-duplicate-path/Dockerfile rename to syft/internal/fileresolver/testdata/image-duplicate-path/Dockerfile diff --git a/syft/internal/fileresolver/test-fixtures/image-duplicate-path/file-1.txt b/syft/internal/fileresolver/testdata/image-duplicate-path/file-1.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/image-duplicate-path/file-1.txt rename to syft/internal/fileresolver/testdata/image-duplicate-path/file-1.txt diff --git a/syft/internal/fileresolver/test-fixtures/image-duplicate-path/file-2.txt b/syft/internal/fileresolver/testdata/image-duplicate-path/file-2.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/image-duplicate-path/file-2.txt rename to syft/internal/fileresolver/testdata/image-duplicate-path/file-2.txt diff --git a/syft/internal/fileresolver/test-fixtures/image-files-deleted/Dockerfile b/syft/internal/fileresolver/testdata/image-files-deleted/Dockerfile similarity index 100% rename from syft/internal/fileresolver/test-fixtures/image-files-deleted/Dockerfile rename to syft/internal/fileresolver/testdata/image-files-deleted/Dockerfile diff --git a/syft/internal/fileresolver/test-fixtures/image-files-deleted/file-1.txt b/syft/internal/fileresolver/testdata/image-files-deleted/file-1.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/image-files-deleted/file-1.txt rename to syft/internal/fileresolver/testdata/image-files-deleted/file-1.txt diff --git a/syft/internal/fileresolver/test-fixtures/image-files-deleted/file-3.txt b/syft/internal/fileresolver/testdata/image-files-deleted/file-3.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/image-files-deleted/file-3.txt rename to syft/internal/fileresolver/testdata/image-files-deleted/file-3.txt diff --git a/syft/internal/fileresolver/test-fixtures/image-files-deleted/target/file-2.txt b/syft/internal/fileresolver/testdata/image-files-deleted/target/file-2.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/image-files-deleted/target/file-2.txt rename to syft/internal/fileresolver/testdata/image-files-deleted/target/file-2.txt diff --git a/syft/internal/fileresolver/test-fixtures/image-simple/Dockerfile b/syft/internal/fileresolver/testdata/image-simple/Dockerfile similarity index 100% rename from syft/internal/fileresolver/test-fixtures/image-simple/Dockerfile rename to syft/internal/fileresolver/testdata/image-simple/Dockerfile diff --git a/syft/internal/fileresolver/test-fixtures/image-simple/file-1.txt b/syft/internal/fileresolver/testdata/image-simple/file-1.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/image-simple/file-1.txt rename to syft/internal/fileresolver/testdata/image-simple/file-1.txt diff --git a/syft/internal/fileresolver/test-fixtures/image-simple/file-2.txt b/syft/internal/fileresolver/testdata/image-simple/file-2.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/image-simple/file-2.txt rename to syft/internal/fileresolver/testdata/image-simple/file-2.txt diff --git a/syft/internal/fileresolver/test-fixtures/image-simple/target/really/nested/file-3.txt b/syft/internal/fileresolver/testdata/image-simple/target/really/nested/file-3.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/image-simple/target/really/nested/file-3.txt rename to syft/internal/fileresolver/testdata/image-simple/target/really/nested/file-3.txt diff --git a/syft/internal/fileresolver/test-fixtures/image-symlinks/Dockerfile b/syft/internal/fileresolver/testdata/image-symlinks/Dockerfile similarity index 100% rename from syft/internal/fileresolver/test-fixtures/image-symlinks/Dockerfile rename to syft/internal/fileresolver/testdata/image-symlinks/Dockerfile diff --git a/syft/internal/fileresolver/test-fixtures/image-symlinks/file-1.txt b/syft/internal/fileresolver/testdata/image-symlinks/file-1.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/image-symlinks/file-1.txt rename to syft/internal/fileresolver/testdata/image-symlinks/file-1.txt diff --git a/syft/internal/fileresolver/test-fixtures/image-symlinks/file-2.txt b/syft/internal/fileresolver/testdata/image-symlinks/file-2.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/image-symlinks/file-2.txt rename to syft/internal/fileresolver/testdata/image-symlinks/file-2.txt diff --git a/syft/internal/fileresolver/test-fixtures/image-symlinks/nested/nested/file-3.txt b/syft/internal/fileresolver/testdata/image-symlinks/nested/nested/file-3.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/image-symlinks/nested/nested/file-3.txt rename to syft/internal/fileresolver/testdata/image-symlinks/nested/nested/file-3.txt diff --git a/syft/internal/fileresolver/test-fixtures/image-symlinks/new-file-2.txt b/syft/internal/fileresolver/testdata/image-symlinks/new-file-2.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/image-symlinks/new-file-2.txt rename to syft/internal/fileresolver/testdata/image-symlinks/new-file-2.txt diff --git a/syft/internal/fileresolver/test-fixtures/image-symlinks/new-file-4.txt b/syft/internal/fileresolver/testdata/image-symlinks/new-file-4.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/image-symlinks/new-file-4.txt rename to syft/internal/fileresolver/testdata/image-symlinks/new-file-4.txt diff --git a/syft/internal/fileresolver/test-fixtures/image-symlinks/parent/file-4.txt b/syft/internal/fileresolver/testdata/image-symlinks/parent/file-4.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/image-symlinks/parent/file-4.txt rename to syft/internal/fileresolver/testdata/image-symlinks/parent/file-4.txt diff --git a/syft/internal/fileresolver/test-fixtures/path-detected-2/.vimrc b/syft/internal/fileresolver/testdata/path-detected-2/.vimrc similarity index 100% rename from syft/internal/fileresolver/test-fixtures/path-detected-2/.vimrc rename to syft/internal/fileresolver/testdata/path-detected-2/.vimrc diff --git a/syft/internal/fileresolver/test-fixtures/path-detected-2/empty b/syft/internal/fileresolver/testdata/path-detected-2/empty similarity index 100% rename from syft/internal/fileresolver/test-fixtures/path-detected-2/empty rename to syft/internal/fileresolver/testdata/path-detected-2/empty diff --git a/syft/internal/fileresolver/test-fixtures/path-detected/.vimrc b/syft/internal/fileresolver/testdata/path-detected/.vimrc similarity index 100% rename from syft/internal/fileresolver/test-fixtures/path-detected/.vimrc rename to syft/internal/fileresolver/testdata/path-detected/.vimrc diff --git a/syft/internal/fileresolver/test-fixtures/path-detected/empty b/syft/internal/fileresolver/testdata/path-detected/empty similarity index 100% rename from syft/internal/fileresolver/test-fixtures/path-detected/empty rename to syft/internal/fileresolver/testdata/path-detected/empty diff --git a/syft/internal/fileresolver/test-fixtures/req-resp/.gitignore b/syft/internal/fileresolver/testdata/req-resp/.gitignore similarity index 100% rename from syft/internal/fileresolver/test-fixtures/req-resp/.gitignore rename to syft/internal/fileresolver/testdata/req-resp/.gitignore diff --git a/syft/internal/fileresolver/test-fixtures/req-resp/path/to/rel-inside.txt b/syft/internal/fileresolver/testdata/req-resp/path/to/rel-inside.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/req-resp/path/to/rel-inside.txt rename to syft/internal/fileresolver/testdata/req-resp/path/to/rel-inside.txt diff --git a/syft/internal/fileresolver/test-fixtures/req-resp/path/to/the/file.txt b/syft/internal/fileresolver/testdata/req-resp/path/to/the/file.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/req-resp/path/to/the/file.txt rename to syft/internal/fileresolver/testdata/req-resp/path/to/the/file.txt diff --git a/syft/internal/fileresolver/test-fixtures/req-resp/path/to/the/rel-outside.txt b/syft/internal/fileresolver/testdata/req-resp/path/to/the/rel-outside.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/req-resp/path/to/the/rel-outside.txt rename to syft/internal/fileresolver/testdata/req-resp/path/to/the/rel-outside.txt diff --git a/syft/internal/fileresolver/test-fixtures/req-resp/root-link b/syft/internal/fileresolver/testdata/req-resp/root-link similarity index 100% rename from syft/internal/fileresolver/test-fixtures/req-resp/root-link rename to syft/internal/fileresolver/testdata/req-resp/root-link diff --git a/syft/internal/fileresolver/test-fixtures/req-resp/somewhere/outside.txt b/syft/internal/fileresolver/testdata/req-resp/somewhere/outside.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/req-resp/somewhere/outside.txt rename to syft/internal/fileresolver/testdata/req-resp/somewhere/outside.txt diff --git a/syft/internal/fileresolver/test-fixtures/symlinked-root/nested/link-root b/syft/internal/fileresolver/testdata/symlinked-root/nested/link-root similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinked-root/nested/link-root rename to syft/internal/fileresolver/testdata/symlinked-root/nested/link-root diff --git a/syft/internal/fileresolver/test-fixtures/symlinked-root/real-root/file1.txt b/syft/internal/fileresolver/testdata/symlinked-root/real-root/file1.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinked-root/real-root/file1.txt rename to syft/internal/fileresolver/testdata/symlinked-root/real-root/file1.txt diff --git a/syft/internal/fileresolver/test-fixtures/symlinked-root/real-root/nested/file2.txt b/syft/internal/fileresolver/testdata/symlinked-root/real-root/nested/file2.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinked-root/real-root/nested/file2.txt rename to syft/internal/fileresolver/testdata/symlinked-root/real-root/nested/file2.txt diff --git a/syft/internal/fileresolver/test-fixtures/symlinked-root/real-root/nested/linked-file1.txt b/syft/internal/fileresolver/testdata/symlinked-root/real-root/nested/linked-file1.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinked-root/real-root/nested/linked-file1.txt rename to syft/internal/fileresolver/testdata/symlinked-root/real-root/nested/linked-file1.txt diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-base/bar b/syft/internal/fileresolver/testdata/symlinks-base/bar similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-base/bar rename to syft/internal/fileresolver/testdata/symlinks-base/bar diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-base/base b/syft/internal/fileresolver/testdata/symlinks-base/base similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-base/base rename to syft/internal/fileresolver/testdata/symlinks-base/base diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-base/baz b/syft/internal/fileresolver/testdata/symlinks-base/baz similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-base/baz rename to syft/internal/fileresolver/testdata/symlinks-base/baz diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-base/chain b/syft/internal/fileresolver/testdata/symlinks-base/chain similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-base/chain rename to syft/internal/fileresolver/testdata/symlinks-base/chain diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-base/foo b/syft/internal/fileresolver/testdata/symlinks-base/foo similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-base/foo rename to syft/internal/fileresolver/testdata/symlinks-base/foo diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-base/sub/item b/syft/internal/fileresolver/testdata/symlinks-base/sub/item similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-base/sub/item rename to syft/internal/fileresolver/testdata/symlinks-base/sub/item diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-base/sub/link b/syft/internal/fileresolver/testdata/symlinks-base/sub/link similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-base/sub/link rename to syft/internal/fileresolver/testdata/symlinks-base/sub/link diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-from-image-symlinks-fixture/file-1.txt b/syft/internal/fileresolver/testdata/symlinks-from-image-symlinks-fixture/file-1.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-from-image-symlinks-fixture/file-1.txt rename to syft/internal/fileresolver/testdata/symlinks-from-image-symlinks-fixture/file-1.txt diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-from-image-symlinks-fixture/file-2.txt b/syft/internal/fileresolver/testdata/symlinks-from-image-symlinks-fixture/file-2.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-from-image-symlinks-fixture/file-2.txt rename to syft/internal/fileresolver/testdata/symlinks-from-image-symlinks-fixture/file-2.txt diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-from-image-symlinks-fixture/file-3.txt b/syft/internal/fileresolver/testdata/symlinks-from-image-symlinks-fixture/file-3.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-from-image-symlinks-fixture/file-3.txt rename to syft/internal/fileresolver/testdata/symlinks-from-image-symlinks-fixture/file-3.txt diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-from-image-symlinks-fixture/link-1 b/syft/internal/fileresolver/testdata/symlinks-from-image-symlinks-fixture/link-1 similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-from-image-symlinks-fixture/link-1 rename to syft/internal/fileresolver/testdata/symlinks-from-image-symlinks-fixture/link-1 diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-from-image-symlinks-fixture/link-2 b/syft/internal/fileresolver/testdata/symlinks-from-image-symlinks-fixture/link-2 similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-from-image-symlinks-fixture/link-2 rename to syft/internal/fileresolver/testdata/symlinks-from-image-symlinks-fixture/link-2 diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-from-image-symlinks-fixture/link-dead b/syft/internal/fileresolver/testdata/symlinks-from-image-symlinks-fixture/link-dead similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-from-image-symlinks-fixture/link-dead rename to syft/internal/fileresolver/testdata/symlinks-from-image-symlinks-fixture/link-dead diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-from-image-symlinks-fixture/link-indirect b/syft/internal/fileresolver/testdata/symlinks-from-image-symlinks-fixture/link-indirect similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-from-image-symlinks-fixture/link-indirect rename to syft/internal/fileresolver/testdata/symlinks-from-image-symlinks-fixture/link-indirect diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-from-image-symlinks-fixture/link-within b/syft/internal/fileresolver/testdata/symlinks-from-image-symlinks-fixture/link-within similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-from-image-symlinks-fixture/link-within rename to syft/internal/fileresolver/testdata/symlinks-from-image-symlinks-fixture/link-within diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-from-image-symlinks-fixture/parent-link b/syft/internal/fileresolver/testdata/symlinks-from-image-symlinks-fixture/parent-link similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-from-image-symlinks-fixture/parent-link rename to syft/internal/fileresolver/testdata/symlinks-from-image-symlinks-fixture/parent-link diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-from-image-symlinks-fixture/parent/file-4.txt b/syft/internal/fileresolver/testdata/symlinks-from-image-symlinks-fixture/parent/file-4.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-from-image-symlinks-fixture/parent/file-4.txt rename to syft/internal/fileresolver/testdata/symlinks-from-image-symlinks-fixture/parent/file-4.txt diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-loop/README.md b/syft/internal/fileresolver/testdata/symlinks-loop/README.md similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-loop/README.md rename to syft/internal/fileresolver/testdata/symlinks-loop/README.md diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-loop/block/loop0 b/syft/internal/fileresolver/testdata/symlinks-loop/block/loop0 similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-loop/block/loop0 rename to syft/internal/fileresolver/testdata/symlinks-loop/block/loop0 diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-loop/devices/loop0/file.target b/syft/internal/fileresolver/testdata/symlinks-loop/devices/loop0/file.target similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-loop/devices/loop0/file.target rename to syft/internal/fileresolver/testdata/symlinks-loop/devices/loop0/file.target diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-loop/devices/loop0/subsystem b/syft/internal/fileresolver/testdata/symlinks-loop/devices/loop0/subsystem similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-loop/devices/loop0/subsystem rename to syft/internal/fileresolver/testdata/symlinks-loop/devices/loop0/subsystem diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-multiple-roots/outside/link_to_readme b/syft/internal/fileresolver/testdata/symlinks-multiple-roots/outside/link_to_readme similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-multiple-roots/outside/link_to_readme rename to syft/internal/fileresolver/testdata/symlinks-multiple-roots/outside/link_to_readme diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-multiple-roots/root/link_to_link_to_readme b/syft/internal/fileresolver/testdata/symlinks-multiple-roots/root/link_to_link_to_readme similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-multiple-roots/root/link_to_link_to_readme rename to syft/internal/fileresolver/testdata/symlinks-multiple-roots/root/link_to_link_to_readme diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-multiple-roots/root/readme b/syft/internal/fileresolver/testdata/symlinks-multiple-roots/root/readme similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-multiple-roots/root/readme rename to syft/internal/fileresolver/testdata/symlinks-multiple-roots/root/readme diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-prune-indexing/before-path b/syft/internal/fileresolver/testdata/symlinks-prune-indexing/before-path similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-prune-indexing/before-path rename to syft/internal/fileresolver/testdata/symlinks-prune-indexing/before-path diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-prune-indexing/c-file.txt b/syft/internal/fileresolver/testdata/symlinks-prune-indexing/c-file.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-prune-indexing/c-file.txt rename to syft/internal/fileresolver/testdata/symlinks-prune-indexing/c-file.txt diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-prune-indexing/c-path b/syft/internal/fileresolver/testdata/symlinks-prune-indexing/c-path similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-prune-indexing/c-path rename to syft/internal/fileresolver/testdata/symlinks-prune-indexing/c-path diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-prune-indexing/path/1/2/3/4/dont-index-me-twice.txt b/syft/internal/fileresolver/testdata/symlinks-prune-indexing/path/1/2/3/4/dont-index-me-twice.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-prune-indexing/path/1/2/3/4/dont-index-me-twice.txt rename to syft/internal/fileresolver/testdata/symlinks-prune-indexing/path/1/2/3/4/dont-index-me-twice.txt diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-prune-indexing/path/5/6/7/8/dont-index-me-twice-either.txt b/syft/internal/fileresolver/testdata/symlinks-prune-indexing/path/5/6/7/8/dont-index-me-twice-either.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-prune-indexing/path/5/6/7/8/dont-index-me-twice-either.txt rename to syft/internal/fileresolver/testdata/symlinks-prune-indexing/path/5/6/7/8/dont-index-me-twice-either.txt diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-prune-indexing/path/file.txt b/syft/internal/fileresolver/testdata/symlinks-prune-indexing/path/file.txt similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-prune-indexing/path/file.txt rename to syft/internal/fileresolver/testdata/symlinks-prune-indexing/path/file.txt diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-simple/link_to_link_to_new_readme b/syft/internal/fileresolver/testdata/symlinks-simple/link_to_link_to_new_readme similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-simple/link_to_link_to_new_readme rename to syft/internal/fileresolver/testdata/symlinks-simple/link_to_link_to_new_readme diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-simple/link_to_new_readme b/syft/internal/fileresolver/testdata/symlinks-simple/link_to_new_readme similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-simple/link_to_new_readme rename to syft/internal/fileresolver/testdata/symlinks-simple/link_to_new_readme diff --git a/syft/internal/fileresolver/test-fixtures/symlinks-simple/readme b/syft/internal/fileresolver/testdata/symlinks-simple/readme similarity index 100% rename from syft/internal/fileresolver/test-fixtures/symlinks-simple/readme rename to syft/internal/fileresolver/testdata/symlinks-simple/readme diff --git a/syft/internal/fileresolver/test-fixtures/system_paths/outside_root/link_target/place b/syft/internal/fileresolver/testdata/system_paths/outside_root/link_target/place similarity index 100% rename from syft/internal/fileresolver/test-fixtures/system_paths/outside_root/link_target/place rename to syft/internal/fileresolver/testdata/system_paths/outside_root/link_target/place diff --git a/syft/internal/fileresolver/test-fixtures/system_paths/target/dev/place b/syft/internal/fileresolver/testdata/system_paths/target/dev/place similarity index 100% rename from syft/internal/fileresolver/test-fixtures/system_paths/target/dev/place rename to syft/internal/fileresolver/testdata/system_paths/target/dev/place diff --git a/syft/internal/fileresolver/test-fixtures/system_paths/target/hierarchical-dev/module_1/module_1_1/place b/syft/internal/fileresolver/testdata/system_paths/target/hierarchical-dev/module_1/module_1_1/place similarity index 100% rename from syft/internal/fileresolver/test-fixtures/system_paths/target/hierarchical-dev/module_1/module_1_1/place rename to syft/internal/fileresolver/testdata/system_paths/target/hierarchical-dev/module_1/module_1_1/place diff --git a/syft/internal/fileresolver/test-fixtures/system_paths/target/home/place b/syft/internal/fileresolver/testdata/system_paths/target/home/place similarity index 100% rename from syft/internal/fileresolver/test-fixtures/system_paths/target/home/place rename to syft/internal/fileresolver/testdata/system_paths/target/home/place diff --git a/syft/internal/fileresolver/test-fixtures/system_paths/target/link/a-symlink b/syft/internal/fileresolver/testdata/system_paths/target/link/a-symlink similarity index 100% rename from syft/internal/fileresolver/test-fixtures/system_paths/target/link/a-symlink rename to syft/internal/fileresolver/testdata/system_paths/target/link/a-symlink diff --git a/syft/internal/fileresolver/test-fixtures/system_paths/target/proc/place b/syft/internal/fileresolver/testdata/system_paths/target/proc/place similarity index 100% rename from syft/internal/fileresolver/test-fixtures/system_paths/target/proc/place rename to syft/internal/fileresolver/testdata/system_paths/target/proc/place diff --git a/syft/internal/fileresolver/test-fixtures/system_paths/target/symlinks-to-dev b/syft/internal/fileresolver/testdata/system_paths/target/symlinks-to-dev similarity index 100% rename from syft/internal/fileresolver/test-fixtures/system_paths/target/symlinks-to-dev rename to syft/internal/fileresolver/testdata/system_paths/target/symlinks-to-dev diff --git a/syft/internal/fileresolver/test-fixtures/system_paths/target/symlinks-to-hierarchical-dev b/syft/internal/fileresolver/testdata/system_paths/target/symlinks-to-hierarchical-dev similarity index 100% rename from syft/internal/fileresolver/test-fixtures/system_paths/target/symlinks-to-hierarchical-dev rename to syft/internal/fileresolver/testdata/system_paths/target/symlinks-to-hierarchical-dev diff --git a/syft/internal/fileresolver/test-fixtures/system_paths/target/sys/place b/syft/internal/fileresolver/testdata/system_paths/target/sys/place similarity index 100% rename from syft/internal/fileresolver/test-fixtures/system_paths/target/sys/place rename to syft/internal/fileresolver/testdata/system_paths/target/sys/place diff --git a/syft/internal/fileresolver/unindexed_directory_test.go b/syft/internal/fileresolver/unindexed_directory_test.go index 254ba75c9..8d92dc353 100644 --- a/syft/internal/fileresolver/unindexed_directory_test.go +++ b/syft/internal/fileresolver/unindexed_directory_test.go @@ -28,7 +28,7 @@ func Test_UnindexDirectoryResolver_RequestRelativePathWithinSymlink(t *testing.T pwd, err := os.Getwd() // we need to mimic a shell, otherwise we won't get a path within a symlink - targetPath := filepath.Join(pwd, "./test-fixtures/symlinked-root/nested/link-root/nested") + targetPath := filepath.Join(pwd, "./testdata/symlinked-root/nested/link-root/nested") t.Setenv("PWD", targetPath) require.NoError(t, err) @@ -66,7 +66,7 @@ func Test_UnindexDirectoryResolver_FilesByPath_request_response(t *testing.T) { testDir, err := os.Getwd() require.NoError(t, err) - relative := filepath.Join("test-fixtures", "req-resp") + relative := filepath.Join("testdata", "req-resp") absolute := filepath.Join(testDir, relative) absInsidePath := filepath.Join(absolute, "path", "to", "abs-inside.txt") @@ -534,7 +534,7 @@ func Test_UnindexedDirectoryResolver_Basic(t *testing.T) { wd, err := os.Getwd() require.NoError(t, err) - r := NewFromUnindexedDirectory(path.Join(wd, "test-fixtures")) + r := NewFromUnindexedDirectory(path.Join(wd, "testdata")) locations, err := r.FilesByGlob("image-symlinks/*") require.NoError(t, err) require.Len(t, locations, 5) @@ -545,7 +545,7 @@ func Test_UnindexedDirectoryResolver_NoGoroutineLeak(t *testing.T) { wd, err := os.Getwd() require.NoError(t, err) - r := NewFromUnindexedDirectory(path.Join(wd, "test-fixtures")) + r := NewFromUnindexedDirectory(path.Join(wd, "testdata")) ctx, cancel := context.WithCancel(context.Background()) for range r.AllLocations(ctx) { break @@ -562,7 +562,7 @@ func Test_UnindexedDirectoryResolver_FilesByPath_relativeRoot(t *testing.T) { }{ { name: "should find a file from an absolute input", - relativeRoot: "./test-fixtures/", + relativeRoot: "./testdata/", input: "/image-symlinks/file-1.txt", expected: []string{ "image-symlinks/file-1.txt", @@ -570,7 +570,7 @@ func Test_UnindexedDirectoryResolver_FilesByPath_relativeRoot(t *testing.T) { }, { name: "should find a file from a relative path", - relativeRoot: "./test-fixtures/", + relativeRoot: "./testdata/", input: "image-symlinks/file-1.txt", expected: []string{ "image-symlinks/file-1.txt", @@ -611,7 +611,7 @@ func Test_UnindexedDirectoryResolver_FilesByPath_absoluteRoot(t *testing.T) { }{ { name: "should find a file from an absolute input", - relativeRoot: "./test-fixtures/", + relativeRoot: "./testdata/", input: "/image-symlinks/file-1.txt", expected: []string{ "image-symlinks/file-1.txt", @@ -619,7 +619,7 @@ func Test_UnindexedDirectoryResolver_FilesByPath_absoluteRoot(t *testing.T) { }, { name: "should find a file from a relative path", - relativeRoot: "./test-fixtures/", + relativeRoot: "./testdata/", input: "image-symlinks/file-1.txt", expected: []string{ "image-symlinks/file-1.txt", @@ -668,34 +668,34 @@ func Test_UnindexedDirectoryResolver_FilesByPath(t *testing.T) { }{ { name: "finds a file (relative)", - root: "./test-fixtures/", + root: "./testdata/", input: "image-symlinks/file-1.txt", expected: "image-symlinks/file-1.txt", refCount: 1, }, { name: "finds a file with relative indirection", - root: "./test-fixtures/../test-fixtures", + root: "./testdata/../testdata", input: "image-symlinks/file-1.txt", expected: "image-symlinks/file-1.txt", refCount: 1, }, { name: "managed non-existing files (relative)", - root: "./test-fixtures/", - input: "test-fixtures/image-symlinks/bogus.txt", + root: "./testdata/", + input: "testdata/image-symlinks/bogus.txt", refCount: 0, }, { name: "finds a file (absolute)", - root: "./test-fixtures/", + root: "./testdata/", input: "/image-symlinks/file-1.txt", expected: "image-symlinks/file-1.txt", refCount: 1, }, { name: "directories ignored", - root: "./test-fixtures/", + root: "./testdata/", input: "/image-symlinks", refCount: 0, forcePositiveHasPath: true, @@ -750,7 +750,7 @@ func Test_UnindexedDirectoryResolver_MultipleFilesByPath(t *testing.T) { } for _, c := range cases { t.Run(c.name, func(t *testing.T) { - resolver := NewFromUnindexedDirectory("./test-fixtures") + resolver := NewFromUnindexedDirectory("./testdata") refs, err := resolver.FilesByPath(c.input...) assert.NoError(t, err) @@ -762,7 +762,7 @@ func Test_UnindexedDirectoryResolver_MultipleFilesByPath(t *testing.T) { } func Test_UnindexedDirectoryResolver_FilesByGlobMultiple(t *testing.T) { - resolver := NewFromUnindexedDirectory("./test-fixtures") + resolver := NewFromUnindexedDirectory("./testdata") refs, err := resolver.FilesByGlob("**/image-symlinks/file*") assert.NoError(t, err) @@ -770,14 +770,14 @@ func Test_UnindexedDirectoryResolver_FilesByGlobMultiple(t *testing.T) { } func Test_UnindexedDirectoryResolver_FilesByGlobRecursive(t *testing.T) { - resolver := NewFromUnindexedDirectory("./test-fixtures/image-symlinks") + resolver := NewFromUnindexedDirectory("./testdata/image-symlinks") refs, err := resolver.FilesByGlob("**/*.txt") assert.NoError(t, err) assert.Len(t, refs, 6) } func Test_UnindexedDirectoryResolver_FilesByGlobSingle(t *testing.T) { - resolver := NewFromUnindexedDirectory("./test-fixtures") + resolver := NewFromUnindexedDirectory("./testdata") refs, err := resolver.FilesByGlob("**/image-symlinks/*1.txt") assert.NoError(t, err) @@ -803,7 +803,7 @@ func Test_UnindexedDirectoryResolver_FilesByPath_ResolvesSymlinks(t *testing.T) for _, test := range tests { t.Run(test.name, func(t *testing.T) { - resolver := NewFromUnindexedDirectory("./test-fixtures/symlinks-simple") + resolver := NewFromUnindexedDirectory("./testdata/symlinks-simple") refs, err := resolver.FilesByPath(test.fixture) require.NoError(t, err) @@ -815,7 +815,7 @@ func Test_UnindexedDirectoryResolver_FilesByPath_ResolvesSymlinks(t *testing.T) actual, err := io.ReadAll(reader) require.NoError(t, err) - expected, err := os.ReadFile("test-fixtures/symlinks-simple/readme") + expected, err := os.ReadFile("testdata/symlinks-simple/readme") require.NoError(t, err) require.Equal(t, string(expected), string(actual)) @@ -825,7 +825,7 @@ func Test_UnindexedDirectoryResolver_FilesByPath_ResolvesSymlinks(t *testing.T) func Test_UnindexedDirectoryResolverDoesNotIgnoreRelativeSystemPaths(t *testing.T) { // let's make certain that "dev/place" is not ignored, since it is not "/dev/place" - resolver := NewFromUnindexedDirectory("test-fixtures/system_paths/target") + resolver := NewFromUnindexedDirectory("testdata/system_paths/target") // all paths should be found (non filtering matches a path) locations, err := resolver.FilesByGlob("**/place") @@ -850,7 +850,7 @@ func Test_UnindexedDirectoryResolverDoesNotIgnoreRelativeSystemPaths(t *testing. } func Test_UnindexedDirectoryResover_IndexingNestedSymLinks(t *testing.T) { - resolver := NewFromUnindexedDirectory("./test-fixtures/symlinks-simple") + resolver := NewFromUnindexedDirectory("./testdata/symlinks-simple") // check that we can get the real path locations, err := resolver.FilesByPath("./readme") @@ -898,7 +898,7 @@ func Test_UnindexedDirectoryResover_IndexingNestedSymLinks(t *testing.T) { } func Test_UnindexedDirectoryResover_IndexingNestedSymLinksOutsideOfRoot(t *testing.T) { - resolver := NewFromUnindexedDirectory("./test-fixtures/symlinks-multiple-roots/root") + resolver := NewFromUnindexedDirectory("./testdata/symlinks-multiple-roots/root") // check that we can get the real path locations, err := resolver.FilesByPath("./readme") @@ -915,7 +915,7 @@ func Test_UnindexedDirectoryResover_IndexingNestedSymLinksOutsideOfRoot(t *testi } func Test_UnindexedDirectoryResover_RootViaSymlink(t *testing.T) { - resolver := NewFromUnindexedDirectory("./test-fixtures/symlinked-root/nested/link-root") + resolver := NewFromUnindexedDirectory("./testdata/symlinked-root/nested/link-root") locations, err := resolver.FilesByPath("./file1.txt") require.NoError(t, err) @@ -934,7 +934,7 @@ func Test_UnindexedDirectoryResolver_FileContentsByLocation(t *testing.T) { cwd, err := os.Getwd() require.NoError(t, err) - r := NewFromUnindexedDirectory(path.Join(cwd, "test-fixtures/image-simple")) + r := NewFromUnindexedDirectory(path.Join(cwd, "testdata/image-simple")) require.NoError(t, err) tests := []struct { @@ -975,7 +975,7 @@ func Test_UnindexedDirectoryResolver_FileContentsByLocation(t *testing.T) { func Test_UnindexedDirectoryResover_SymlinkLoopWithGlobsShouldResolve(t *testing.T) { test := func(t *testing.T) { - resolver := NewFromUnindexedDirectory("./test-fixtures/symlinks-loop") + resolver := NewFromUnindexedDirectory("./testdata/symlinks-loop") locations, err := resolver.FilesByGlob("**/file.target") require.NoError(t, err) @@ -996,7 +996,7 @@ func Test_UnindexedDirectoryResolver_FilesByPath_baseRoot(t *testing.T) { }{ { name: "should find the base file", - root: "./test-fixtures/symlinks-base/", + root: "./testdata/symlinks-base/", input: "./base", expected: []string{ "base", @@ -1004,7 +1004,7 @@ func Test_UnindexedDirectoryResolver_FilesByPath_baseRoot(t *testing.T) { }, { name: "should follow a link with a pivoted root", - root: "./test-fixtures/symlinks-base/", + root: "./testdata/symlinks-base/", input: "./foo", expected: []string{ "base", @@ -1012,7 +1012,7 @@ func Test_UnindexedDirectoryResolver_FilesByPath_baseRoot(t *testing.T) { }, { name: "should follow a relative link with extra parents", - root: "./test-fixtures/symlinks-base/", + root: "./testdata/symlinks-base/", input: "./bar", expected: []string{ "base", @@ -1020,7 +1020,7 @@ func Test_UnindexedDirectoryResolver_FilesByPath_baseRoot(t *testing.T) { }, { name: "should follow an absolute link with extra parents", - root: "./test-fixtures/symlinks-base/", + root: "./testdata/symlinks-base/", input: "./baz", expected: []string{ "base", @@ -1028,7 +1028,7 @@ func Test_UnindexedDirectoryResolver_FilesByPath_baseRoot(t *testing.T) { }, { name: "should follow an absolute link with extra parents", - root: "./test-fixtures/symlinks-base/", + root: "./testdata/symlinks-base/", input: "./sub/link", expected: []string{ "sub/item", @@ -1036,7 +1036,7 @@ func Test_UnindexedDirectoryResolver_FilesByPath_baseRoot(t *testing.T) { }, { name: "should follow chained pivoted link", - root: "./test-fixtures/symlinks-base/", + root: "./testdata/symlinks-base/", input: "./chain", expected: []string{ "base", @@ -1171,7 +1171,7 @@ func Test_UnindexedDirectoryResolver_resolvesLinks(t *testing.T) { for _, test := range tests { t.Run(test.name, func(t *testing.T) { - resolver := NewFromUnindexedDirectory("./test-fixtures/symlinks-from-image-symlinks-fixture") + resolver := NewFromUnindexedDirectory("./testdata/symlinks-from-image-symlinks-fixture") actual := test.runner(resolver) @@ -1181,7 +1181,7 @@ func Test_UnindexedDirectoryResolver_resolvesLinks(t *testing.T) { } func Test_UnindexedDirectoryResolver_DoNotAddVirtualPathsToTree(t *testing.T) { - resolver := NewFromUnindexedDirectory("./test-fixtures/symlinks-prune-indexing") + resolver := NewFromUnindexedDirectory("./testdata/symlinks-prune-indexing") ctx, cancel := context.WithCancel(context.Background()) defer cancel() @@ -1204,7 +1204,7 @@ func Test_UnindexedDirectoryResolver_DoNotAddVirtualPathsToTree(t *testing.T) { } func Test_UnindexedDirectoryResolver_FilesContents_errorOnDirRequest(t *testing.T) { - resolver := NewFromUnindexedDirectory("./test-fixtures/system_paths") + resolver := NewFromUnindexedDirectory("./testdata/system_paths") dirLoc := file.NewLocation("arg/foo") @@ -1214,7 +1214,7 @@ func Test_UnindexedDirectoryResolver_FilesContents_errorOnDirRequest(t *testing. } func Test_UnindexedDirectoryResolver_AllLocations(t *testing.T) { - resolver := NewFromUnindexedDirectory("./test-fixtures/symlinks-from-image-symlinks-fixture") + resolver := NewFromUnindexedDirectory("./testdata/symlinks-from-image-symlinks-fixture") paths := strset.New() ctx, cancel := context.WithCancel(context.Background()) diff --git a/syft/linux/identify_release_test.go b/syft/linux/identify_release_test.go index c81a5ad1f..9aa723a66 100644 --- a/syft/linux/identify_release_test.go +++ b/syft/linux/identify_release_test.go @@ -18,7 +18,7 @@ func TestIdentifyRelease(t *testing.T) { release *Release }{ { - fixture: "test-fixtures/os/alpine", + fixture: "testdata/os/alpine", release: &Release{ PrettyName: "Alpine Linux v3.11", Name: "Alpine Linux", @@ -30,7 +30,7 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/os/amazon", + fixture: "testdata/os/amazon", release: &Release{ PrettyName: "Amazon Linux 2", Name: "Amazon Linux", @@ -47,7 +47,7 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/os/busybox", + fixture: "testdata/os/busybox", release: &Release{ PrettyName: "BusyBox v1.31.1", Name: "busybox", @@ -58,7 +58,7 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/os/centos", + fixture: "testdata/os/centos", release: &Release{ PrettyName: "CentOS Linux 8 (Core)", Name: "CentOS Linux", @@ -74,7 +74,7 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/os/debian/from-os-release", + fixture: "testdata/os/debian/from-os-release", release: &Release{ PrettyName: "Debian GNU/Linux 8 (jessie)", Name: "Debian GNU/Linux", @@ -88,7 +88,7 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/os/debian/from-debian_version", + fixture: "testdata/os/debian/from-debian_version", release: &Release{ PrettyName: "Distroless", Name: "Debian GNU/Linux", @@ -102,7 +102,7 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/os/fedora", + fixture: "testdata/os/fedora", release: &Release{ PrettyName: "Fedora Linux 36 (Container Image)", Name: "Fedora Linux", @@ -121,7 +121,7 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/os/redhat/from-os-release", + fixture: "testdata/os/redhat/from-os-release", release: &Release{ PrettyName: "Red Hat Enterprise Linux Server 7.3 (Maipo)", Name: "Red Hat Enterprise Linux Server", @@ -135,7 +135,7 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/os/redhat/from-redhat-release", + fixture: "testdata/os/redhat/from-redhat-release", release: &Release{ PrettyName: "Red Hat Enterprise Linux release 8.10 (Ootpa)", Name: "Red Hat Enterprise Linux", @@ -146,7 +146,7 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/os/ubuntu", + fixture: "testdata/os/ubuntu", release: &Release{ PrettyName: "Ubuntu 20.04 LTS", Name: "Ubuntu", @@ -162,7 +162,7 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/os/oraclelinux", + fixture: "testdata/os/oraclelinux", release: &Release{ PrettyName: "Oracle Linux Server 8.3", Name: "Oracle Linux Server", @@ -178,10 +178,10 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/os/empty", + fixture: "testdata/os/empty", }, { - fixture: "test-fixtures/os/custom", + fixture: "testdata/os/custom", release: &Release{ PrettyName: "CentOS Linux 8 (Core)", Name: "Scientific Linux", @@ -198,7 +198,7 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/os/opensuse-leap", + fixture: "testdata/os/opensuse-leap", release: &Release{ PrettyName: "openSUSE Leap 15.2", Name: "openSUSE Leap", @@ -215,7 +215,7 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/os/sles", + fixture: "testdata/os/sles", release: &Release{ PrettyName: "SUSE Linux Enterprise Server 15 SP2", Name: "SLES", @@ -227,7 +227,7 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/os/photon", + fixture: "testdata/os/photon", release: &Release{ PrettyName: "VMware Photon OS/Linux", Name: "VMware Photon OS", @@ -240,7 +240,7 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/os/arch", + fixture: "testdata/os/arch", release: &Release{ PrettyName: "Arch Linux", Name: "Arch Linux", @@ -253,7 +253,7 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/partial-fields/missing-id", + fixture: "testdata/partial-fields/missing-id", release: &Release{ Name: "Debian GNU/Linux", IDLike: []string{"debian"}, @@ -261,7 +261,7 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/partial-fields/unknown-id", + fixture: "testdata/partial-fields/unknown-id", release: &Release{ Name: "Debian GNU/Linux", ID: "my-awesome-distro", @@ -270,14 +270,14 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/partial-fields/missing-version", + fixture: "testdata/partial-fields/missing-version", release: &Release{ Name: "Debian GNU/Linux", IDLike: []string{"debian"}, }, }, { - fixture: "test-fixtures/os/centos6", + fixture: "testdata/os/centos6", release: &Release{ PrettyName: "centos", Name: "centos", @@ -289,7 +289,7 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/os/centos5", + fixture: "testdata/os/centos5", release: &Release{ PrettyName: "CentOS release 5.7 (Final)", Name: "CentOS", @@ -300,7 +300,7 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/os/mariner", + fixture: "testdata/os/mariner", release: &Release{ PrettyName: "CBL-Mariner/Linux", Name: "Common Base Linux Mariner", @@ -314,7 +314,7 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/os/rockylinux", + fixture: "testdata/os/rockylinux", release: &Release{ PrettyName: "Rocky Linux 8.4 (Green Obsidian)", Name: "Rocky Linux", @@ -331,7 +331,7 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/os/almalinux", + fixture: "testdata/os/almalinux", release: &Release{ PrettyName: "AlmaLinux 8.4 (Electric Cheetah)", Name: "AlmaLinux", @@ -349,7 +349,7 @@ func TestIdentifyRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/os/wolfi", + fixture: "testdata/os/wolfi", release: &Release{ PrettyName: "Wolfi", Name: "Wolfi", @@ -382,7 +382,7 @@ func TestParseOsRelease(t *testing.T) { release *Release }{ { - fixture: "test-fixtures/ubuntu-20.04", + fixture: "testdata/ubuntu-20.04", release: &Release{ PrettyName: "Ubuntu 20.04 LTS", @@ -400,7 +400,7 @@ func TestParseOsRelease(t *testing.T) { }, { - fixture: "test-fixtures/debian-8", + fixture: "testdata/debian-8", release: &Release{ PrettyName: "Debian GNU/Linux 8 (jessie)", @@ -416,7 +416,7 @@ func TestParseOsRelease(t *testing.T) { }, { - fixture: "test-fixtures/centos-8", + fixture: "testdata/centos-8", release: &Release{ PrettyName: "CentOS Linux 8 (Core)", @@ -435,7 +435,7 @@ func TestParseOsRelease(t *testing.T) { }, { - fixture: "test-fixtures/rhel-8", + fixture: "testdata/rhel-8", release: &Release{ PrettyName: "Red Hat Enterprise Linux 8.1 (Ootpa)", @@ -451,7 +451,7 @@ func TestParseOsRelease(t *testing.T) { }, { - fixture: "test-fixtures/unprintable", + fixture: "testdata/unprintable", release: &Release{ PrettyName: "Debian GNU/Linux 8 (jessie)", @@ -489,7 +489,7 @@ func TestParseSystemReleaseCPE(t *testing.T) { release *Release }{ { - fixture: "test-fixtures/os/centos6/etc/system-release-cpe", + fixture: "testdata/os/centos6/etc/system-release-cpe", release: &Release{ PrettyName: "centos", Name: "centos", @@ -501,7 +501,7 @@ func TestParseSystemReleaseCPE(t *testing.T) { }, }, { - fixture: "test-fixtures/bad-system-release-cpe", + fixture: "testdata/bad-system-release-cpe", release: nil, }, } @@ -528,7 +528,7 @@ func TestParseRedhatRelease(t *testing.T) { release *Release }{ { - fixture: "test-fixtures/os/centos5/etc/redhat-release", + fixture: "testdata/os/centos5/etc/redhat-release", name: "Centos 5", release: &Release{ PrettyName: "CentOS release 5.7 (Final)", @@ -540,7 +540,7 @@ func TestParseRedhatRelease(t *testing.T) { }, }, { - fixture: "test-fixtures/bad-redhat-release", + fixture: "testdata/bad-redhat-release", name: "Centos 5 Bad Redhat Release", release: nil, }, diff --git a/syft/linux/test-fixtures/bad-redhat-release b/syft/linux/testdata/bad-redhat-release similarity index 100% rename from syft/linux/test-fixtures/bad-redhat-release rename to syft/linux/testdata/bad-redhat-release diff --git a/syft/linux/test-fixtures/bad-system-release-cpe b/syft/linux/testdata/bad-system-release-cpe similarity index 100% rename from syft/linux/test-fixtures/bad-system-release-cpe rename to syft/linux/testdata/bad-system-release-cpe diff --git a/syft/linux/test-fixtures/centos-8 b/syft/linux/testdata/centos-8 similarity index 100% rename from syft/linux/test-fixtures/centos-8 rename to syft/linux/testdata/centos-8 diff --git a/syft/linux/test-fixtures/debian-8 b/syft/linux/testdata/debian-8 similarity index 100% rename from syft/linux/test-fixtures/debian-8 rename to syft/linux/testdata/debian-8 diff --git a/syft/linux/test-fixtures/os/almalinux/etc/os-release b/syft/linux/testdata/os/almalinux/etc/os-release similarity index 100% rename from syft/linux/test-fixtures/os/almalinux/etc/os-release rename to syft/linux/testdata/os/almalinux/etc/os-release diff --git a/syft/linux/test-fixtures/os/alpine/etc/os-release b/syft/linux/testdata/os/alpine/etc/os-release similarity index 100% rename from syft/linux/test-fixtures/os/alpine/etc/os-release rename to syft/linux/testdata/os/alpine/etc/os-release diff --git a/syft/linux/test-fixtures/os/amazon/etc/os-release b/syft/linux/testdata/os/amazon/etc/os-release similarity index 100% rename from syft/linux/test-fixtures/os/amazon/etc/os-release rename to syft/linux/testdata/os/amazon/etc/os-release diff --git a/syft/linux/test-fixtures/os/arch/etc/os-release b/syft/linux/testdata/os/arch/etc/os-release similarity index 100% rename from syft/linux/test-fixtures/os/arch/etc/os-release rename to syft/linux/testdata/os/arch/etc/os-release diff --git a/syft/linux/testdata/os/busybox/.gitignore b/syft/linux/testdata/os/busybox/.gitignore new file mode 100644 index 000000000..905bc56c0 --- /dev/null +++ b/syft/linux/testdata/os/busybox/.gitignore @@ -0,0 +1,2 @@ +# override root level ignores for test fixtures +!bin/ diff --git a/syft/linux/testdata/os/busybox/bin/.gitignore b/syft/linux/testdata/os/busybox/bin/.gitignore new file mode 100644 index 000000000..5022a8e0b --- /dev/null +++ b/syft/linux/testdata/os/busybox/bin/.gitignore @@ -0,0 +1,2 @@ +# override root level ignores for test fixtures +!* diff --git a/syft/linux/test-fixtures/os/busybox/bin/busybox b/syft/linux/testdata/os/busybox/bin/busybox similarity index 100% rename from syft/linux/test-fixtures/os/busybox/bin/busybox rename to syft/linux/testdata/os/busybox/bin/busybox diff --git a/syft/linux/test-fixtures/os/centos/usr/lib/os-release b/syft/linux/testdata/os/centos/usr/lib/os-release similarity index 100% rename from syft/linux/test-fixtures/os/centos/usr/lib/os-release rename to syft/linux/testdata/os/centos/usr/lib/os-release diff --git a/syft/linux/test-fixtures/os/centos5/etc/redhat-release b/syft/linux/testdata/os/centos5/etc/redhat-release similarity index 100% rename from syft/linux/test-fixtures/os/centos5/etc/redhat-release rename to syft/linux/testdata/os/centos5/etc/redhat-release diff --git a/syft/linux/test-fixtures/os/centos6/etc/system-release-cpe b/syft/linux/testdata/os/centos6/etc/system-release-cpe similarity index 100% rename from syft/linux/test-fixtures/os/centos6/etc/system-release-cpe rename to syft/linux/testdata/os/centos6/etc/system-release-cpe diff --git a/syft/linux/test-fixtures/os/custom/etc/os-release b/syft/linux/testdata/os/custom/etc/os-release similarity index 100% rename from syft/linux/test-fixtures/os/custom/etc/os-release rename to syft/linux/testdata/os/custom/etc/os-release diff --git a/syft/linux/test-fixtures/os/debian/from-debian_version/etc/debian_version b/syft/linux/testdata/os/debian/from-debian_version/etc/debian_version similarity index 100% rename from syft/linux/test-fixtures/os/debian/from-debian_version/etc/debian_version rename to syft/linux/testdata/os/debian/from-debian_version/etc/debian_version diff --git a/syft/linux/test-fixtures/os/debian/from-debian_version/etc/os-release b/syft/linux/testdata/os/debian/from-debian_version/etc/os-release similarity index 100% rename from syft/linux/test-fixtures/os/debian/from-debian_version/etc/os-release rename to syft/linux/testdata/os/debian/from-debian_version/etc/os-release diff --git a/syft/linux/test-fixtures/os/debian/from-os-release/usr/lib/os-release b/syft/linux/testdata/os/debian/from-os-release/usr/lib/os-release similarity index 100% rename from syft/linux/test-fixtures/os/debian/from-os-release/usr/lib/os-release rename to syft/linux/testdata/os/debian/from-os-release/usr/lib/os-release diff --git a/syft/linux/test-fixtures/os/empty/etc/os-release b/syft/linux/testdata/os/empty/etc/os-release similarity index 100% rename from syft/linux/test-fixtures/os/empty/etc/os-release rename to syft/linux/testdata/os/empty/etc/os-release diff --git a/syft/linux/test-fixtures/os/fedora/usr/lib/os-release b/syft/linux/testdata/os/fedora/usr/lib/os-release similarity index 100% rename from syft/linux/test-fixtures/os/fedora/usr/lib/os-release rename to syft/linux/testdata/os/fedora/usr/lib/os-release diff --git a/syft/linux/test-fixtures/os/mariner/etc/os-release b/syft/linux/testdata/os/mariner/etc/os-release similarity index 100% rename from syft/linux/test-fixtures/os/mariner/etc/os-release rename to syft/linux/testdata/os/mariner/etc/os-release diff --git a/syft/linux/test-fixtures/os/opensuse-leap/etc/os-release b/syft/linux/testdata/os/opensuse-leap/etc/os-release similarity index 100% rename from syft/linux/test-fixtures/os/opensuse-leap/etc/os-release rename to syft/linux/testdata/os/opensuse-leap/etc/os-release diff --git a/syft/linux/test-fixtures/os/oraclelinux/etc/os-release b/syft/linux/testdata/os/oraclelinux/etc/os-release similarity index 100% rename from syft/linux/test-fixtures/os/oraclelinux/etc/os-release rename to syft/linux/testdata/os/oraclelinux/etc/os-release diff --git a/syft/linux/test-fixtures/os/photon/etc/os-release b/syft/linux/testdata/os/photon/etc/os-release similarity index 100% rename from syft/linux/test-fixtures/os/photon/etc/os-release rename to syft/linux/testdata/os/photon/etc/os-release diff --git a/syft/linux/test-fixtures/os/redhat/from-os-release/usr/lib/os-release b/syft/linux/testdata/os/redhat/from-os-release/usr/lib/os-release similarity index 100% rename from syft/linux/test-fixtures/os/redhat/from-os-release/usr/lib/os-release rename to syft/linux/testdata/os/redhat/from-os-release/usr/lib/os-release diff --git a/syft/linux/test-fixtures/os/redhat/from-redhat-release/etc/redhat-release b/syft/linux/testdata/os/redhat/from-redhat-release/etc/redhat-release similarity index 100% rename from syft/linux/test-fixtures/os/redhat/from-redhat-release/etc/redhat-release rename to syft/linux/testdata/os/redhat/from-redhat-release/etc/redhat-release diff --git a/syft/linux/test-fixtures/os/rockylinux/etc/os-release b/syft/linux/testdata/os/rockylinux/etc/os-release similarity index 100% rename from syft/linux/test-fixtures/os/rockylinux/etc/os-release rename to syft/linux/testdata/os/rockylinux/etc/os-release diff --git a/syft/linux/test-fixtures/os/sles/etc/os-release b/syft/linux/testdata/os/sles/etc/os-release similarity index 100% rename from syft/linux/test-fixtures/os/sles/etc/os-release rename to syft/linux/testdata/os/sles/etc/os-release diff --git a/syft/linux/test-fixtures/os/ubuntu/etc/os-release b/syft/linux/testdata/os/ubuntu/etc/os-release similarity index 100% rename from syft/linux/test-fixtures/os/ubuntu/etc/os-release rename to syft/linux/testdata/os/ubuntu/etc/os-release diff --git a/syft/linux/test-fixtures/os/wolfi/etc/os-release b/syft/linux/testdata/os/wolfi/etc/os-release similarity index 100% rename from syft/linux/test-fixtures/os/wolfi/etc/os-release rename to syft/linux/testdata/os/wolfi/etc/os-release diff --git a/syft/linux/test-fixtures/partial-fields/missing-id/usr/lib/os-release b/syft/linux/testdata/partial-fields/missing-id/usr/lib/os-release similarity index 100% rename from syft/linux/test-fixtures/partial-fields/missing-id/usr/lib/os-release rename to syft/linux/testdata/partial-fields/missing-id/usr/lib/os-release diff --git a/syft/linux/test-fixtures/partial-fields/missing-version/usr/lib/os-release b/syft/linux/testdata/partial-fields/missing-version/usr/lib/os-release similarity index 100% rename from syft/linux/test-fixtures/partial-fields/missing-version/usr/lib/os-release rename to syft/linux/testdata/partial-fields/missing-version/usr/lib/os-release diff --git a/syft/linux/test-fixtures/partial-fields/unknown-id/usr/lib/os-release b/syft/linux/testdata/partial-fields/unknown-id/usr/lib/os-release similarity index 100% rename from syft/linux/test-fixtures/partial-fields/unknown-id/usr/lib/os-release rename to syft/linux/testdata/partial-fields/unknown-id/usr/lib/os-release diff --git a/syft/linux/test-fixtures/rhel-8 b/syft/linux/testdata/rhel-8 similarity index 100% rename from syft/linux/test-fixtures/rhel-8 rename to syft/linux/testdata/rhel-8 diff --git a/syft/linux/test-fixtures/ubuntu-20.04 b/syft/linux/testdata/ubuntu-20.04 similarity index 100% rename from syft/linux/test-fixtures/ubuntu-20.04 rename to syft/linux/testdata/ubuntu-20.04 diff --git a/syft/linux/test-fixtures/unprintable b/syft/linux/testdata/unprintable similarity index 100% rename from syft/linux/test-fixtures/unprintable rename to syft/linux/testdata/unprintable diff --git a/syft/pkg/cataloger/.gitignore b/syft/pkg/cataloger/.gitignore index 752bd7a6c..dea90f76f 100644 --- a/syft/pkg/cataloger/.gitignore +++ b/syft/pkg/cataloger/.gitignore @@ -1,2 +1,3 @@ # these are generated by pkgtest helpers, no need to check them in -**/test-fixtures/test-observations.json \ No newline at end of file +**/test-fixtures/test-observations.json +**/testdata/test-observations.json \ No newline at end of file diff --git a/syft/pkg/cataloger/ai/cataloger_test.go b/syft/pkg/cataloger/ai/cataloger_test.go index cb4b7573f..f3a99e9e2 100644 --- a/syft/pkg/cataloger/ai/cataloger_test.go +++ b/syft/pkg/cataloger/ai/cataloger_test.go @@ -18,7 +18,7 @@ func TestGGUFCataloger_Globs(t *testing.T) { }{ { name: "obtain gguf files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "models/model.gguf", }, diff --git a/syft/pkg/cataloger/ai/test-fixtures/glob-paths/models/model.gguf b/syft/pkg/cataloger/ai/testdata/glob-paths/models/model.gguf similarity index 100% rename from syft/pkg/cataloger/ai/test-fixtures/glob-paths/models/model.gguf rename to syft/pkg/cataloger/ai/testdata/glob-paths/models/model.gguf diff --git a/syft/pkg/cataloger/alpine/cataloger_test.go b/syft/pkg/cataloger/alpine/cataloger_test.go index dd90b469a..d5cdd9957 100644 --- a/syft/pkg/cataloger/alpine/cataloger_test.go +++ b/syft/pkg/cataloger/alpine/cataloger_test.go @@ -184,7 +184,7 @@ func TestApkDBCataloger(t *testing.T) { } pkgtest.NewCatalogTester(). - FromDirectory(t, "test-fixtures/multiple-1"). + FromDirectory(t, "testdata/multiple-1"). WithCompareOptions(cmpopts.IgnoreFields(pkg.ApkDBEntry{}, "Files", "GitCommit", "Checksum")). Expects(expectedPkgs, expectedRelationships). TestCataloger(t, NewDBCataloger()) @@ -193,7 +193,7 @@ func TestApkDBCataloger(t *testing.T) { func Test_corruptDb(t *testing.T) { pkgtest.NewCatalogTester(). - FromDirectory(t, "test-fixtures/corrupt"). + FromDirectory(t, "testdata/corrupt"). WithCompareOptions(cmpopts.IgnoreFields(pkg.ApkDBEntry{}, "Files", "GitCommit", "Checksum")). WithError(). TestCataloger(t, NewDBCataloger()) @@ -239,7 +239,7 @@ func TestCatalogerDependencyTree(t *testing.T) { } pkgtest.NewCatalogTester(). - FromDirectory(t, "test-fixtures/multiple-2"). + FromDirectory(t, "testdata/multiple-2"). ExpectsAssertion(assertion). TestCataloger(t, NewDBCataloger()) @@ -253,7 +253,7 @@ func TestCataloger_Globs(t *testing.T) { }{ { name: "obtain DB files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{"lib/apk/db/installed"}, }, } diff --git a/syft/pkg/cataloger/alpine/parse_apk_db_test.go b/syft/pkg/cataloger/alpine/parse_apk_db_test.go index 7f3b9ce1e..0354a5931 100644 --- a/syft/pkg/cataloger/alpine/parse_apk_db_test.go +++ b/syft/pkg/cataloger/alpine/parse_apk_db_test.go @@ -60,7 +60,7 @@ func TestExtraFileAttributes(t *testing.T) { for _, test := range tests { t.Run(test.name, func(t *testing.T) { - fixturePath := "test-fixtures/extra-file-attributes" + fixturePath := "testdata/extra-file-attributes" lrc := newLocationReadCloser(t, fixturePath) pkgs, _, err := parseApkDB(context.Background(), nil, new(generic.Environment), lrc) @@ -82,7 +82,7 @@ func TestSinglePackageDetails(t *testing.T) { expected pkg.Package }{ { - fixture: "test-fixtures/single", + fixture: "testdata/single", expected: pkg.Package{ Name: "musl-utils", Version: "1.1.24-r2", @@ -171,7 +171,7 @@ func TestSinglePackageDetails(t *testing.T) { }, }, { - fixture: "test-fixtures/empty-deps-and-provides", + fixture: "testdata/empty-deps-and-provides", expected: pkg.Package{ Name: "alpine-baselayout-data", Version: "3.4.0-r0", @@ -215,7 +215,7 @@ func TestSinglePackageDetails(t *testing.T) { }, }, { - fixture: "test-fixtures/base", + fixture: "testdata/base", expected: pkg.Package{ Name: "alpine-baselayout", Version: "3.2.0-r6", @@ -774,7 +774,7 @@ func Test_parseApkDB_expectedPkgNames(t *testing.T) { for _, test := range tests { t.Run(test.fixture, func(t *testing.T) { - fixturePath := filepath.Join("test-fixtures", test.fixture) + fixturePath := filepath.Join("testdata", test.fixture) lrc := newLocationReadCloser(t, fixturePath) pkgs, _, err := parseApkDB(context.Background(), nil, new(generic.Environment), lrc) diff --git a/syft/pkg/cataloger/alpine/test-fixtures/base b/syft/pkg/cataloger/alpine/testdata/base similarity index 100% rename from syft/pkg/cataloger/alpine/test-fixtures/base rename to syft/pkg/cataloger/alpine/testdata/base diff --git a/syft/pkg/cataloger/alpine/test-fixtures/corrupt/lib/apk/db/installed b/syft/pkg/cataloger/alpine/testdata/corrupt/lib/apk/db/installed similarity index 100% rename from syft/pkg/cataloger/alpine/test-fixtures/corrupt/lib/apk/db/installed rename to syft/pkg/cataloger/alpine/testdata/corrupt/lib/apk/db/installed diff --git a/syft/pkg/cataloger/alpine/test-fixtures/empty-deps-and-provides b/syft/pkg/cataloger/alpine/testdata/empty-deps-and-provides similarity index 100% rename from syft/pkg/cataloger/alpine/test-fixtures/empty-deps-and-provides rename to syft/pkg/cataloger/alpine/testdata/empty-deps-and-provides diff --git a/syft/pkg/cataloger/alpine/test-fixtures/extra-file-attributes b/syft/pkg/cataloger/alpine/testdata/extra-file-attributes similarity index 100% rename from syft/pkg/cataloger/alpine/test-fixtures/extra-file-attributes rename to syft/pkg/cataloger/alpine/testdata/extra-file-attributes diff --git a/syft/pkg/cataloger/alpine/test-fixtures/glob-paths/lib/apk/db/installed b/syft/pkg/cataloger/alpine/testdata/glob-paths/lib/apk/db/installed similarity index 100% rename from syft/pkg/cataloger/alpine/test-fixtures/glob-paths/lib/apk/db/installed rename to syft/pkg/cataloger/alpine/testdata/glob-paths/lib/apk/db/installed diff --git a/syft/pkg/cataloger/alpine/test-fixtures/multiple-1/lib/apk/db/installed b/syft/pkg/cataloger/alpine/testdata/multiple-1/lib/apk/db/installed similarity index 100% rename from syft/pkg/cataloger/alpine/test-fixtures/multiple-1/lib/apk/db/installed rename to syft/pkg/cataloger/alpine/testdata/multiple-1/lib/apk/db/installed diff --git a/syft/pkg/cataloger/alpine/test-fixtures/multiple-2/lib/apk/db/installed b/syft/pkg/cataloger/alpine/testdata/multiple-2/lib/apk/db/installed similarity index 100% rename from syft/pkg/cataloger/alpine/test-fixtures/multiple-2/lib/apk/db/installed rename to syft/pkg/cataloger/alpine/testdata/multiple-2/lib/apk/db/installed diff --git a/syft/pkg/cataloger/alpine/test-fixtures/single b/syft/pkg/cataloger/alpine/testdata/single similarity index 100% rename from syft/pkg/cataloger/alpine/test-fixtures/single rename to syft/pkg/cataloger/alpine/testdata/single diff --git a/syft/pkg/cataloger/alpine/test-fixtures/very-large-entries b/syft/pkg/cataloger/alpine/testdata/very-large-entries similarity index 100% rename from syft/pkg/cataloger/alpine/test-fixtures/very-large-entries rename to syft/pkg/cataloger/alpine/testdata/very-large-entries diff --git a/syft/pkg/cataloger/arch/cataloger_test.go b/syft/pkg/cataloger/arch/cataloger_test.go index d234d8507..dd014086c 100644 --- a/syft/pkg/cataloger/arch/cataloger_test.go +++ b/syft/pkg/cataloger/arch/cataloger_test.go @@ -14,7 +14,7 @@ import ( func TestAlpmUnknowns(t *testing.T) { pkgtest.NewCatalogTester(). - FromDirectory(t, "test-fixtures/installed"). + FromDirectory(t, "testdata/installed"). WithCompareOptions(cmpopts.IgnoreFields(pkg.AlpmFileRecord{}, "Time")). WithError(). TestCataloger(t, NewDBCataloger()) @@ -304,7 +304,7 @@ func TestAlpmCataloger(t *testing.T) { } pkgtest.NewCatalogTester(). - FromDirectory(t, "test-fixtures/installed"). + FromDirectory(t, "testdata/installed"). WithCompareOptions(cmpopts.IgnoreFields(pkg.AlpmFileRecord{}, "Time")). Expects(expectedPkgs, expectedRelationships). TestCataloger(t, NewDBCataloger()) @@ -319,7 +319,7 @@ func TestCataloger_Globs(t *testing.T) { }{ { name: "obtain description files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "var/lib/pacman/local/base-1.0/desc", "var/lib/pacman/local/dive-0.10.0/desc", diff --git a/syft/pkg/cataloger/arch/parse_alpm_db_test.go b/syft/pkg/cataloger/arch/parse_alpm_db_test.go index 10b367a35..a046fff88 100644 --- a/syft/pkg/cataloger/arch/parse_alpm_db_test.go +++ b/syft/pkg/cataloger/arch/parse_alpm_db_test.go @@ -21,7 +21,7 @@ func TestDatabaseParser(t *testing.T) { }{ { name: "simple desc parsing", - fixture: "test-fixtures/files", + fixture: "testdata/files", expected: &parsedData{ AlpmDBEntry: pkg.AlpmDBEntry{ Backup: []pkg.AlpmFileRecord{ @@ -92,7 +92,7 @@ func TestDatabaseParser(t *testing.T) { }, { name: "with dependencies", - fixture: "test-fixtures/installed/var/lib/pacman/local/gmp-6.2.1-2/desc", + fixture: "testdata/installed/var/lib/pacman/local/gmp-6.2.1-2/desc", expected: &parsedData{ Licenses: "LGPL3\nGPL", AlpmDBEntry: pkg.AlpmDBEntry{ @@ -114,7 +114,7 @@ func TestDatabaseParser(t *testing.T) { }, { name: "with provides", - fixture: "test-fixtures/installed/var/lib/pacman/local/tree-sitter-0.22.6-1/desc", + fixture: "testdata/installed/var/lib/pacman/local/tree-sitter-0.22.6-1/desc", expected: &parsedData{ Licenses: "MIT", AlpmDBEntry: pkg.AlpmDBEntry{ @@ -201,7 +201,7 @@ func TestMtreeParse(t *testing.T) { for _, test := range tests { t.Run(test.name, func(t *testing.T) { - f, err := os.Open("test-fixtures/mtree") + f, err := os.Open("testdata/mtree") require.NoError(t, err) t.Cleanup(func() { require.NoError(t, f.Close()) }) diff --git a/syft/pkg/cataloger/arch/test-fixtures/files b/syft/pkg/cataloger/arch/testdata/files similarity index 100% rename from syft/pkg/cataloger/arch/test-fixtures/files rename to syft/pkg/cataloger/arch/testdata/files diff --git a/syft/pkg/cataloger/arch/test-fixtures/glob-paths/var/lib/pacman/local/base-1.0/desc b/syft/pkg/cataloger/arch/testdata/glob-paths/var/lib/pacman/local/base-1.0/desc similarity index 100% rename from syft/pkg/cataloger/arch/test-fixtures/glob-paths/var/lib/pacman/local/base-1.0/desc rename to syft/pkg/cataloger/arch/testdata/glob-paths/var/lib/pacman/local/base-1.0/desc diff --git a/syft/pkg/cataloger/arch/test-fixtures/glob-paths/var/lib/pacman/local/base-1.0/files b/syft/pkg/cataloger/arch/testdata/glob-paths/var/lib/pacman/local/base-1.0/files similarity index 100% rename from syft/pkg/cataloger/arch/test-fixtures/glob-paths/var/lib/pacman/local/base-1.0/files rename to syft/pkg/cataloger/arch/testdata/glob-paths/var/lib/pacman/local/base-1.0/files diff --git a/syft/pkg/cataloger/arch/test-fixtures/glob-paths/var/lib/pacman/local/dive-0.10.0/desc b/syft/pkg/cataloger/arch/testdata/glob-paths/var/lib/pacman/local/dive-0.10.0/desc similarity index 100% rename from syft/pkg/cataloger/arch/test-fixtures/glob-paths/var/lib/pacman/local/dive-0.10.0/desc rename to syft/pkg/cataloger/arch/testdata/glob-paths/var/lib/pacman/local/dive-0.10.0/desc diff --git a/syft/pkg/cataloger/arch/test-fixtures/installed/var/lib/pacman/local/corrupt-0.2.1-3/desc b/syft/pkg/cataloger/arch/testdata/installed/var/lib/pacman/local/corrupt-0.2.1-3/desc similarity index 100% rename from syft/pkg/cataloger/arch/test-fixtures/installed/var/lib/pacman/local/corrupt-0.2.1-3/desc rename to syft/pkg/cataloger/arch/testdata/installed/var/lib/pacman/local/corrupt-0.2.1-3/desc diff --git a/syft/pkg/cataloger/arch/test-fixtures/installed/var/lib/pacman/local/emacs-29.3-3/desc b/syft/pkg/cataloger/arch/testdata/installed/var/lib/pacman/local/emacs-29.3-3/desc similarity index 100% rename from syft/pkg/cataloger/arch/test-fixtures/installed/var/lib/pacman/local/emacs-29.3-3/desc rename to syft/pkg/cataloger/arch/testdata/installed/var/lib/pacman/local/emacs-29.3-3/desc diff --git a/syft/pkg/cataloger/arch/test-fixtures/installed/var/lib/pacman/local/fuzzy-1.2-3/desc b/syft/pkg/cataloger/arch/testdata/installed/var/lib/pacman/local/fuzzy-1.2-3/desc similarity index 100% rename from syft/pkg/cataloger/arch/test-fixtures/installed/var/lib/pacman/local/fuzzy-1.2-3/desc rename to syft/pkg/cataloger/arch/testdata/installed/var/lib/pacman/local/fuzzy-1.2-3/desc diff --git a/syft/pkg/cataloger/arch/test-fixtures/installed/var/lib/pacman/local/fuzzy-1.2-3/files b/syft/pkg/cataloger/arch/testdata/installed/var/lib/pacman/local/fuzzy-1.2-3/files similarity index 100% rename from syft/pkg/cataloger/arch/test-fixtures/installed/var/lib/pacman/local/fuzzy-1.2-3/files rename to syft/pkg/cataloger/arch/testdata/installed/var/lib/pacman/local/fuzzy-1.2-3/files diff --git a/syft/pkg/cataloger/arch/test-fixtures/installed/var/lib/pacman/local/gmp-6.2.1-2/desc b/syft/pkg/cataloger/arch/testdata/installed/var/lib/pacman/local/gmp-6.2.1-2/desc similarity index 100% rename from syft/pkg/cataloger/arch/test-fixtures/installed/var/lib/pacman/local/gmp-6.2.1-2/desc rename to syft/pkg/cataloger/arch/testdata/installed/var/lib/pacman/local/gmp-6.2.1-2/desc diff --git a/syft/pkg/cataloger/arch/test-fixtures/installed/var/lib/pacman/local/gmp-6.2.1-2/files b/syft/pkg/cataloger/arch/testdata/installed/var/lib/pacman/local/gmp-6.2.1-2/files similarity index 100% rename from syft/pkg/cataloger/arch/test-fixtures/installed/var/lib/pacman/local/gmp-6.2.1-2/files rename to syft/pkg/cataloger/arch/testdata/installed/var/lib/pacman/local/gmp-6.2.1-2/files diff --git a/syft/pkg/cataloger/arch/test-fixtures/installed/var/lib/pacman/local/gmp-6.2.1-2/mtree b/syft/pkg/cataloger/arch/testdata/installed/var/lib/pacman/local/gmp-6.2.1-2/mtree similarity index 100% rename from syft/pkg/cataloger/arch/test-fixtures/installed/var/lib/pacman/local/gmp-6.2.1-2/mtree rename to syft/pkg/cataloger/arch/testdata/installed/var/lib/pacman/local/gmp-6.2.1-2/mtree diff --git a/syft/pkg/cataloger/arch/test-fixtures/installed/var/lib/pacman/local/madeup-20.30-4/desc b/syft/pkg/cataloger/arch/testdata/installed/var/lib/pacman/local/madeup-20.30-4/desc similarity index 100% rename from syft/pkg/cataloger/arch/test-fixtures/installed/var/lib/pacman/local/madeup-20.30-4/desc rename to syft/pkg/cataloger/arch/testdata/installed/var/lib/pacman/local/madeup-20.30-4/desc diff --git a/syft/pkg/cataloger/arch/test-fixtures/installed/var/lib/pacman/local/tree-sitter-0.22.6-1/desc b/syft/pkg/cataloger/arch/testdata/installed/var/lib/pacman/local/tree-sitter-0.22.6-1/desc similarity index 100% rename from syft/pkg/cataloger/arch/test-fixtures/installed/var/lib/pacman/local/tree-sitter-0.22.6-1/desc rename to syft/pkg/cataloger/arch/testdata/installed/var/lib/pacman/local/tree-sitter-0.22.6-1/desc diff --git a/syft/pkg/cataloger/arch/test-fixtures/mtree b/syft/pkg/cataloger/arch/testdata/mtree similarity index 100% rename from syft/pkg/cataloger/arch/test-fixtures/mtree rename to syft/pkg/cataloger/arch/testdata/mtree diff --git a/syft/pkg/cataloger/binary/README.md b/syft/pkg/cataloger/binary/README.md index e4cb9cd67..f6b31290a 100644 --- a/syft/pkg/cataloger/binary/README.md +++ b/syft/pkg/cataloger/binary/README.md @@ -2,7 +2,7 @@ > [!TIP] > **TL;DR** to add a test for a new classifier: -> 1. head to the correct directory: `cd test-fixtures` +> 1. head to the correct directory: `cd testdata` > 2. add a new entry to `config.yaml` to track where to get the binary from (verify the entry with `make list`) > 3. run `make download` to get the binary > 4. run `make add-snippet` and follow the prompts (use `/` to search) @@ -20,7 +20,7 @@ The upside with full binaries is that they are the "Real McCoy" and allows the b You can find the test fixtures at the following locations: ``` -syft/pkg/cataloger/binary/test-fixtures/ +syft/pkg/cataloger/binary/testdata/ └── classifiers/ ├── bin/ # full binaries ├── ... @@ -77,7 +77,7 @@ The test cases have been setup to allow testing against full binaries or a mix o To force running only against full binaries run with: ```bash -go test -must-use-full-binaries ./syft/pkg/cataloger/binary/test-fixtures/... +go test -must-use-full-binaries ./syft/pkg/cataloger/binary/testdata/... ``` ## Adding a new test fixture diff --git a/syft/pkg/cataloger/binary/classifier_cataloger_test.go b/syft/pkg/cataloger/binary/classifier_cataloger_test.go index 3ff8f328f..65fedc92a 100644 --- a/syft/pkg/cataloger/binary/classifier_cataloger_test.go +++ b/syft/pkg/cataloger/binary/classifier_cataloger_test.go @@ -20,7 +20,7 @@ import ( "github.com/anchore/syft/syft/cpe" "github.com/anchore/syft/syft/file" "github.com/anchore/syft/syft/pkg" - "github.com/anchore/syft/syft/pkg/cataloger/binary/test-fixtures/manager/testutil" + "github.com/anchore/syft/syft/pkg/cataloger/binary/internal/manager/testutil" "github.com/anchore/syft/syft/pkg/cataloger/internal/binutils" "github.com/anchore/syft/syft/source" "github.com/anchore/syft/syft/source/directorysource" @@ -32,8 +32,8 @@ var mustUseOriginalBinaries = flag.Bool("must-use-original-binaries", false, "fo func Test_Cataloger_PositiveCases(t *testing.T) { tests := []struct { name string - // logicalFixture is the logical path to the full binary or snippet. This is relative to the test-fixtures/classifiers/snippets - // or test-fixtures/classifiers/bin directory . Snippets are searched for first, and if not found, then existing binaries are + // logicalFixture is the logical path to the full binary or snippet. This is relative to the testdata/classifiers/snippets + // or testdata/classifiers/bin directory . Snippets are searched for first, and if not found, then existing binaries are // used. If no binary or snippet is found the test will fail. If '-must-use-original-binaries' is used the only // full binaries are tested (no snippets), and if no binary is found the test will be skipped. logicalFixture string @@ -1948,8 +1948,8 @@ func Test_Cataloger_PositiveCases(t *testing.T) { t.Run(test.logicalFixture, func(t *testing.T) { c := NewClassifierCataloger(DefaultClassifierCatalogerConfig()) - // logicalFixture is the logical path to the full binary or snippet. This is relative to the test-fixtures/classifiers/snippets - // or test-fixtures/classifiers/bin directory . Snippets are searched for first, and if not found, then existing binaries are + // logicalFixture is the logical path to the full binary or snippet. This is relative to the testdata/classifiers/snippets + // or testdata/classifiers/bin directory . Snippets are searched for first, and if not found, then existing binaries are // used. If no binary or snippet is found the test will fail. If '-must-use-original-binaries' is used the only // full binaries are tested (no snippets), and if no binary is found the test will be skipped. path := testutil.SnippetOrBinary(t, test.logicalFixture, *mustUseOriginalBinaries) @@ -2014,7 +2014,7 @@ func Test_Cataloger_DefaultClassifiers_PositiveCases_Image(t *testing.T) { func TestClassifierCataloger_DefaultClassifiers_NegativeCases(t *testing.T) { c := NewClassifierCataloger(DefaultClassifierCatalogerConfig()) - src, err := directorysource.NewFromPath("test-fixtures/classifiers/negative") + src, err := directorysource.NewFromPath("testdata/classifiers/negative") assert.NoError(t, err) resolver, err := src.FileResolver(source.SquashedScope) @@ -2065,7 +2065,7 @@ func Test_Cataloger_CustomClassifiers(t *testing.T) { config: ClassifierCatalogerConfig{ Classifiers: []binutils.Classifier{}, }, - fixtureDir: "test-fixtures/custom/go-1.14", + fixtureDir: "testdata/custom/go-1.14", expected: nil, }, { @@ -2073,7 +2073,7 @@ func Test_Cataloger_CustomClassifiers(t *testing.T) { config: ClassifierCatalogerConfig{ Classifiers: defaultClassifers, }, - fixtureDir: "test-fixtures/custom/go-1.14", + fixtureDir: "testdata/custom/go-1.14", expected: &golangExpected, }, { @@ -2081,7 +2081,7 @@ func Test_Cataloger_CustomClassifiers(t *testing.T) { config: ClassifierCatalogerConfig{ Classifiers: []binutils.Classifier{fooClassifier}, }, - fixtureDir: "test-fixtures/custom/go-1.14", + fixtureDir: "testdata/custom/go-1.14", expected: nil, }, { @@ -2092,7 +2092,7 @@ func Test_Cataloger_CustomClassifiers(t *testing.T) { fooClassifier, ), }, - fixtureDir: "test-fixtures/custom/go-1.14", + fixtureDir: "testdata/custom/go-1.14", expected: &golangExpected, }, { @@ -2111,7 +2111,7 @@ func Test_Cataloger_CustomClassifiers(t *testing.T) { }, ), }, - fixtureDir: "test-fixtures/custom/extra", + fixtureDir: "testdata/custom/extra", expected: nil, }, { @@ -2122,7 +2122,7 @@ func Test_Cataloger_CustomClassifiers(t *testing.T) { fooClassifier, ), }, - fixtureDir: "test-fixtures/custom/extra", + fixtureDir: "testdata/custom/extra", expected: &customExpected, }, } diff --git a/syft/pkg/cataloger/binary/elf_package_cataloger_test.go b/syft/pkg/cataloger/binary/elf_package_cataloger_test.go index 7a29d3d44..708bb578f 100644 --- a/syft/pkg/cataloger/binary/elf_package_cataloger_test.go +++ b/syft/pkg/cataloger/binary/elf_package_cataloger_test.go @@ -21,7 +21,7 @@ func Test_ELFPackageCataloger(t *testing.T) { }{ { name: "go case", - fixture: "elf-test-fixtures", + fixture: "elf-testdata", expected: []pkg.Package{ { Name: "libhello_world.so", @@ -119,8 +119,8 @@ func Test_ELFPackageCataloger(t *testing.T) { expected: []pkg.Package{ { Name: "glibc", - Version: "2.42-r4", - PURL: "pkg:apk/wolfi/glibc@2.42-r4?distro=wolfi", + Version: "2.43-r2", + PURL: "pkg:apk/wolfi/glibc@2.43-r2?distro=wolfi", Locations: file.NewLocationSet( file.NewLocationFromDirectory("/lib/libBrokenLocale.so.1", "sha256:559eaef4e501b8e7a150661a94ee8b9ebc63bfca3256953a703f9f82053346f2", diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/cli/cli.go b/syft/pkg/cataloger/binary/internal/manager/internal/cli/cli.go similarity index 81% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/cli/cli.go rename to syft/pkg/cataloger/binary/internal/manager/internal/cli/cli.go index 30b7dac4e..be3816229 100644 --- a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/cli/cli.go +++ b/syft/pkg/cataloger/binary/internal/manager/internal/cli/cli.go @@ -3,8 +3,8 @@ package cli import ( "github.com/spf13/cobra" - "github.com/anchore/syft/syft/pkg/cataloger/binary/test-fixtures/manager/internal/cli/commands" - "github.com/anchore/syft/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config" + "github.com/anchore/syft/syft/pkg/cataloger/binary/internal/manager/internal/cli/commands" + "github.com/anchore/syft/syft/pkg/cataloger/binary/internal/manager/internal/config" ) // list all managed binaries (in ./bin, organized by 'name-version/platform/binary') diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/cli/commands/add_snippet.go b/syft/pkg/cataloger/binary/internal/manager/internal/cli/commands/add_snippet.go similarity index 91% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/cli/commands/add_snippet.go rename to syft/pkg/cataloger/binary/internal/manager/internal/cli/commands/add_snippet.go index fbffe8b99..240f0982f 100644 --- a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/cli/commands/add_snippet.go +++ b/syft/pkg/cataloger/binary/internal/manager/internal/cli/commands/add_snippet.go @@ -9,9 +9,9 @@ import ( "github.com/anmitsu/go-shlex" "github.com/spf13/cobra" - "github.com/anchore/syft/syft/pkg/cataloger/binary/test-fixtures/manager/internal" - "github.com/anchore/syft/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config" - "github.com/anchore/syft/syft/pkg/cataloger/binary/test-fixtures/manager/internal/ui" + "github.com/anchore/syft/syft/pkg/cataloger/binary/internal/manager/internal" + "github.com/anchore/syft/syft/pkg/cataloger/binary/internal/manager/internal/config" + "github.com/anchore/syft/syft/pkg/cataloger/binary/internal/manager/internal/ui" ) func AddSnippet(appConfig config.Application) *cobra.Command { diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/cli/commands/download.go b/syft/pkg/cataloger/binary/internal/manager/internal/cli/commands/download.go similarity index 90% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/cli/commands/download.go rename to syft/pkg/cataloger/binary/internal/manager/internal/cli/commands/download.go index 5240fc6d9..7af382357 100644 --- a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/cli/commands/download.go +++ b/syft/pkg/cataloger/binary/internal/manager/internal/cli/commands/download.go @@ -5,8 +5,8 @@ import ( "github.com/spf13/cobra" - "github.com/anchore/syft/syft/pkg/cataloger/binary/test-fixtures/manager/internal" - "github.com/anchore/syft/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config" + "github.com/anchore/syft/syft/pkg/cataloger/binary/internal/manager/internal" + "github.com/anchore/syft/syft/pkg/cataloger/binary/internal/manager/internal/config" ) func Download(appConfig config.Application) *cobra.Command { diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/cli/commands/list.go b/syft/pkg/cataloger/binary/internal/manager/internal/cli/commands/list.go similarity index 94% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/cli/commands/list.go rename to syft/pkg/cataloger/binary/internal/manager/internal/cli/commands/list.go index 223739d16..389e9d0b8 100644 --- a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/cli/commands/list.go +++ b/syft/pkg/cataloger/binary/internal/manager/internal/cli/commands/list.go @@ -8,8 +8,8 @@ import ( "github.com/jedib0t/go-pretty/v6/table" "github.com/spf13/cobra" - "github.com/anchore/syft/syft/pkg/cataloger/binary/test-fixtures/manager/internal" - "github.com/anchore/syft/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config" + "github.com/anchore/syft/syft/pkg/cataloger/binary/internal/manager/internal" + "github.com/anchore/syft/syft/pkg/cataloger/binary/internal/manager/internal/config" ) func List(appConfig config.Application) *cobra.Command { diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/cli/commands/root.go b/syft/pkg/cataloger/binary/internal/manager/internal/cli/commands/root.go similarity index 70% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/cli/commands/root.go rename to syft/pkg/cataloger/binary/internal/manager/internal/cli/commands/root.go index 4c4aa9148..4587db718 100644 --- a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/cli/commands/root.go +++ b/syft/pkg/cataloger/binary/internal/manager/internal/cli/commands/root.go @@ -3,7 +3,7 @@ package commands import ( "github.com/spf13/cobra" - "github.com/anchore/syft/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config" + "github.com/anchore/syft/syft/pkg/cataloger/binary/internal/manager/internal/config" ) func Root(_ config.Application) *cobra.Command { diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/cli/commands/write_snippet.go b/syft/pkg/cataloger/binary/internal/manager/internal/cli/commands/write_snippet.go similarity index 97% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/cli/commands/write_snippet.go rename to syft/pkg/cataloger/binary/internal/manager/internal/cli/commands/write_snippet.go index a00ddec60..115805887 100644 --- a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/cli/commands/write_snippet.go +++ b/syft/pkg/cataloger/binary/internal/manager/internal/cli/commands/write_snippet.go @@ -13,8 +13,8 @@ import ( "github.com/spf13/cobra" "go.yaml.in/yaml/v3" - "github.com/anchore/syft/syft/pkg/cataloger/binary/test-fixtures/manager/internal" - "github.com/anchore/syft/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config" + "github.com/anchore/syft/syft/pkg/cataloger/binary/internal/manager/internal" + "github.com/anchore/syft/syft/pkg/cataloger/binary/internal/manager/internal/config" ) func WriteSnippet(appConfig config.Application) *cobra.Command { diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/application.go b/syft/pkg/cataloger/binary/internal/manager/internal/config/application.go similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/application.go rename to syft/pkg/cataloger/binary/internal/manager/internal/config/application.go diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/application_test.go b/syft/pkg/cataloger/binary/internal/manager/internal/config/application_test.go similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/application_test.go rename to syft/pkg/cataloger/binary/internal/manager/internal/config/application_test.go diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/binary_from_image.go b/syft/pkg/cataloger/binary/internal/manager/internal/config/binary_from_image.go similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/binary_from_image.go rename to syft/pkg/cataloger/binary/internal/manager/internal/config/binary_from_image.go diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/binary_from_image_test.go b/syft/pkg/cataloger/binary/internal/manager/internal/config/binary_from_image_test.go similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/binary_from_image_test.go rename to syft/pkg/cataloger/binary/internal/manager/internal/config/binary_from_image_test.go diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/testdata/app-configs/bad-image-collision.yaml b/syft/pkg/cataloger/binary/internal/manager/internal/config/testdata/app-configs/bad-image-collision.yaml similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/testdata/app-configs/bad-image-collision.yaml rename to syft/pkg/cataloger/binary/internal/manager/internal/config/testdata/app-configs/bad-image-collision.yaml diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/testdata/app-configs/bad-implicit-name-collision.yaml b/syft/pkg/cataloger/binary/internal/manager/internal/config/testdata/app-configs/bad-implicit-name-collision.yaml similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/testdata/app-configs/bad-implicit-name-collision.yaml rename to syft/pkg/cataloger/binary/internal/manager/internal/config/testdata/app-configs/bad-implicit-name-collision.yaml diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/testdata/app-configs/bad-missing-image-platform.yaml b/syft/pkg/cataloger/binary/internal/manager/internal/config/testdata/app-configs/bad-missing-image-platform.yaml similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/testdata/app-configs/bad-missing-image-platform.yaml rename to syft/pkg/cataloger/binary/internal/manager/internal/config/testdata/app-configs/bad-missing-image-platform.yaml diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/testdata/app-configs/bad-missing-image-ref.yaml b/syft/pkg/cataloger/binary/internal/manager/internal/config/testdata/app-configs/bad-missing-image-ref.yaml similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/testdata/app-configs/bad-missing-image-ref.yaml rename to syft/pkg/cataloger/binary/internal/manager/internal/config/testdata/app-configs/bad-missing-image-ref.yaml diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/testdata/app-configs/bad-missing-image.yaml b/syft/pkg/cataloger/binary/internal/manager/internal/config/testdata/app-configs/bad-missing-image.yaml similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/testdata/app-configs/bad-missing-image.yaml rename to syft/pkg/cataloger/binary/internal/manager/internal/config/testdata/app-configs/bad-missing-image.yaml diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/testdata/app-configs/bad-missing-paths.yaml b/syft/pkg/cataloger/binary/internal/manager/internal/config/testdata/app-configs/bad-missing-paths.yaml similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/testdata/app-configs/bad-missing-paths.yaml rename to syft/pkg/cataloger/binary/internal/manager/internal/config/testdata/app-configs/bad-missing-paths.yaml diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/testdata/app-configs/bad-missing-version.yaml b/syft/pkg/cataloger/binary/internal/manager/internal/config/testdata/app-configs/bad-missing-version.yaml similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/testdata/app-configs/bad-missing-version.yaml rename to syft/pkg/cataloger/binary/internal/manager/internal/config/testdata/app-configs/bad-missing-version.yaml diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/testdata/app-configs/bad-no-name.yaml b/syft/pkg/cataloger/binary/internal/manager/internal/config/testdata/app-configs/bad-no-name.yaml similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/testdata/app-configs/bad-no-name.yaml rename to syft/pkg/cataloger/binary/internal/manager/internal/config/testdata/app-configs/bad-no-name.yaml diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/testdata/app-configs/valid-1.yaml b/syft/pkg/cataloger/binary/internal/manager/internal/config/testdata/app-configs/valid-1.yaml similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/testdata/app-configs/valid-1.yaml rename to syft/pkg/cataloger/binary/internal/manager/internal/config/testdata/app-configs/valid-1.yaml diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/testdata/app-configs/valid-2.yaml b/syft/pkg/cataloger/binary/internal/manager/internal/config/testdata/app-configs/valid-2.yaml similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/config/testdata/app-configs/valid-2.yaml rename to syft/pkg/cataloger/binary/internal/manager/internal/config/testdata/app-configs/valid-2.yaml diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/download_from_image.go b/syft/pkg/cataloger/binary/internal/manager/internal/download_from_image.go similarity index 97% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/download_from_image.go rename to syft/pkg/cataloger/binary/internal/manager/internal/download_from_image.go index 1d5a667ea..7eb502e90 100644 --- a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/download_from_image.go +++ b/syft/pkg/cataloger/binary/internal/manager/internal/download_from_image.go @@ -11,8 +11,8 @@ import ( "github.com/google/uuid" - "github.com/anchore/syft/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config" - "github.com/anchore/syft/syft/pkg/cataloger/binary/test-fixtures/manager/internal/ui" + "github.com/anchore/syft/syft/pkg/cataloger/binary/internal/manager/internal/config" + "github.com/anchore/syft/syft/pkg/cataloger/binary/internal/manager/internal/ui" ) const digestFileSuffix = ".xxh64" diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/download_from_image_test.go b/syft/pkg/cataloger/binary/internal/manager/internal/download_from_image_test.go similarity index 92% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/download_from_image_test.go rename to syft/pkg/cataloger/binary/internal/manager/internal/download_from_image_test.go index fc097a7db..d873d9870 100644 --- a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/download_from_image_test.go +++ b/syft/pkg/cataloger/binary/internal/manager/internal/download_from_image_test.go @@ -8,7 +8,7 @@ import ( "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" - "github.com/anchore/syft/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config" + "github.com/anchore/syft/syft/pkg/cataloger/binary/internal/manager/internal/config" ) func TestIsDownloadStale(t *testing.T) { diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/list_entries.go b/syft/pkg/cataloger/binary/internal/manager/internal/list_entries.go similarity index 98% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/list_entries.go rename to syft/pkg/cataloger/binary/internal/manager/internal/list_entries.go index 60f036e51..de35b3731 100644 --- a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/list_entries.go +++ b/syft/pkg/cataloger/binary/internal/manager/internal/list_entries.go @@ -11,7 +11,7 @@ import ( "golang.org/x/exp/maps" - "github.com/anchore/syft/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config" + "github.com/anchore/syft/syft/pkg/cataloger/binary/internal/manager/internal/config" ) type Entries map[LogicalEntryKey]EntryInfo diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/list_entries_test.go b/syft/pkg/cataloger/binary/internal/manager/internal/list_entries_test.go similarity index 97% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/list_entries_test.go rename to syft/pkg/cataloger/binary/internal/manager/internal/list_entries_test.go index 11ca8e3e5..82d430346 100644 --- a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/list_entries_test.go +++ b/syft/pkg/cataloger/binary/internal/manager/internal/list_entries_test.go @@ -8,7 +8,7 @@ import ( "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" - "github.com/anchore/syft/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config" + "github.com/anchore/syft/syft/pkg/cataloger/binary/internal/manager/internal/config" ) func TestSortingLogicalEntryKeys(t *testing.T) { diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/snippet_metadata.go b/syft/pkg/cataloger/binary/internal/manager/internal/snippet_metadata.go similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/snippet_metadata.go rename to syft/pkg/cataloger/binary/internal/manager/internal/snippet_metadata.go diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/snippet_metadata_test.go b/syft/pkg/cataloger/binary/internal/manager/internal/snippet_metadata_test.go similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/snippet_metadata_test.go rename to syft/pkg/cataloger/binary/internal/manager/internal/snippet_metadata_test.go diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/testdata/.gitignore b/syft/pkg/cataloger/binary/internal/manager/internal/testdata/.gitignore similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/testdata/.gitignore rename to syft/pkg/cataloger/binary/internal/manager/internal/testdata/.gitignore diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/testdata/bin/busybox/1.3.6/linux-amd64/busybox b/syft/pkg/cataloger/binary/internal/manager/internal/testdata/bin/busybox/1.3.6/linux-amd64/busybox similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/testdata/bin/busybox/1.3.6/linux-amd64/busybox rename to syft/pkg/cataloger/binary/internal/manager/internal/testdata/bin/busybox/1.3.6/linux-amd64/busybox diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/testdata/bin/busybox/1.3.6/linux-arm64/busybox b/syft/pkg/cataloger/binary/internal/manager/internal/testdata/bin/busybox/1.3.6/linux-arm64/busybox similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/testdata/bin/busybox/1.3.6/linux-arm64/busybox rename to syft/pkg/cataloger/binary/internal/manager/internal/testdata/bin/busybox/1.3.6/linux-arm64/busybox diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/testdata/snippets/busybox/1.3.6/linux-amd64/busybox b/syft/pkg/cataloger/binary/internal/manager/internal/testdata/snippets/busybox/1.3.6/linux-amd64/busybox similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/testdata/snippets/busybox/1.3.6/linux-amd64/busybox rename to syft/pkg/cataloger/binary/internal/manager/internal/testdata/snippets/busybox/1.3.6/linux-amd64/busybox diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/testdata/snippets/busybox/1.3.6/linux-arm64/busybox b/syft/pkg/cataloger/binary/internal/manager/internal/testdata/snippets/busybox/1.3.6/linux-arm64/busybox similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/testdata/snippets/busybox/1.3.6/linux-arm64/busybox rename to syft/pkg/cataloger/binary/internal/manager/internal/testdata/snippets/busybox/1.3.6/linux-arm64/busybox diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/testdata/snippets/postgres/9.6.10/linux-amd64/postgres b/syft/pkg/cataloger/binary/internal/manager/internal/testdata/snippets/postgres/9.6.10/linux-amd64/postgres similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/testdata/snippets/postgres/9.6.10/linux-amd64/postgres rename to syft/pkg/cataloger/binary/internal/manager/internal/testdata/snippets/postgres/9.6.10/linux-amd64/postgres diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/ui/action.go b/syft/pkg/cataloger/binary/internal/manager/internal/ui/action.go similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/ui/action.go rename to syft/pkg/cataloger/binary/internal/manager/internal/ui/action.go diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/ui/ansi.go b/syft/pkg/cataloger/binary/internal/manager/internal/ui/ansi.go similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/ui/ansi.go rename to syft/pkg/cataloger/binary/internal/manager/internal/ui/ansi.go diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/ui/binary_list.go b/syft/pkg/cataloger/binary/internal/manager/internal/ui/binary_list.go similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/ui/binary_list.go rename to syft/pkg/cataloger/binary/internal/manager/internal/ui/binary_list.go diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/ui/error.go b/syft/pkg/cataloger/binary/internal/manager/internal/ui/error.go similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/ui/error.go rename to syft/pkg/cataloger/binary/internal/manager/internal/ui/error.go diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/ui/title.go b/syft/pkg/cataloger/binary/internal/manager/internal/ui/title.go similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/ui/title.go rename to syft/pkg/cataloger/binary/internal/manager/internal/ui/title.go diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/utils.go b/syft/pkg/cataloger/binary/internal/manager/internal/utils.go similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/utils.go rename to syft/pkg/cataloger/binary/internal/manager/internal/utils.go diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/internal/utils_test.go b/syft/pkg/cataloger/binary/internal/manager/internal/utils_test.go similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/internal/utils_test.go rename to syft/pkg/cataloger/binary/internal/manager/internal/utils_test.go diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/main.go b/syft/pkg/cataloger/binary/internal/manager/main.go similarity index 61% rename from syft/pkg/cataloger/binary/test-fixtures/manager/main.go rename to syft/pkg/cataloger/binary/internal/manager/main.go index 14b23f0da..0c197bc7e 100644 --- a/syft/pkg/cataloger/binary/test-fixtures/manager/main.go +++ b/syft/pkg/cataloger/binary/internal/manager/main.go @@ -4,8 +4,8 @@ import ( "fmt" "os" - "github.com/anchore/syft/syft/pkg/cataloger/binary/test-fixtures/manager/internal/cli" - "github.com/anchore/syft/syft/pkg/cataloger/binary/test-fixtures/manager/internal/ui" + "github.com/anchore/syft/syft/pkg/cataloger/binary/internal/manager/internal/cli" + "github.com/anchore/syft/syft/pkg/cataloger/binary/internal/manager/internal/ui" ) func main() { diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/testutil/snippet_or_binary.go b/syft/pkg/cataloger/binary/internal/manager/testutil/snippet_or_binary.go similarity index 85% rename from syft/pkg/cataloger/binary/test-fixtures/manager/testutil/snippet_or_binary.go rename to syft/pkg/cataloger/binary/internal/manager/testutil/snippet_or_binary.go index b2a18aa4b..9a4ef20fc 100644 --- a/syft/pkg/cataloger/binary/test-fixtures/manager/testutil/snippet_or_binary.go +++ b/syft/pkg/cataloger/binary/internal/manager/testutil/snippet_or_binary.go @@ -8,13 +8,13 @@ import ( "github.com/stretchr/testify/require" - "github.com/anchore/syft/syft/pkg/cataloger/binary/test-fixtures/manager/internal" - "github.com/anchore/syft/syft/pkg/cataloger/binary/test-fixtures/manager/internal/config" + "github.com/anchore/syft/syft/pkg/cataloger/binary/internal/manager/internal" + "github.com/anchore/syft/syft/pkg/cataloger/binary/internal/manager/internal/config" ) // SnippetOrBinary returns the path to either the binary or the snippet for the given logical entry key. // Note: this is intended to be used only within the context of the binary cataloger test fixtures. Any other -// use is unsupported. Path should be a logical path relative to the test-fixtures/classifiers directory (but does +// use is unsupported. Path should be a logical path relative to the testdata/classifiers directory (but does // not specify the "bin" or "snippets" parent path... this is determined logically [snippets > binary unless told // otherwise]). Path should also be to the directory containing the binary or snippets of interest (not the binaries // or snippets itself). @@ -23,12 +23,12 @@ func SnippetOrBinary(t *testing.T, path string, requireBinary bool) string { require.Len(t, internal.SplitFilepath(path), 3, "path must be a in the form //") - // cd to test-fixtures directory and load the config + // cd to testdata directory and load the config cwd, err := os.Getwd() require.NoError(t, err) - require.NoError(t, os.Chdir("test-fixtures")) + require.NoError(t, os.Chdir("testdata")) defer func() { require.NoError(t, os.Chdir(cwd)) }() @@ -65,7 +65,7 @@ func SnippetOrBinary(t *testing.T, path string, requireBinary bool) string { } if v.SnippetPath != "" && !v.IsConfigured { - t.Skip("no binary found, but is covered by a snippet. Please add this case to the 'binary/test-fixtures/config.yaml' and recreate the snippet") + t.Skip("no binary found, but is covered by a snippet. Please add this case to the 'binary/testdata/config.yaml' and recreate the snippet") } t.Fatalf("no binary found for %q", path) @@ -78,7 +78,7 @@ func SnippetOrBinary(t *testing.T, path string, requireBinary bool) string { // this should be relative to the tests-fixtures directory and should be the directory containing the binary or // snippet of interest (not the path to the binary or snippet itself) - return filepath.Join("test-fixtures", filepath.Dir(fixturePath)) + return filepath.Join("testdata", filepath.Dir(fixturePath)) } func validateSnippet(binaryPath, snippetPath string) error { diff --git a/syft/pkg/cataloger/binary/test-fixtures/manager/testutil/snippet_or_binary_test.go b/syft/pkg/cataloger/binary/internal/manager/testutil/snippet_or_binary_test.go similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/manager/testutil/snippet_or_binary_test.go rename to syft/pkg/cataloger/binary/internal/manager/testutil/snippet_or_binary_test.go diff --git a/syft/pkg/cataloger/binary/test-fixtures/.gitignore b/syft/pkg/cataloger/binary/testdata/.gitignore similarity index 56% rename from syft/pkg/cataloger/binary/test-fixtures/.gitignore rename to syft/pkg/cataloger/binary/testdata/.gitignore index 4d4d11ec9..388e71046 100644 --- a/syft/pkg/cataloger/binary/test-fixtures/.gitignore +++ b/syft/pkg/cataloger/binary/testdata/.gitignore @@ -5,5 +5,7 @@ classifiers/bin !lib*.so !lib*.dylib -# allow for go-hint file -!VERSION* \ No newline at end of file +# allow for go-hint files and binaries +!VERSION* +!classifiers/snippets/**/bin/ +!*.exe \ No newline at end of file diff --git a/syft/pkg/cataloger/binary/test-fixtures/Makefile b/syft/pkg/cataloger/binary/testdata/Makefile similarity index 84% rename from syft/pkg/cataloger/binary/test-fixtures/Makefile rename to syft/pkg/cataloger/binary/testdata/Makefile index 3920d2397..65e72e99b 100644 --- a/syft/pkg/cataloger/binary/test-fixtures/Makefile +++ b/syft/pkg/cataloger/binary/testdata/Makefile @@ -11,16 +11,16 @@ fixtures: download fingerprint: clean-fingerprint $(FINGERPRINT_FILE) list: ## list all managed binaries and snippets - go run ./manager list + go run ../internal/manager list download: ## download only binaries that are not covered by a snippet - go run ./manager download $(name) --skip-if-covered-by-snippet + go run ../internal/manager download $(name) --skip-if-covered-by-snippet download-all: ## download all managed binaries - go run ./manager download + go run ../internal/manager download add-snippet: ## add a new snippet from an existing binary - go run ./manager add-snippet + go run ../internal/manager add-snippet # requirement 3: we always need to recalculate the fingerprint based on source regardless of any existing fingerprint .PHONY: $(FINGERPRINT_FILE) @@ -32,7 +32,7 @@ clean: ## clean up all downloaded binaries rm -rf $(BIN) clean-fingerprint: ## clean up all legacy fingerprint files - @find $(BIN) -name '*.fingerprint' -delete + @if [ -d $(BIN) ]; then find $(BIN) -name '*.fingerprint' -delete; fi ## Halp! ################################# diff --git a/syft/pkg/cataloger/binary/test-fixtures/capture-snippet.sh b/syft/pkg/cataloger/binary/testdata/capture-snippet.sh similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/capture-snippet.sh rename to syft/pkg/cataloger/binary/testdata/capture-snippet.sh diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/negative/.gitignore b/syft/pkg/cataloger/binary/testdata/classifiers/negative/.gitignore similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/negative/.gitignore rename to syft/pkg/cataloger/binary/testdata/classifiers/negative/.gitignore diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/negative/busybox b/syft/pkg/cataloger/binary/testdata/classifiers/negative/busybox similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/negative/busybox rename to syft/pkg/cataloger/binary/testdata/classifiers/negative/busybox diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/negative/go b/syft/pkg/cataloger/binary/testdata/classifiers/negative/go similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/negative/go rename to syft/pkg/cataloger/binary/testdata/classifiers/negative/go diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/negative/libpython2.7.so b/syft/pkg/cataloger/binary/testdata/classifiers/negative/libpython2.7.so similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/negative/libpython2.7.so rename to syft/pkg/cataloger/binary/testdata/classifiers/negative/libpython2.7.so diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/negative/python2.6 b/syft/pkg/cataloger/binary/testdata/classifiers/negative/python2.6 similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/negative/python2.6 rename to syft/pkg/cataloger/binary/testdata/classifiers/negative/python2.6 diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/negative/traefik/traefik b/syft/pkg/cataloger/binary/testdata/classifiers/negative/traefik/traefik similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/negative/traefik/traefik rename to syft/pkg/cataloger/binary/testdata/classifiers/negative/traefik/traefik diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/arangodb/3.11.8/linux-amd64/arangosh b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/arangodb/3.11.8/linux-amd64/arangosh similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/arangodb/3.11.8/linux-amd64/arangosh rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/arangodb/3.11.8/linux-amd64/arangosh diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/arangodb/3.12.0-2/linux-amd64/arangosh b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/arangodb/3.12.0-2/linux-amd64/arangosh similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/arangodb/3.12.0-2/linux-amd64/arangosh rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/arangodb/3.12.0-2/linux-amd64/arangosh diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/bash/5.1.16/linux-amd64/bash b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/bash/5.1.16/linux-amd64/bash similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/bash/5.1.16/linux-amd64/bash rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/bash/5.1.16/linux-amd64/bash diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/busybox/1.36.1/linux-amd64/[ b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/busybox/1.36.1/linux-amd64/[ similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/busybox/1.36.1/linux-amd64/[ rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/busybox/1.36.1/linux-amd64/[ diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/busybox/1.36.1/linux-amd64/busybox b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/busybox/1.36.1/linux-amd64/busybox similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/busybox/1.36.1/linux-amd64/busybox rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/busybox/1.36.1/linux-amd64/busybox diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/chrome/126.0.6478.182/linux-amd64/chrome b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/chrome/126.0.6478.182/linux-amd64/chrome similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/chrome/126.0.6478.182/linux-amd64/chrome rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/chrome/126.0.6478.182/linux-amd64/chrome diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/chrome/127.0.6533.119/linux-amd64/chrome b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/chrome/127.0.6533.119/linux-amd64/chrome similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/chrome/127.0.6533.119/linux-amd64/chrome rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/chrome/127.0.6533.119/linux-amd64/chrome diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/consul/1.15.2/linux-amd64/consul b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/consul/1.15.2/linux-amd64/consul similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/consul/1.15.2/linux-amd64/consul rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/consul/1.15.2/linux-amd64/consul diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/dart/2.12.4/linux-amd64/dart b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/dart/2.12.4/linux-amd64/dart similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/dart/2.12.4/linux-amd64/dart rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/dart/2.12.4/linux-amd64/dart diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/dart/3.0.0/linux-arm/dart b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/dart/3.0.0/linux-arm/dart similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/dart/3.0.0/linux-arm/dart rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/dart/3.0.0/linux-arm/dart diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/dart/3.5.2/linux-amd64/dart b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/dart/3.5.2/linux-amd64/dart similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/dart/3.5.2/linux-amd64/dart rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/dart/3.5.2/linux-amd64/dart diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/dart/3.6.0-216.1.beta/linux-amd64/dart b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/dart/3.6.0-216.1.beta/linux-amd64/dart similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/dart/3.6.0-216.1.beta/linux-amd64/dart rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/dart/3.6.0-216.1.beta/linux-amd64/dart diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/elixir/1.19.1/linux-amd64/elixir b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/elixir/1.19.1/linux-amd64/elixir similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/elixir/1.19.1/linux-amd64/elixir rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/elixir/1.19.1/linux-amd64/elixir diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/elixir/1.19.1/linux-amd64/lib/elixir/ebin/elixir.app b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/elixir/1.19.1/linux-amd64/lib/elixir/ebin/elixir.app similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/elixir/1.19.1/linux-amd64/lib/elixir/ebin/elixir.app rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/elixir/1.19.1/linux-amd64/lib/elixir/ebin/elixir.app diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/envoy/1.11.0/linux-amd64/envoy b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/envoy/1.11.0/linux-amd64/envoy similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/envoy/1.11.0/linux-amd64/envoy rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/envoy/1.11.0/linux-amd64/envoy diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/envoy/1.14.3/linux-amd64/envoy b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/envoy/1.14.3/linux-amd64/envoy similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/envoy/1.14.3/linux-amd64/envoy rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/envoy/1.14.3/linux-amd64/envoy diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/envoy/1.18.6/linux-amd64/envoy b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/envoy/1.18.6/linux-amd64/envoy similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/envoy/1.18.6/linux-amd64/envoy rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/envoy/1.18.6/linux-amd64/envoy diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/envoy/1.20.7/linux-amd64/envoy b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/envoy/1.20.7/linux-amd64/envoy similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/envoy/1.20.7/linux-amd64/envoy rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/envoy/1.20.7/linux-amd64/envoy diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/envoy/1.22.11/linux-amd64/envoy b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/envoy/1.22.11/linux-amd64/envoy similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/envoy/1.22.11/linux-amd64/envoy rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/envoy/1.22.11/linux-amd64/envoy diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/envoy/1.28.7/linux-amd64/envoy b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/envoy/1.28.7/linux-amd64/envoy similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/envoy/1.28.7/linux-amd64/envoy rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/envoy/1.28.7/linux-amd64/envoy diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/envoy/1.34.5/linux-amd64/envoy b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/envoy/1.34.5/linux-amd64/envoy similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/envoy/1.34.5/linux-amd64/envoy rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/envoy/1.34.5/linux-amd64/envoy diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/envoy/1.36.4/linux-amd64/envoy b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/envoy/1.36.4/linux-amd64/envoy similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/envoy/1.36.4/linux-amd64/envoy rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/envoy/1.36.4/linux-amd64/envoy diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/envoy/1.6.0/linux-amd64/envoy b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/envoy/1.6.0/linux-amd64/envoy similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/envoy/1.6.0/linux-amd64/envoy rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/envoy/1.6.0/linux-amd64/envoy diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/erlang/25.3.2.6/linux-amd64/erlexec b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/erlang/25.3.2.6/linux-amd64/erlexec similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/erlang/25.3.2.6/linux-amd64/erlexec rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/erlang/25.3.2.6/linux-amd64/erlexec diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/erlang/26.1.2/linux-arm64/beam.smp b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/erlang/26.1.2/linux-arm64/beam.smp similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/erlang/26.1.2/linux-arm64/beam.smp rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/erlang/26.1.2/linux-arm64/beam.smp diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/erlang/26.2.0.0/linux-amd64/erlexec b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/erlang/26.2.0.0/linux-amd64/erlexec similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/erlang/26.2.0.0/linux-amd64/erlexec rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/erlang/26.2.0.0/linux-amd64/erlexec diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/erlang/26.2.4/linux-amd64/liberts_internal.a b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/erlang/26.2.4/linux-amd64/liberts_internal.a similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/erlang/26.2.4/linux-amd64/liberts_internal.a rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/erlang/26.2.4/linux-amd64/liberts_internal.a diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/erlang/27.0/linux-amd64/beam.smp b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/erlang/27.0/linux-amd64/beam.smp similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/erlang/27.0/linux-amd64/beam.smp rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/erlang/27.0/linux-amd64/beam.smp diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/ffmpeg-shared-libs/5.1.4/linux-amd64/libavcodec-9aae324f.so.59.37.100 b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/ffmpeg-shared-libs/5.1.4/linux-amd64/libavcodec-9aae324f.so.59.37.100 similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/ffmpeg-shared-libs/5.1.4/linux-amd64/libavcodec-9aae324f.so.59.37.100 rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/ffmpeg-shared-libs/5.1.4/linux-amd64/libavcodec-9aae324f.so.59.37.100 diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/ffmpeg/6.1.1/linux-amd64/ffmpeg b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/ffmpeg/6.1.1/linux-amd64/ffmpeg similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/ffmpeg/6.1.1/linux-amd64/ffmpeg rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/ffmpeg/6.1.1/linux-amd64/ffmpeg diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/ffmpeg/7.1.1/darwin-arm64/ffmpeg b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/ffmpeg/7.1.1/darwin-arm64/ffmpeg similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/ffmpeg/7.1.1/darwin-arm64/ffmpeg rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/ffmpeg/7.1.1/darwin-arm64/ffmpeg diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/fluent-bit/1.3.10/linux-arm/fluent-bit b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/fluent-bit/1.3.10/linux-arm/fluent-bit similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/fluent-bit/1.3.10/linux-arm/fluent-bit rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/fluent-bit/1.3.10/linux-arm/fluent-bit diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/fluent-bit/1.7.0-dev-3/linux-amd64/fluent-bit b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/fluent-bit/1.7.0-dev-3/linux-amd64/fluent-bit similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/fluent-bit/1.7.0-dev-3/linux-amd64/fluent-bit rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/fluent-bit/1.7.0-dev-3/linux-amd64/fluent-bit diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/fluent-bit/2.2.1/linux-arm64/fluent-bit b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/fluent-bit/2.2.1/linux-arm64/fluent-bit similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/fluent-bit/2.2.1/linux-arm64/fluent-bit rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/fluent-bit/2.2.1/linux-arm64/fluent-bit diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/fluent-bit/3.0.2/linux-amd64/fluent-bit b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/fluent-bit/3.0.2/linux-amd64/fluent-bit similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/fluent-bit/3.0.2/linux-amd64/fluent-bit rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/fluent-bit/3.0.2/linux-amd64/fluent-bit diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/gcc/12.3.0/linux-amd64/gcc b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/gcc/12.3.0/linux-amd64/gcc similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/gcc/12.3.0/linux-amd64/gcc rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/gcc/12.3.0/linux-amd64/gcc diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/go-version-hint/1.15/any/VERSION b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/go-version-hint/1.15/any/VERSION similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/go-version-hint/1.15/any/VERSION rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/go-version-hint/1.15/any/VERSION diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/go-version-hint/1.15/any/bin/go b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/go-version-hint/1.15/any/bin/go similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/go-version-hint/1.15/any/bin/go rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/go-version-hint/1.15/any/bin/go diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/go-version-hint/1.15w/any/VERSION b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/go-version-hint/1.15w/any/VERSION similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/go-version-hint/1.15w/any/VERSION rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/go-version-hint/1.15w/any/VERSION diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/go-version-hint/1.15w/any/bin/go.exe b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/go-version-hint/1.15w/any/bin/go.exe similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/go-version-hint/1.15w/any/bin/go.exe rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/go-version-hint/1.15w/any/bin/go.exe diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/go-version-hint/1.21/any/VERSION b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/go-version-hint/1.21/any/VERSION similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/go-version-hint/1.21/any/VERSION rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/go-version-hint/1.21/any/VERSION diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/go-version-hint/1.21/any/go b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/go-version-hint/1.21/any/go similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/go-version-hint/1.21/any/go rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/go-version-hint/1.21/any/go diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/go-version-hint/1.25/any/VERSION.cache b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/go-version-hint/1.25/any/VERSION.cache similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/go-version-hint/1.25/any/VERSION.cache rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/go-version-hint/1.25/any/VERSION.cache diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/go-version-hint/1.25/any/bin/go b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/go-version-hint/1.25/any/bin/go similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/go-version-hint/1.25/any/bin/go rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/go-version-hint/1.25/any/bin/go diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/go-version-hint/1.25w/any/VERSION b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/go-version-hint/1.25w/any/VERSION similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/go-version-hint/1.25w/any/VERSION rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/go-version-hint/1.25w/any/VERSION diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/go-version-hint/1.25w/any/go.exe b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/go-version-hint/1.25w/any/go.exe similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/go-version-hint/1.25w/any/go.exe rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/go-version-hint/1.25w/any/go.exe diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/go/1.21.3/linux-amd64/go b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/go/1.21.3/linux-amd64/go similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/go/1.21.3/linux-amd64/go rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/go/1.21.3/linux-amd64/go diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/10.3.12/linux-amd64/grafana b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/10.3.12/linux-amd64/grafana similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/10.3.12/linux-amd64/grafana rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/10.3.12/linux-amd64/grafana diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/10.4.19/linux-amd64/grafana b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/10.4.19/linux-amd64/grafana similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/10.4.19/linux-amd64/grafana rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/10.4.19/linux-amd64/grafana diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/11.0.0-preview/linux-amd64/grafana b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/11.0.0-preview/linux-amd64/grafana similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/11.0.0-preview/linux-amd64/grafana rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/11.0.0-preview/linux-amd64/grafana diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/11.0.0/linux-amd64/grafana b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/11.0.0/linux-amd64/grafana similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/11.0.0/linux-amd64/grafana rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/11.0.0/linux-amd64/grafana diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/12.0.0/linux-amd64/grafana b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/12.0.0/linux-amd64/grafana similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/12.0.0/linux-amd64/grafana rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/12.0.0/linux-amd64/grafana diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/12.2.0-258092/linux-amd64/grafana b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/12.2.0-258092/linux-amd64/grafana similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/12.2.0-258092/linux-amd64/grafana rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/12.2.0-258092/linux-amd64/grafana diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/12.3.1/linux-amd64/grafana b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/12.3.1/linux-amd64/grafana similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/12.3.1/linux-amd64/grafana rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/12.3.1/linux-amd64/grafana diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/12.3.2-security-01/linux-amd64/grafana b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/12.3.2-security-01/linux-amd64/grafana similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/12.3.2-security-01/linux-amd64/grafana rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/12.3.2-security-01/linux-amd64/grafana diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/12.4.0-22081664032/linux-amd64/grafana b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/12.4.0-22081664032/linux-amd64/grafana similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/12.4.0-22081664032/linux-amd64/grafana rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/12.4.0-22081664032/linux-amd64/grafana diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/6.0.0-beta1/linux-amd64/grafana-server b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/6.0.0-beta1/linux-amd64/grafana-server similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/6.0.0-beta1/linux-amd64/grafana-server rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/6.0.0-beta1/linux-amd64/grafana-server diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/6.7.0-test/linux-amd64/grafana-server b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/6.7.0-test/linux-amd64/grafana-server similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/6.7.0-test/linux-amd64/grafana-server rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/6.7.0-test/linux-amd64/grafana-server diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/6.7.6/linux-amd64/grafana-server b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/6.7.6/linux-amd64/grafana-server similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/6.7.6/linux-amd64/grafana-server rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/6.7.6/linux-amd64/grafana-server diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/7.5.17/linux-amd64/grafana-server b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/7.5.17/linux-amd64/grafana-server similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/7.5.17/linux-amd64/grafana-server rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/7.5.17/linux-amd64/grafana-server diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/9.0.0/linux-amd64/grafana-server b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/9.0.0/linux-amd64/grafana-server similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/9.0.0/linux-amd64/grafana-server rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/9.0.0/linux-amd64/grafana-server diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/9.2.13/linux-amd64/grafana b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/9.2.13/linux-amd64/grafana similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/9.2.13/linux-amd64/grafana rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/9.2.13/linux-amd64/grafana diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/9.2.20/linux-amd64/grafana b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/9.2.20/linux-amd64/grafana similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/9.2.20/linux-amd64/grafana rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/9.2.20/linux-amd64/grafana diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/9.3.0-beta1/linux-amd64/grafana-server b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/9.3.0-beta1/linux-amd64/grafana-server similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/9.3.0-beta1/linux-amd64/grafana-server rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/9.3.0-beta1/linux-amd64/grafana-server diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/9.4.0-beta1/linux-amd64/grafana b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/9.4.0-beta1/linux-amd64/grafana similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/9.4.0-beta1/linux-amd64/grafana rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/9.4.0-beta1/linux-amd64/grafana diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/9.5.21/linux-amd64/grafana b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/9.5.21/linux-amd64/grafana similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/grafana/9.5.21/linux-amd64/grafana rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/grafana/9.5.21/linux-amd64/grafana diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/gzip/1.12/linux-amd64/gzip b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/gzip/1.12/linux-amd64/gzip similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/gzip/1.12/linux-amd64/gzip rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/gzip/1.12/linux-amd64/gzip diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/haproxy/1.5.14/linux-amd64/haproxy b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/haproxy/1.5.14/linux-amd64/haproxy similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/haproxy/1.5.14/linux-amd64/haproxy rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/haproxy/1.5.14/linux-amd64/haproxy diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/haproxy/1.8.22/linux-amd64/haproxy b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/haproxy/1.8.22/linux-amd64/haproxy similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/haproxy/1.8.22/linux-amd64/haproxy rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/haproxy/1.8.22/linux-amd64/haproxy diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/haproxy/2.0.0/linux-amd64/haproxy b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/haproxy/2.0.0/linux-amd64/haproxy similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/haproxy/2.0.0/linux-amd64/haproxy rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/haproxy/2.0.0/linux-amd64/haproxy diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/haproxy/2.7.3/linux-amd64/haproxy b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/haproxy/2.7.3/linux-amd64/haproxy similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/haproxy/2.7.3/linux-amd64/haproxy rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/haproxy/2.7.3/linux-amd64/haproxy diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/haproxy/3.1-dev0/linux-amd64/haproxy b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/haproxy/3.1-dev0/linux-amd64/haproxy similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/haproxy/3.1-dev0/linux-amd64/haproxy rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/haproxy/3.1-dev0/linux-amd64/haproxy diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/haskell-cabal/3.10.3.0/linux-amd64/cabal b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/haskell-cabal/3.10.3.0/linux-amd64/cabal similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/haskell-cabal/3.10.3.0/linux-amd64/cabal rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/haskell-cabal/3.10.3.0/linux-amd64/cabal diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/haskell-ghc/9.6.5/linux-amd64/ghc-9.6.5 b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/haskell-ghc/9.6.5/linux-amd64/ghc-9.6.5 similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/haskell-ghc/9.6.5/linux-amd64/ghc-9.6.5 rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/haskell-ghc/9.6.5/linux-amd64/ghc-9.6.5 diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/helm/3.10.3/linux-amd64/helm b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/helm/3.10.3/linux-amd64/helm similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/helm/3.10.3/linux-amd64/helm rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/helm/3.10.3/linux-amd64/helm diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/helm/3.11.1/linux-amd64/helm b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/helm/3.11.1/linux-amd64/helm similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/helm/3.11.1/linux-amd64/helm rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/helm/3.11.1/linux-amd64/helm diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/httpd/2.4.54/linux-amd64/httpd b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/httpd/2.4.54/linux-amd64/httpd similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/httpd/2.4.54/linux-amd64/httpd rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/httpd/2.4.54/linux-amd64/httpd diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/istio_pilot-agent/1.1.17/linux-amd64/pilot-agent b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/istio_pilot-agent/1.1.17/linux-amd64/pilot-agent similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/istio_pilot-agent/1.1.17/linux-amd64/pilot-agent rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/istio_pilot-agent/1.1.17/linux-amd64/pilot-agent diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/istio_pilot-agent/1.26.8/linux-amd64/pilot-agent b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/istio_pilot-agent/1.26.8/linux-amd64/pilot-agent similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/istio_pilot-agent/1.26.8/linux-amd64/pilot-agent rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/istio_pilot-agent/1.26.8/linux-amd64/pilot-agent diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/istio_pilot-agent/1.8.0/linux-amd64/pilot-agent b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/istio_pilot-agent/1.8.0/linux-amd64/pilot-agent similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/istio_pilot-agent/1.8.0/linux-amd64/pilot-agent rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/istio_pilot-agent/1.8.0/linux-amd64/pilot-agent diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/istio_pilot-discovery/1.1.17/linux-amd64/pilot-discovery b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/istio_pilot-discovery/1.1.17/linux-amd64/pilot-discovery similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/istio_pilot-discovery/1.1.17/linux-amd64/pilot-discovery rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/istio_pilot-discovery/1.1.17/linux-amd64/pilot-discovery diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/istio_pilot-discovery/1.26.8/linux-amd64/pilot-discovery b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/istio_pilot-discovery/1.26.8/linux-amd64/pilot-discovery similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/istio_pilot-discovery/1.26.8/linux-amd64/pilot-discovery rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/istio_pilot-discovery/1.26.8/linux-amd64/pilot-discovery diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/istio_pilot-discovery/1.3.8/linux-amd64/pilot-discovery b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/istio_pilot-discovery/1.3.8/linux-amd64/pilot-discovery similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/istio_pilot-discovery/1.3.8/linux-amd64/pilot-discovery rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/istio_pilot-discovery/1.3.8/linux-amd64/pilot-discovery diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/istio_pilot-discovery/1.8.0/linux-amd64/pilot-discovery b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/istio_pilot-discovery/1.8.0/linux-amd64/pilot-discovery similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/istio_pilot-discovery/1.8.0/linux-amd64/pilot-discovery rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/istio_pilot-discovery/1.8.0/linux-amd64/pilot-discovery diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-graal-openjdk/17.0.3+7-jvmci-22.1-b06/linux-amd64/java b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-graal-openjdk/17.0.3+7-jvmci-22.1-b06/linux-amd64/java similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-graal-openjdk/17.0.3+7-jvmci-22.1-b06/linux-amd64/java rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-graal-openjdk/17.0.3+7-jvmci-22.1-b06/linux-amd64/java diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-jdk-openjdk/21.0.2+13-LTS/linux-amd64/jdb b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-jdk-openjdk/21.0.2+13-LTS/linux-amd64/jdb similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-jdk-openjdk/21.0.2+13-LTS/linux-amd64/jdb rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-jdk-openjdk/21.0.2+13-LTS/linux-amd64/jdb diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-jdk-oracle/1.8.0_451-b10/linux-amd64/java b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-jdk-oracle/1.8.0_451-b10/linux-amd64/java similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-jdk-oracle/1.8.0_451-b10/linux-amd64/java rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-jdk-oracle/1.8.0_451-b10/linux-amd64/java diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-jdk-oracle/1.8.0_451-b10/linux-amd64/jdb b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-jdk-oracle/1.8.0_451-b10/linux-amd64/jdb similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-jdk-oracle/1.8.0_451-b10/linux-amd64/jdb rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-jdk-oracle/1.8.0_451-b10/linux-amd64/jdb diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-jre-openjdk-arm64-eclipse/11.0.22/linux-arm64/java b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-jre-openjdk-arm64-eclipse/11.0.22/linux-arm64/java similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-jre-openjdk-arm64-eclipse/11.0.22/linux-arm64/java rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-jre-openjdk-arm64-eclipse/11.0.22/linux-arm64/java diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-jre-openjdk-eclipse/11.0.22/linux-amd64/java b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-jre-openjdk-eclipse/11.0.22/linux-amd64/java similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-jre-openjdk-eclipse/11.0.22/linux-amd64/java rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-jre-openjdk-eclipse/11.0.22/linux-amd64/java diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-jre-openjdk/1.8.0_352-b08/linux-amd64/java b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-jre-openjdk/1.8.0_352-b08/linux-amd64/java similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-jre-openjdk/1.8.0_352-b08/linux-amd64/java rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-jre-openjdk/1.8.0_352-b08/linux-amd64/java diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-jre-openjdk/11.0.17/linux-amd64/java b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-jre-openjdk/11.0.17/linux-amd64/java similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-jre-openjdk/11.0.17/linux-amd64/java rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-jre-openjdk/11.0.17/linux-amd64/java diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-jre-oracle-sdk/1.8.0_451-b10/linux-amd64/java b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-jre-oracle-sdk/1.8.0_451-b10/linux-amd64/java similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-jre-oracle-sdk/1.8.0_451-b10/linux-amd64/java rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-jre-oracle-sdk/1.8.0_451-b10/linux-amd64/java diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-jre-oracle/1.8.0_451-b10/linux-amd64/java b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-jre-oracle/1.8.0_451-b10/linux-amd64/java similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-jre-oracle/1.8.0_451-b10/linux-amd64/java rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-jre-oracle/1.8.0_451-b10/linux-amd64/java diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-jre-oracle/19.0.1/darwin/java b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-jre-oracle/19.0.1/darwin/java similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-jre-oracle/19.0.1/darwin/java rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-jre-oracle/19.0.1/darwin/java diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-jre-oracle/19.0.1/linux-amd64/java b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-jre-oracle/19.0.1/linux-amd64/java similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/java-jre-oracle/19.0.1/linux-amd64/java rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/java-jre-oracle/19.0.1/linux-amd64/java diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/jq/1.7.1/linux-amd64/jq b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/jq/1.7.1/linux-amd64/jq similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/jq/1.7.1/linux-amd64/jq rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/jq/1.7.1/linux-amd64/jq diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/lighttpd/1.4.76/linux-amd64/lighttpd b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/lighttpd/1.4.76/linux-amd64/lighttpd similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/lighttpd/1.4.76/linux-amd64/lighttpd rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/lighttpd/1.4.76/linux-amd64/lighttpd diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/mariadb/10.6.15/linux-amd64/mariadb b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/mariadb/10.6.15/linux-amd64/mariadb similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/mariadb/10.6.15/linux-amd64/mariadb rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/mariadb/10.6.15/linux-amd64/mariadb diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/memcached/1.6.18/linux-amd64/memcached b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/memcached/1.6.18/linux-amd64/memcached similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/memcached/1.6.18/linux-amd64/memcached rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/memcached/1.6.18/linux-amd64/memcached diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/mongodb/4.4.30/linux-amd64/mongod b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/mongodb/4.4.30/linux-amd64/mongod similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/mongodb/4.4.30/linux-amd64/mongod rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/mongodb/4.4.30/linux-amd64/mongod diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/mongodb/5.0.32/linux-amd64/mongod b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/mongodb/5.0.32/linux-amd64/mongod similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/mongodb/5.0.32/linux-amd64/mongod rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/mongodb/5.0.32/linux-amd64/mongod diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/mongodb/6.0.27/linux-amd64/mongod b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/mongodb/6.0.27/linux-amd64/mongod similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/mongodb/6.0.27/linux-amd64/mongod rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/mongodb/6.0.27/linux-amd64/mongod diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/mongodb/7.0.28/linux-amd64/mongod b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/mongodb/7.0.28/linux-amd64/mongod similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/mongodb/7.0.28/linux-amd64/mongod rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/mongodb/7.0.28/linux-amd64/mongod diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/mongodb/8.0.17/linux-amd64/mongod b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/mongodb/8.0.17/linux-amd64/mongod similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/mongodb/8.0.17/linux-amd64/mongod rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/mongodb/8.0.17/linux-amd64/mongod diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/mysql/5.6.51/linux-amd64/mysql b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/mysql/5.6.51/linux-amd64/mysql similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/mysql/5.6.51/linux-amd64/mysql rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/mysql/5.6.51/linux-amd64/mysql diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/mysql/8.0.34/linux-amd64/mysql b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/mysql/8.0.34/linux-amd64/mysql similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/mysql/8.0.34/linux-amd64/mysql rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/mysql/8.0.34/linux-amd64/mysql diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/mysql/8.0.37/linux-amd64/mysql b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/mysql/8.0.37/linux-amd64/mysql similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/mysql/8.0.37/linux-amd64/mysql rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/mysql/8.0.37/linux-amd64/mysql diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/nginx-openresty/1.21.4.3/linux-amd64/nginx b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/nginx-openresty/1.21.4.3/linux-amd64/nginx similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/nginx-openresty/1.21.4.3/linux-amd64/nginx rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/nginx-openresty/1.21.4.3/linux-amd64/nginx diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/nginx/1.25.1/linux-amd64/nginx b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/nginx/1.25.1/linux-amd64/nginx similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/nginx/1.25.1/linux-amd64/nginx rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/nginx/1.25.1/linux-amd64/nginx diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/node/0.10.48/linux-amd64/node b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/node/0.10.48/linux-amd64/node similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/node/0.10.48/linux-amd64/node rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/node/0.10.48/linux-amd64/node diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/node/0.12.18/linux-amd64/node b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/node/0.12.18/linux-amd64/node similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/node/0.12.18/linux-amd64/node rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/node/0.12.18/linux-amd64/node diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/node/19.2.0/linux-amd64/node b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/node/19.2.0/linux-amd64/node similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/node/19.2.0/linux-amd64/node rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/node/19.2.0/linux-amd64/node diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/node/4.9.1/linux-amd64/node b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/node/4.9.1/linux-amd64/node similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/node/4.9.1/linux-amd64/node rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/node/4.9.1/linux-amd64/node diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/openssl/1.1.1w/linux-arm64/openssl b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/openssl/1.1.1w/linux-arm64/openssl similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/openssl/1.1.1w/linux-arm64/openssl rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/openssl/1.1.1w/linux-arm64/openssl diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/openssl/1.1.1zb/linux-arm64/openssl b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/openssl/1.1.1zb/linux-arm64/openssl similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/openssl/1.1.1zb/linux-arm64/openssl rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/openssl/1.1.1zb/linux-arm64/openssl diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/openssl/3.1.4/linux-amd64/openssl b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/openssl/3.1.4/linux-amd64/openssl similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/openssl/3.1.4/linux-amd64/openssl rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/openssl/3.1.4/linux-amd64/openssl diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/percona-server/8.0.35/linux-amd64/mysql b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/percona-server/8.0.35/linux-amd64/mysql similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/percona-server/8.0.35/linux-amd64/mysql rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/percona-server/8.0.35/linux-amd64/mysql diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/percona-xtrabackup/8.0.35/linux-amd64/xtrabackup b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/percona-xtrabackup/8.0.35/linux-amd64/xtrabackup similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/percona-xtrabackup/8.0.35/linux-amd64/xtrabackup rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/percona-xtrabackup/8.0.35/linux-amd64/xtrabackup diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/percona-xtradb-cluster/8.0.34/linux-amd64/mysql b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/percona-xtradb-cluster/8.0.34/linux-amd64/mysql similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/percona-xtradb-cluster/8.0.34/linux-amd64/mysql rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/percona-xtradb-cluster/8.0.34/linux-amd64/mysql diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/perl/5.12.5/linux-amd64/perl b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/perl/5.12.5/linux-amd64/perl similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/perl/5.12.5/linux-amd64/perl rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/perl/5.12.5/linux-amd64/perl diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/perl/5.20.0/linux-amd64/perl b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/perl/5.20.0/linux-amd64/perl similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/perl/5.20.0/linux-amd64/perl rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/perl/5.20.0/linux-amd64/perl diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/perl/5.37.8/linux-amd64/perl b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/perl/5.37.8/linux-amd64/perl similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/perl/5.37.8/linux-amd64/perl rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/perl/5.37.8/linux-amd64/perl diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/php-apache/8.2.1/linux-amd64/libphp.so b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/php-apache/8.2.1/linux-amd64/libphp.so similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/php-apache/8.2.1/linux-amd64/libphp.so rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/php-apache/8.2.1/linux-amd64/libphp.so diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/postgres/15.1/linux-amd64/postgres b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/postgres/15.1/linux-amd64/postgres similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/postgres/15.1/linux-amd64/postgres rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/postgres/15.1/linux-amd64/postgres diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/postgres/15beta4/linux-amd64/postgres b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/postgres/15beta4/linux-amd64/postgres similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/postgres/15beta4/linux-amd64/postgres rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/postgres/15beta4/linux-amd64/postgres diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/postgres/9.5alpha1/linux-amd64/postgres b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/postgres/9.5alpha1/linux-amd64/postgres similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/postgres/9.5alpha1/linux-amd64/postgres rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/postgres/9.5alpha1/linux-amd64/postgres diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/postgres/9.6.24/linux-amd64/postgres b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/postgres/9.6.24/linux-amd64/postgres similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/postgres/9.6.24/linux-amd64/postgres rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/postgres/9.6.24/linux-amd64/postgres diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/proftpd/1.3.8b/linux-amd64/proftpd b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/proftpd/1.3.8b/linux-amd64/proftpd similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/proftpd/1.3.8b/linux-amd64/proftpd rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/proftpd/1.3.8b/linux-amd64/proftpd diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/pypy-shared-lib/7.3.14/linux-amd64/libpypy3.9-c.so b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/pypy-shared-lib/7.3.14/linux-amd64/libpypy3.9-c.so similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/pypy-shared-lib/7.3.14/linux-amd64/libpypy3.9-c.so rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/pypy-shared-lib/7.3.14/linux-amd64/libpypy3.9-c.so diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/python-duplicates/3.8.16/linux-amd64/dir/python3.8 b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/python-duplicates/3.8.16/linux-amd64/dir/python3.8 similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/python-duplicates/3.8.16/linux-amd64/dir/python3.8 rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/python-duplicates/3.8.16/linux-amd64/dir/python3.8 diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/python-duplicates/3.8.16/linux-amd64/libpython3.8.so b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/python-duplicates/3.8.16/linux-amd64/libpython3.8.so similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/python-duplicates/3.8.16/linux-amd64/libpython3.8.so rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/python-duplicates/3.8.16/linux-amd64/libpython3.8.so diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/python-duplicates/3.8.16/linux-amd64/patchlevel.h b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/python-duplicates/3.8.16/linux-amd64/patchlevel.h similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/python-duplicates/3.8.16/linux-amd64/patchlevel.h rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/python-duplicates/3.8.16/linux-amd64/patchlevel.h diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/python-duplicates/3.8.16/linux-amd64/python3.8 b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/python-duplicates/3.8.16/linux-amd64/python3.8 similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/python-duplicates/3.8.16/linux-amd64/python3.8 rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/python-duplicates/3.8.16/linux-amd64/python3.8 diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/python-shared-lib/3.7.4/linux-amd64/libpython3.7m.so.1.0 b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/python-shared-lib/3.7.4/linux-amd64/libpython3.7m.so.1.0 similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/python-shared-lib/3.7.4/linux-amd64/libpython3.7m.so.1.0 rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/python-shared-lib/3.7.4/linux-amd64/libpython3.7m.so.1.0 diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/python-with-incorrect-match/3.5.3/linux-amd64/python3.5 b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/python-with-incorrect-match/3.5.3/linux-amd64/python3.5 similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/python-with-incorrect-match/3.5.3/linux-amd64/python3.5 rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/python-with-incorrect-match/3.5.3/linux-amd64/python3.5 diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/python/3.6.3/linux-amd64/python3.6 b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/python/3.6.3/linux-amd64/python3.6 similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/python/3.6.3/linux-amd64/python3.6 rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/python/3.6.3/linux-amd64/python3.6 diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/qt/4.8.6/linux-amd64/libQtCore.so.4.8.6 b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/qt/4.8.6/linux-amd64/libQtCore.so.4.8.6 similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/qt/4.8.6/linux-amd64/libQtCore.so.4.8.6 rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/qt/4.8.6/linux-amd64/libQtCore.so.4.8.6 diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/qt/5.15.2/linux-amd64/libQt5Core.so.5.15.2 b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/qt/5.15.2/linux-amd64/libQt5Core.so.5.15.2 similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/qt/5.15.2/linux-amd64/libQt5Core.so.5.15.2 rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/qt/5.15.2/linux-amd64/libQt5Core.so.5.15.2 diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/qt/6.5.0/linux-amd64/libQt6Core.so.6.5.0 b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/qt/6.5.0/linux-amd64/libQt6Core.so.6.5.0 similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/qt/6.5.0/linux-amd64/libQt6Core.so.6.5.0 rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/qt/6.5.0/linux-amd64/libQt6Core.so.6.5.0 diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/redis-server/2.8.23/linux-amd64/redis-server b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/redis-server/2.8.23/linux-amd64/redis-server similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/redis-server/2.8.23/linux-amd64/redis-server rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/redis-server/2.8.23/linux-amd64/redis-server diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/redis-server/4.0.11/linux-amd64/redis-server b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/redis-server/4.0.11/linux-amd64/redis-server similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/redis-server/4.0.11/linux-amd64/redis-server rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/redis-server/4.0.11/linux-amd64/redis-server diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/redis-server/5.0.0/linux-amd64/redis-server b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/redis-server/5.0.0/linux-amd64/redis-server similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/redis-server/5.0.0/linux-amd64/redis-server rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/redis-server/5.0.0/linux-amd64/redis-server diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/redis-server/6.0.16/linux-amd64/redis-server b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/redis-server/6.0.16/linux-amd64/redis-server similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/redis-server/6.0.16/linux-amd64/redis-server rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/redis-server/6.0.16/linux-amd64/redis-server diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/redis-server/7.0.0/linux-amd64/redis-server b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/redis-server/7.0.0/linux-amd64/redis-server similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/redis-server/7.0.0/linux-amd64/redis-server rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/redis-server/7.0.0/linux-amd64/redis-server diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/redis-server/7.0.14/linux-amd64/redis-server b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/redis-server/7.0.14/linux-amd64/redis-server similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/redis-server/7.0.14/linux-amd64/redis-server rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/redis-server/7.0.14/linux-amd64/redis-server diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/redis-server/7.2.3/linux-amd64/redis-server b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/redis-server/7.2.3/linux-amd64/redis-server similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/redis-server/7.2.3/linux-amd64/redis-server rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/redis-server/7.2.3/linux-amd64/redis-server diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/redis-server/7.2.3/linux-arm64/redis-server b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/redis-server/7.2.3/linux-arm64/redis-server similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/redis-server/7.2.3/linux-arm64/redis-server rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/redis-server/7.2.3/linux-arm64/redis-server diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/redis-server/7.2.5/linux-unknown-454d5f333836/redis-server b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/redis-server/7.2.5/linux-unknown-454d5f333836/redis-server similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/redis-server/7.2.5/linux-unknown-454d5f333836/redis-server rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/redis-server/7.2.5/linux-unknown-454d5f333836/redis-server diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/ruby/1.9.3p551/linux-amd64/ruby b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/ruby/1.9.3p551/linux-amd64/ruby similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/ruby/1.9.3p551/linux-amd64/ruby rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/ruby/1.9.3p551/linux-amd64/ruby diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/rust-libstd-musl/1.67.1/linux-amd64/libstd-86aefecbddda356d.so b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/rust-libstd-musl/1.67.1/linux-amd64/libstd-86aefecbddda356d.so similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/rust-libstd-musl/1.67.1/linux-amd64/libstd-86aefecbddda356d.so rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/rust-libstd-musl/1.67.1/linux-amd64/libstd-86aefecbddda356d.so diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/rust-libstd/1.50.0/darwin/libstd-f6f9eec1635e636a.dylib b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/rust-libstd/1.50.0/darwin/libstd-f6f9eec1635e636a.dylib similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/rust-libstd/1.50.0/darwin/libstd-f6f9eec1635e636a.dylib rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/rust-libstd/1.50.0/darwin/libstd-f6f9eec1635e636a.dylib diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/rust-libstd/1.50.0/linux-amd64/libstd-6f77337c1826707d.so b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/rust-libstd/1.50.0/linux-amd64/libstd-6f77337c1826707d.so similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/rust-libstd/1.50.0/linux-amd64/libstd-6f77337c1826707d.so rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/rust-libstd/1.50.0/linux-amd64/libstd-6f77337c1826707d.so diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/rust-libstd/1.67.1/darwin/libstd-16f2b65e77054c42.dylib b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/rust-libstd/1.67.1/darwin/libstd-16f2b65e77054c42.dylib similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/rust-libstd/1.67.1/darwin/libstd-16f2b65e77054c42.dylib rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/rust-libstd/1.67.1/darwin/libstd-16f2b65e77054c42.dylib diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/rust-libstd/1.67.1/linux-amd64/libstd-c6192dd4c4d410ac.so b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/rust-libstd/1.67.1/linux-amd64/libstd-c6192dd4c4d410ac.so similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/rust-libstd/1.67.1/linux-amd64/libstd-c6192dd4c4d410ac.so rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/rust-libstd/1.67.1/linux-amd64/libstd-c6192dd4c4d410ac.so diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/sqlcipher/4.5.5/linux-amd64/sqlcipher b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/sqlcipher/4.5.5/linux-amd64/sqlcipher similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/sqlcipher/4.5.5/linux-amd64/sqlcipher rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/sqlcipher/4.5.5/linux-amd64/sqlcipher diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/swipl/9.3.8/linux-amd64/swipl b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/swipl/9.3.8/linux-amd64/swipl similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/swipl/9.3.8/linux-amd64/swipl rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/swipl/9.3.8/linux-amd64/swipl diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/traefik/1.7.34/linux-amd64/traefik b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/traefik/1.7.34/linux-amd64/traefik similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/traefik/1.7.34/linux-amd64/traefik rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/traefik/1.7.34/linux-amd64/traefik diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/traefik/2.10.7/linux-amd64/traefik b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/traefik/2.10.7/linux-amd64/traefik similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/traefik/2.10.7/linux-amd64/traefik rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/traefik/2.10.7/linux-amd64/traefik diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/traefik/2.9.6/linux-amd64/traefik b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/traefik/2.9.6/linux-amd64/traefik similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/traefik/2.9.6/linux-amd64/traefik rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/traefik/2.9.6/linux-amd64/traefik diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/traefik/3.0.4/linux-riscv64/traefik b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/traefik/3.0.4/linux-riscv64/traefik similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/traefik/3.0.4/linux-riscv64/traefik rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/traefik/3.0.4/linux-riscv64/traefik diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/traefik/3.6.5/linux-amd64/traefik b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/traefik/3.6.5/linux-amd64/traefik similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/traefik/3.6.5/linux-amd64/traefik rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/traefik/3.6.5/linux-amd64/traefik diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/util-linux/2.37.4/linux-amd64/getopt b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/util-linux/2.37.4/linux-amd64/getopt similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/util-linux/2.37.4/linux-amd64/getopt rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/util-linux/2.37.4/linux-amd64/getopt diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/valkey-server/9.0.0/linux-amd64/valkey-server b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/valkey-server/9.0.0/linux-amd64/valkey-server similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/valkey-server/9.0.0/linux-amd64/valkey-server rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/valkey-server/9.0.0/linux-amd64/valkey-server diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/vault/1.19.4/linux-arm64/vault b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/vault/1.19.4/linux-arm64/vault similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/vault/1.19.4/linux-arm64/vault rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/vault/1.19.4/linux-arm64/vault diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/vault/1.20.2/linux-amd64/vault b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/vault/1.20.2/linux-amd64/vault similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/vault/1.20.2/linux-amd64/vault rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/vault/1.20.2/linux-amd64/vault diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/wp/2.9.0/linux-amd64/wp b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/wp/2.9.0/linux-amd64/wp similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/wp/2.9.0/linux-amd64/wp rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/wp/2.9.0/linux-amd64/wp diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/xz/5.6.2/linux-amd64/xz b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/xz/5.6.2/linux-amd64/xz similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/xz/5.6.2/linux-amd64/xz rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/xz/5.6.2/linux-amd64/xz diff --git a/syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/zstd/1.5.6/linux-amd64/zstd b/syft/pkg/cataloger/binary/testdata/classifiers/snippets/zstd/1.5.6/linux-amd64/zstd similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/classifiers/snippets/zstd/1.5.6/linux-amd64/zstd rename to syft/pkg/cataloger/binary/testdata/classifiers/snippets/zstd/1.5.6/linux-amd64/zstd diff --git a/syft/pkg/cataloger/binary/test-fixtures/config.yaml b/syft/pkg/cataloger/binary/testdata/config.yaml similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/config.yaml rename to syft/pkg/cataloger/binary/testdata/config.yaml diff --git a/syft/pkg/cataloger/binary/test-fixtures/custom/extra/foo b/syft/pkg/cataloger/binary/testdata/custom/extra/foo similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/custom/extra/foo rename to syft/pkg/cataloger/binary/testdata/custom/extra/foo diff --git a/syft/pkg/cataloger/binary/test-fixtures/custom/go-1.14/go b/syft/pkg/cataloger/binary/testdata/custom/go-1.14/go similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/custom/go-1.14/go rename to syft/pkg/cataloger/binary/testdata/custom/go-1.14/go diff --git a/syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/Dockerfile b/syft/pkg/cataloger/binary/testdata/elf-testdata/Dockerfile similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/Dockerfile rename to syft/pkg/cataloger/binary/testdata/elf-testdata/Dockerfile diff --git a/syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/README.md b/syft/pkg/cataloger/binary/testdata/elf-testdata/README.md similarity index 98% rename from syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/README.md rename to syft/pkg/cataloger/binary/testdata/elf-testdata/README.md index e96480405..e8c698d7d 100644 --- a/syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/README.md +++ b/syft/pkg/cataloger/binary/testdata/elf-testdata/README.md @@ -1,7 +1,7 @@ ## Summary This image illustrates a few examples of how ELF executables can be assembled and illustrated in an SBOM. -### Example 1: elf-test-fixtures/elfbinwithsisterlib +### Example 1: elf-testdata/elfbinwithsisterlib This example builds two binaries with srcs found in elfsrc1 and elfsrc2. diff --git a/syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithcorrupt/elfsrc/hello_world.cpp b/syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithcorrupt/elfsrc/hello_world.cpp similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithcorrupt/elfsrc/hello_world.cpp rename to syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithcorrupt/elfsrc/hello_world.cpp diff --git a/syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithcorrupt/elfsrc/hello_world.h b/syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithcorrupt/elfsrc/hello_world.h similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithcorrupt/elfsrc/hello_world.h rename to syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithcorrupt/elfsrc/hello_world.h diff --git a/syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithcorrupt/elfsrc/makefile b/syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithcorrupt/elfsrc/makefile similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithcorrupt/elfsrc/makefile rename to syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithcorrupt/elfsrc/makefile diff --git a/syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithcorrupt/elfsrc/testbin.cpp b/syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithcorrupt/elfsrc/testbin.cpp similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithcorrupt/elfsrc/testbin.cpp rename to syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithcorrupt/elfsrc/testbin.cpp diff --git a/syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithcorrupt/makefile b/syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithcorrupt/makefile similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithcorrupt/makefile rename to syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithcorrupt/makefile diff --git a/syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithnestedlib/elfsrc/hello_world.cpp b/syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithnestedlib/elfsrc/hello_world.cpp similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithnestedlib/elfsrc/hello_world.cpp rename to syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithnestedlib/elfsrc/hello_world.cpp diff --git a/syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithnestedlib/elfsrc/hello_world.h b/syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithnestedlib/elfsrc/hello_world.h similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithnestedlib/elfsrc/hello_world.h rename to syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithnestedlib/elfsrc/hello_world.h diff --git a/syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithnestedlib/elfsrc/makefile b/syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithnestedlib/elfsrc/makefile similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithnestedlib/elfsrc/makefile rename to syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithnestedlib/elfsrc/makefile diff --git a/syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithnestedlib/elfsrc/testbin.cpp b/syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithnestedlib/elfsrc/testbin.cpp similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithnestedlib/elfsrc/testbin.cpp rename to syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithnestedlib/elfsrc/testbin.cpp diff --git a/syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithnestedlib/makefile b/syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithnestedlib/makefile similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithnestedlib/makefile rename to syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithnestedlib/makefile diff --git a/syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithsisterlib/elfsrc1/hello_world.cpp b/syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithsisterlib/elfsrc1/hello_world.cpp similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithsisterlib/elfsrc1/hello_world.cpp rename to syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithsisterlib/elfsrc1/hello_world.cpp diff --git a/syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithsisterlib/elfsrc1/hello_world.h b/syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithsisterlib/elfsrc1/hello_world.h similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithsisterlib/elfsrc1/hello_world.h rename to syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithsisterlib/elfsrc1/hello_world.h diff --git a/syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithsisterlib/elfsrc1/makefile b/syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithsisterlib/elfsrc1/makefile similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithsisterlib/elfsrc1/makefile rename to syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithsisterlib/elfsrc1/makefile diff --git a/syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithsisterlib/elfsrc1/testbin.cpp b/syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithsisterlib/elfsrc1/testbin.cpp similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithsisterlib/elfsrc1/testbin.cpp rename to syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithsisterlib/elfsrc1/testbin.cpp diff --git a/syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithsisterlib/elfsrc2/hello_world2.cpp b/syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithsisterlib/elfsrc2/hello_world2.cpp similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithsisterlib/elfsrc2/hello_world2.cpp rename to syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithsisterlib/elfsrc2/hello_world2.cpp diff --git a/syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithsisterlib/elfsrc2/hello_world2.h b/syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithsisterlib/elfsrc2/hello_world2.h similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithsisterlib/elfsrc2/hello_world2.h rename to syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithsisterlib/elfsrc2/hello_world2.h diff --git a/syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithsisterlib/elfsrc2/makefile b/syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithsisterlib/elfsrc2/makefile similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithsisterlib/elfsrc2/makefile rename to syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithsisterlib/elfsrc2/makefile diff --git a/syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithsisterlib/elfsrc2/testbin2.cpp b/syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithsisterlib/elfsrc2/testbin2.cpp similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithsisterlib/elfsrc2/testbin2.cpp rename to syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithsisterlib/elfsrc2/testbin2.cpp diff --git a/syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithsisterlib/makefile b/syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithsisterlib/makefile similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/elf-test-fixtures/elfbinwithsisterlib/makefile rename to syft/pkg/cataloger/binary/testdata/elf-testdata/elfbinwithsisterlib/makefile diff --git a/syft/pkg/cataloger/binary/test-fixtures/image-busybox/Dockerfile b/syft/pkg/cataloger/binary/testdata/image-busybox/Dockerfile similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/image-busybox/Dockerfile rename to syft/pkg/cataloger/binary/testdata/image-busybox/Dockerfile diff --git a/syft/pkg/cataloger/binary/test-fixtures/image-dotnet-app/Dockerfile b/syft/pkg/cataloger/binary/testdata/image-dotnet-app/Dockerfile similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/image-dotnet-app/Dockerfile rename to syft/pkg/cataloger/binary/testdata/image-dotnet-app/Dockerfile diff --git a/syft/pkg/cataloger/binary/test-fixtures/image-fedora-32bit/Dockerfile b/syft/pkg/cataloger/binary/testdata/image-fedora-32bit/Dockerfile similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/image-fedora-32bit/Dockerfile rename to syft/pkg/cataloger/binary/testdata/image-fedora-32bit/Dockerfile diff --git a/syft/pkg/cataloger/binary/test-fixtures/image-fedora-64bit/Dockerfile b/syft/pkg/cataloger/binary/testdata/image-fedora-64bit/Dockerfile similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/image-fedora-64bit/Dockerfile rename to syft/pkg/cataloger/binary/testdata/image-fedora-64bit/Dockerfile diff --git a/syft/pkg/cataloger/binary/test-fixtures/image-java-binary/Dockerfile b/syft/pkg/cataloger/binary/testdata/image-java-binary/Dockerfile similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/image-java-binary/Dockerfile rename to syft/pkg/cataloger/binary/testdata/image-java-binary/Dockerfile diff --git a/syft/pkg/cataloger/binary/test-fixtures/image-java-ibm-8/Dockerfile b/syft/pkg/cataloger/binary/testdata/image-java-ibm-8/Dockerfile similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/image-java-ibm-8/Dockerfile rename to syft/pkg/cataloger/binary/testdata/image-java-ibm-8/Dockerfile diff --git a/syft/pkg/cataloger/binary/test-fixtures/image-java-ibm-jre-8/Dockerfile b/syft/pkg/cataloger/binary/testdata/image-java-ibm-jre-8/Dockerfile similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/image-java-ibm-jre-8/Dockerfile rename to syft/pkg/cataloger/binary/testdata/image-java-ibm-jre-8/Dockerfile diff --git a/syft/pkg/cataloger/binary/test-fixtures/image-java-ibm-sdk-8/Dockerfile b/syft/pkg/cataloger/binary/testdata/image-java-ibm-sdk-8/Dockerfile similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/image-java-ibm-sdk-8/Dockerfile rename to syft/pkg/cataloger/binary/testdata/image-java-ibm-sdk-8/Dockerfile diff --git a/syft/pkg/cataloger/binary/test-fixtures/image-java-zulu-21/Dockerfile b/syft/pkg/cataloger/binary/testdata/image-java-zulu-21/Dockerfile similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/image-java-zulu-21/Dockerfile rename to syft/pkg/cataloger/binary/testdata/image-java-zulu-21/Dockerfile diff --git a/syft/pkg/cataloger/binary/test-fixtures/image-java-zulu-8/Dockerfile b/syft/pkg/cataloger/binary/testdata/image-java-zulu-8/Dockerfile similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/image-java-zulu-8/Dockerfile rename to syft/pkg/cataloger/binary/testdata/image-java-zulu-8/Dockerfile diff --git a/syft/pkg/cataloger/binary/test-fixtures/image-jruby/Dockerfile b/syft/pkg/cataloger/binary/testdata/image-jruby/Dockerfile similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/image-jruby/Dockerfile rename to syft/pkg/cataloger/binary/testdata/image-jruby/Dockerfile diff --git a/syft/pkg/cataloger/binary/test-fixtures/image-wolfi-64bit-without-version/Dockerfile b/syft/pkg/cataloger/binary/testdata/image-wolfi-64bit-without-version/Dockerfile similarity index 100% rename from syft/pkg/cataloger/binary/test-fixtures/image-wolfi-64bit-without-version/Dockerfile rename to syft/pkg/cataloger/binary/testdata/image-wolfi-64bit-without-version/Dockerfile diff --git a/syft/pkg/cataloger/bitnami/cataloger_test.go b/syft/pkg/cataloger/bitnami/cataloger_test.go index 7f56e30b4..624b8ab1c 100644 --- a/syft/pkg/cataloger/bitnami/cataloger_test.go +++ b/syft/pkg/cataloger/bitnami/cataloger_test.go @@ -444,7 +444,11 @@ func TestBitnamiCataloger(t *testing.T) { Architecture: "arm64", Distro: "debian-12", Path: "opt/bitnami/redis", - Files: []string{"opt/bitnami/redis/bin/redis-server"}, + Files: []string{ + "opt/bitnami/redis/.gitignore", + "opt/bitnami/redis/bin/.gitignore", + "opt/bitnami/redis/bin/redis-server", + }, }, } @@ -560,48 +564,48 @@ func TestBitnamiCataloger(t *testing.T) { }{ { name: "parse valid PostgreSQL SBOM", - fixture: "test-fixtures/json", + fixture: "testdata/json", wantPkgs: postgresqlExpectedPkgs, wantRelationships: postgresqlExpectedRelationships, wantErr: require.NoError, }, { name: "parse valid SBOM that includes both Bitnami and non-Bitnami packages", - fixture: "test-fixtures/mix", + fixture: "testdata/mix", wantPkgs: []pkg.Package{renderTemplateMainPkg}, wantRelationships: nil, wantErr: require.NoError, }, { name: "Redis SBOM with not allowed tag-value format", - fixture: "test-fixtures/tag-value", + fixture: "testdata/tag-value", wantPkgs: nil, wantRelationships: nil, wantErr: require.NoError, }, { name: "Invalid SBOM", - fixture: "test-fixtures/invalid", + fixture: "testdata/invalid", wantPkgs: nil, wantRelationships: nil, wantErr: require.Error, }, { name: "SBOM with no relationships", - fixture: "test-fixtures/no-rel", + fixture: "testdata/no-rel", wantPkgs: []pkg.Package{redisMainPkg}, wantRelationships: nil, }, { name: "parse legacy .bitnami_components.json (MongoDB with multiple components)", - fixture: "test-fixtures/components-json-mongodb", + fixture: "testdata/components-json-mongodb", wantPkgs: mongodbComponentsPkgs, wantRelationships: nil, wantErr: require.NoError, }, { name: "parse legacy .bitnami_components.json (PostgreSQL single component, no digest)", - fixture: "test-fixtures/components-json-postgresql", + fixture: "testdata/components-json-postgresql", wantPkgs: postgresqlComponentsPkgs, wantRelationships: nil, wantErr: require.NoError, diff --git a/syft/pkg/cataloger/bitnami/test-fixtures/components-json-mongodb/opt/bitnami/.bitnami_components.json b/syft/pkg/cataloger/bitnami/testdata/components-json-mongodb/opt/bitnami/.bitnami_components.json similarity index 100% rename from syft/pkg/cataloger/bitnami/test-fixtures/components-json-mongodb/opt/bitnami/.bitnami_components.json rename to syft/pkg/cataloger/bitnami/testdata/components-json-mongodb/opt/bitnami/.bitnami_components.json diff --git a/syft/pkg/cataloger/bitnami/test-fixtures/components-json-postgresql/opt/bitnami/.bitnami_components.json b/syft/pkg/cataloger/bitnami/testdata/components-json-postgresql/opt/bitnami/.bitnami_components.json similarity index 100% rename from syft/pkg/cataloger/bitnami/test-fixtures/components-json-postgresql/opt/bitnami/.bitnami_components.json rename to syft/pkg/cataloger/bitnami/testdata/components-json-postgresql/opt/bitnami/.bitnami_components.json diff --git a/syft/pkg/cataloger/bitnami/test-fixtures/invalid/opt/bitnami/redis/.spdx-redis.spdx b/syft/pkg/cataloger/bitnami/testdata/invalid/opt/bitnami/redis/.spdx-redis.spdx similarity index 100% rename from syft/pkg/cataloger/bitnami/test-fixtures/invalid/opt/bitnami/redis/.spdx-redis.spdx rename to syft/pkg/cataloger/bitnami/testdata/invalid/opt/bitnami/redis/.spdx-redis.spdx diff --git a/syft/pkg/cataloger/bitnami/test-fixtures/json/opt/bitnami/postgresql/.spdx-postgresql.spdx b/syft/pkg/cataloger/bitnami/testdata/json/opt/bitnami/postgresql/.spdx-postgresql.spdx similarity index 100% rename from syft/pkg/cataloger/bitnami/test-fixtures/json/opt/bitnami/postgresql/.spdx-postgresql.spdx rename to syft/pkg/cataloger/bitnami/testdata/json/opt/bitnami/postgresql/.spdx-postgresql.spdx diff --git a/syft/pkg/cataloger/bitnami/test-fixtures/json/opt/bitnami/postgresql/readme.txt b/syft/pkg/cataloger/bitnami/testdata/json/opt/bitnami/postgresql/readme.txt similarity index 100% rename from syft/pkg/cataloger/bitnami/test-fixtures/json/opt/bitnami/postgresql/readme.txt rename to syft/pkg/cataloger/bitnami/testdata/json/opt/bitnami/postgresql/readme.txt diff --git a/syft/pkg/cataloger/bitnami/test-fixtures/mix/opt/bitnami/render-template/.spdx-render-template.spdx b/syft/pkg/cataloger/bitnami/testdata/mix/opt/bitnami/render-template/.spdx-render-template.spdx similarity index 100% rename from syft/pkg/cataloger/bitnami/test-fixtures/mix/opt/bitnami/render-template/.spdx-render-template.spdx rename to syft/pkg/cataloger/bitnami/testdata/mix/opt/bitnami/render-template/.spdx-render-template.spdx diff --git a/syft/pkg/cataloger/bitnami/testdata/no-rel/opt/bitnami/redis/.gitignore b/syft/pkg/cataloger/bitnami/testdata/no-rel/opt/bitnami/redis/.gitignore new file mode 100644 index 000000000..905bc56c0 --- /dev/null +++ b/syft/pkg/cataloger/bitnami/testdata/no-rel/opt/bitnami/redis/.gitignore @@ -0,0 +1,2 @@ +# override root level ignores for test fixtures +!bin/ diff --git a/syft/pkg/cataloger/bitnami/test-fixtures/no-rel/opt/bitnami/redis/.spdx-redis.spdx b/syft/pkg/cataloger/bitnami/testdata/no-rel/opt/bitnami/redis/.spdx-redis.spdx similarity index 100% rename from syft/pkg/cataloger/bitnami/test-fixtures/no-rel/opt/bitnami/redis/.spdx-redis.spdx rename to syft/pkg/cataloger/bitnami/testdata/no-rel/opt/bitnami/redis/.spdx-redis.spdx diff --git a/syft/pkg/cataloger/bitnami/testdata/no-rel/opt/bitnami/redis/bin/.gitignore b/syft/pkg/cataloger/bitnami/testdata/no-rel/opt/bitnami/redis/bin/.gitignore new file mode 100644 index 000000000..5022a8e0b --- /dev/null +++ b/syft/pkg/cataloger/bitnami/testdata/no-rel/opt/bitnami/redis/bin/.gitignore @@ -0,0 +1,2 @@ +# override root level ignores for test fixtures +!* diff --git a/syft/pkg/cataloger/bitnami/test-fixtures/no-rel/opt/bitnami/redis/bin/redis-server b/syft/pkg/cataloger/bitnami/testdata/no-rel/opt/bitnami/redis/bin/redis-server similarity index 100% rename from syft/pkg/cataloger/bitnami/test-fixtures/no-rel/opt/bitnami/redis/bin/redis-server rename to syft/pkg/cataloger/bitnami/testdata/no-rel/opt/bitnami/redis/bin/redis-server diff --git a/syft/pkg/cataloger/bitnami/test-fixtures/tag-value/opt/bitnami/redis/.spdx-apache.spdx b/syft/pkg/cataloger/bitnami/testdata/tag-value/opt/bitnami/redis/.spdx-apache.spdx similarity index 100% rename from syft/pkg/cataloger/bitnami/test-fixtures/tag-value/opt/bitnami/redis/.spdx-apache.spdx rename to syft/pkg/cataloger/bitnami/testdata/tag-value/opt/bitnami/redis/.spdx-apache.spdx diff --git a/syft/pkg/cataloger/conda/cataloger_test.go b/syft/pkg/cataloger/conda/cataloger_test.go index 0c25db326..74d630403 100644 --- a/syft/pkg/cataloger/conda/cataloger_test.go +++ b/syft/pkg/cataloger/conda/cataloger_test.go @@ -24,7 +24,7 @@ func Test_CondaCataloger(t *testing.T) { }{ { name: "multiple packages in conda meta (python, c binaries, ...)", - fixture: "test-fixtures/conda-meta-python-c-etc", + fixture: "testdata/conda-meta-python-c-etc", wantErr: require.NoError, expectedPackages: []pkg.Package{ { @@ -193,7 +193,7 @@ func Test_CondaCataloger(t *testing.T) { }, { name: "badly formatted conda meta json file", - fixture: "test-fixtures/conda-meta-bad-json", + fixture: "testdata/conda-meta-bad-json", expectedPackages: nil, wantErr: func(t require.TestingT, err error, msgAndArgs ...interface{}) { require.Error(t, err) diff --git a/syft/pkg/cataloger/conda/test-fixtures/conda-meta-bad-json/conda-meta/package-1.2.3-pyhd8ed1ab_0.json b/syft/pkg/cataloger/conda/testdata/conda-meta-bad-json/conda-meta/package-1.2.3-pyhd8ed1ab_0.json similarity index 100% rename from syft/pkg/cataloger/conda/test-fixtures/conda-meta-bad-json/conda-meta/package-1.2.3-pyhd8ed1ab_0.json rename to syft/pkg/cataloger/conda/testdata/conda-meta-bad-json/conda-meta/package-1.2.3-pyhd8ed1ab_0.json diff --git a/syft/pkg/cataloger/conda/test-fixtures/conda-meta-python-c-etc/conda-meta/jupyterlab-4.4.3-pyhd8ed1ab_0.json b/syft/pkg/cataloger/conda/testdata/conda-meta-python-c-etc/conda-meta/jupyterlab-4.4.3-pyhd8ed1ab_0.json similarity index 100% rename from syft/pkg/cataloger/conda/test-fixtures/conda-meta-python-c-etc/conda-meta/jupyterlab-4.4.3-pyhd8ed1ab_0.json rename to syft/pkg/cataloger/conda/testdata/conda-meta-python-c-etc/conda-meta/jupyterlab-4.4.3-pyhd8ed1ab_0.json diff --git a/syft/pkg/cataloger/conda/test-fixtures/conda-meta-python-c-etc/conda-meta/zlib-1.2.11-h90dfc92_1014.json b/syft/pkg/cataloger/conda/testdata/conda-meta-python-c-etc/conda-meta/zlib-1.2.11-h90dfc92_1014.json similarity index 100% rename from syft/pkg/cataloger/conda/test-fixtures/conda-meta-python-c-etc/conda-meta/zlib-1.2.11-h90dfc92_1014.json rename to syft/pkg/cataloger/conda/testdata/conda-meta-python-c-etc/conda-meta/zlib-1.2.11-h90dfc92_1014.json diff --git a/syft/pkg/cataloger/cpp/cataloger_test.go b/syft/pkg/cataloger/cpp/cataloger_test.go index 56887ac02..99b4543c9 100644 --- a/syft/pkg/cataloger/cpp/cataloger_test.go +++ b/syft/pkg/cataloger/cpp/cataloger_test.go @@ -14,7 +14,7 @@ func TestCataloger_Globs(t *testing.T) { }{ { name: "obtain conan files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "somewhere/src/conanfile.txt", "somewhere/src/conan.lock", @@ -40,7 +40,7 @@ func TestCatalogerInfo_Globs(t *testing.T) { }{ { name: "obtain conan files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "somewhere/src/conaninfo.txt", }, diff --git a/syft/pkg/cataloger/cpp/parse_conanfile_test.go b/syft/pkg/cataloger/cpp/parse_conanfile_test.go index 65a4b9b0d..53995493b 100644 --- a/syft/pkg/cataloger/cpp/parse_conanfile_test.go +++ b/syft/pkg/cataloger/cpp/parse_conanfile_test.go @@ -10,7 +10,7 @@ import ( ) func TestParseConanfile(t *testing.T) { - fixture := "test-fixtures/conanfile.txt" + fixture := "testdata/conanfile.txt" fixtureLocationSet := file.NewLocationSet(file.NewLocation(fixture)) expected := []pkg.Package{ { diff --git a/syft/pkg/cataloger/cpp/parse_conaninfo_test.go b/syft/pkg/cataloger/cpp/parse_conaninfo_test.go index 3c7eb1bac..92fbd1342 100644 --- a/syft/pkg/cataloger/cpp/parse_conaninfo_test.go +++ b/syft/pkg/cataloger/cpp/parse_conaninfo_test.go @@ -10,7 +10,7 @@ import ( ) func TestParseConaninfo(t *testing.T) { - fixture := "test-fixtures/conaninfo/mfast/1.2.2/my_user/my_channel/package/9d1f076b471417647c2022a78d5e2c1f834289ac/conaninfo.txt" + fixture := "testdata/conaninfo/mfast/1.2.2/my_user/my_channel/package/9d1f076b471417647c2022a78d5e2c1f834289ac/conaninfo.txt" expected := []pkg.Package{ { Name: "mfast", diff --git a/syft/pkg/cataloger/cpp/parse_conanlock_test.go b/syft/pkg/cataloger/cpp/parse_conanlock_test.go index 23fe24c28..9c0c664b7 100644 --- a/syft/pkg/cataloger/cpp/parse_conanlock_test.go +++ b/syft/pkg/cataloger/cpp/parse_conanlock_test.go @@ -10,7 +10,7 @@ import ( ) func TestParseConanLock(t *testing.T) { - fixture := "test-fixtures/conan.lock" + fixture := "testdata/conan.lock" expected := []pkg.Package{ { Name: "mfast", @@ -334,7 +334,7 @@ func TestParseConanLock(t *testing.T) { } func TestParseConanLockV2(t *testing.T) { - fixture := "test-fixtures/conanlock-v2/conan.lock" + fixture := "testdata/conanlock-v2/conan.lock" expected := []pkg.Package{ { Name: "matrix", @@ -376,7 +376,7 @@ func TestParseConanLockV2(t *testing.T) { func Test_corruptConanlock(t *testing.T) { pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/corrupt/conan.lock"). + FromFile(t, "testdata/corrupt/conan.lock"). WithError(). TestParser(t, parseConanLock) } diff --git a/syft/pkg/cataloger/cpp/test-fixtures/README.md b/syft/pkg/cataloger/cpp/testdata/README.md similarity index 100% rename from syft/pkg/cataloger/cpp/test-fixtures/README.md rename to syft/pkg/cataloger/cpp/testdata/README.md diff --git a/syft/pkg/cataloger/cpp/test-fixtures/conan.lock b/syft/pkg/cataloger/cpp/testdata/conan.lock similarity index 100% rename from syft/pkg/cataloger/cpp/test-fixtures/conan.lock rename to syft/pkg/cataloger/cpp/testdata/conan.lock diff --git a/syft/pkg/cataloger/cpp/test-fixtures/conanfile.txt b/syft/pkg/cataloger/cpp/testdata/conanfile.txt similarity index 100% rename from syft/pkg/cataloger/cpp/test-fixtures/conanfile.txt rename to syft/pkg/cataloger/cpp/testdata/conanfile.txt diff --git a/syft/pkg/cataloger/cpp/test-fixtures/conaninfo/mfast/1.2.2/my_user/my_channel/package/9d1f076b471417647c2022a78d5e2c1f834289ac/conaninfo.txt b/syft/pkg/cataloger/cpp/testdata/conaninfo/mfast/1.2.2/my_user/my_channel/package/9d1f076b471417647c2022a78d5e2c1f834289ac/conaninfo.txt similarity index 100% rename from syft/pkg/cataloger/cpp/test-fixtures/conaninfo/mfast/1.2.2/my_user/my_channel/package/9d1f076b471417647c2022a78d5e2c1f834289ac/conaninfo.txt rename to syft/pkg/cataloger/cpp/testdata/conaninfo/mfast/1.2.2/my_user/my_channel/package/9d1f076b471417647c2022a78d5e2c1f834289ac/conaninfo.txt diff --git a/syft/pkg/cataloger/cpp/test-fixtures/conanlock-v2/conan.lock b/syft/pkg/cataloger/cpp/testdata/conanlock-v2/conan.lock similarity index 100% rename from syft/pkg/cataloger/cpp/test-fixtures/conanlock-v2/conan.lock rename to syft/pkg/cataloger/cpp/testdata/conanlock-v2/conan.lock diff --git a/syft/pkg/cataloger/cpp/test-fixtures/corrupt/conan.lock b/syft/pkg/cataloger/cpp/testdata/corrupt/conan.lock similarity index 100% rename from syft/pkg/cataloger/cpp/test-fixtures/corrupt/conan.lock rename to syft/pkg/cataloger/cpp/testdata/corrupt/conan.lock diff --git a/syft/pkg/cataloger/cpp/test-fixtures/glob-paths/somewhere/src/conan.lock b/syft/pkg/cataloger/cpp/testdata/glob-paths/somewhere/src/conan.lock similarity index 100% rename from syft/pkg/cataloger/cpp/test-fixtures/glob-paths/somewhere/src/conan.lock rename to syft/pkg/cataloger/cpp/testdata/glob-paths/somewhere/src/conan.lock diff --git a/syft/pkg/cataloger/cpp/test-fixtures/glob-paths/somewhere/src/conanfile.txt b/syft/pkg/cataloger/cpp/testdata/glob-paths/somewhere/src/conanfile.txt similarity index 100% rename from syft/pkg/cataloger/cpp/test-fixtures/glob-paths/somewhere/src/conanfile.txt rename to syft/pkg/cataloger/cpp/testdata/glob-paths/somewhere/src/conanfile.txt diff --git a/syft/pkg/cataloger/cpp/test-fixtures/glob-paths/somewhere/src/conaninfo.txt b/syft/pkg/cataloger/cpp/testdata/glob-paths/somewhere/src/conaninfo.txt similarity index 100% rename from syft/pkg/cataloger/cpp/test-fixtures/glob-paths/somewhere/src/conaninfo.txt rename to syft/pkg/cataloger/cpp/testdata/glob-paths/somewhere/src/conaninfo.txt diff --git a/syft/pkg/cataloger/dart/cataloger_test.go b/syft/pkg/cataloger/dart/cataloger_test.go index 6ad9f1518..d1eb60ecc 100644 --- a/syft/pkg/cataloger/dart/cataloger_test.go +++ b/syft/pkg/cataloger/dart/cataloger_test.go @@ -14,7 +14,7 @@ func TestPubspecLockCataloger_Globs(t *testing.T) { }{ { name: "obtain pubspec lock files", - fixture: "test-fixtures/glob-paths/lock", + fixture: "testdata/glob-paths/lock", expected: []string{ "src/pubspec.lock", }, @@ -39,7 +39,7 @@ func TestPubspecCataloger_Globs(t *testing.T) { }{ { name: "obtain pubspec files", - fixture: "test-fixtures/glob-paths/spec", + fixture: "testdata/glob-paths/spec", expected: []string{ "pubspec.yml", "pubspec.yaml", diff --git a/syft/pkg/cataloger/dart/parse_pubspec_lock_test.go b/syft/pkg/cataloger/dart/parse_pubspec_lock_test.go index 43fc79b15..313807c9c 100644 --- a/syft/pkg/cataloger/dart/parse_pubspec_lock_test.go +++ b/syft/pkg/cataloger/dart/parse_pubspec_lock_test.go @@ -20,13 +20,13 @@ func TestParsePubspecLock(t *testing.T) { }{ { name: "standard pubspec.lock", - fixture: "test-fixtures/pubspec_locks/pubspec.lock", + fixture: "testdata/pubspec_locks/pubspec.lock", expectedPackages: []pkg.Package{ { Name: "ale", Version: "3.3.0", PURL: "pkg:pub/ale@3.3.0?hosted_url=pub.hosted.org", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/pubspec_locks/pubspec.lock")), + Locations: file.NewLocationSet(file.NewLocation("testdata/pubspec_locks/pubspec.lock")), Language: pkg.Dart, Type: pkg.DartPubPkg, Metadata: pkg.DartPubspecLockEntry{ @@ -39,7 +39,7 @@ func TestParsePubspecLock(t *testing.T) { Name: "analyzer", Version: "0.40.7", PURL: "pkg:pub/analyzer@0.40.7", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/pubspec_locks/pubspec.lock")), + Locations: file.NewLocationSet(file.NewLocation("testdata/pubspec_locks/pubspec.lock")), Language: pkg.Dart, Type: pkg.DartPubPkg, Metadata: pkg.DartPubspecLockEntry{ @@ -51,7 +51,7 @@ func TestParsePubspecLock(t *testing.T) { Name: "ansicolor", Version: "1.1.1", PURL: "pkg:pub/ansicolor@1.1.1", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/pubspec_locks/pubspec.lock")), + Locations: file.NewLocationSet(file.NewLocation("testdata/pubspec_locks/pubspec.lock")), Language: pkg.Dart, Type: pkg.DartPubPkg, Metadata: pkg.DartPubspecLockEntry{ @@ -63,7 +63,7 @@ func TestParsePubspecLock(t *testing.T) { Name: "archive", Version: "2.0.13", PURL: "pkg:pub/archive@2.0.13", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/pubspec_locks/pubspec.lock")), + Locations: file.NewLocationSet(file.NewLocation("testdata/pubspec_locks/pubspec.lock")), Language: pkg.Dart, Type: pkg.DartPubPkg, Metadata: pkg.DartPubspecLockEntry{ @@ -75,7 +75,7 @@ func TestParsePubspecLock(t *testing.T) { Name: "args", Version: "1.6.0", PURL: "pkg:pub/args@1.6.0", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/pubspec_locks/pubspec.lock")), + Locations: file.NewLocationSet(file.NewLocation("testdata/pubspec_locks/pubspec.lock")), Language: pkg.Dart, Type: pkg.DartPubPkg, Metadata: pkg.DartPubspecLockEntry{ @@ -87,7 +87,7 @@ func TestParsePubspecLock(t *testing.T) { Name: "flutter", Version: "3.24.5", PURL: "pkg:pub/flutter@3.24.5", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/pubspec_locks/pubspec.lock")), + Locations: file.NewLocationSet(file.NewLocation("testdata/pubspec_locks/pubspec.lock")), Language: pkg.Dart, Type: pkg.DartPubPkg, Metadata: pkg.DartPubspecLockEntry{ @@ -99,7 +99,7 @@ func TestParsePubspecLock(t *testing.T) { Name: "key_binder", Version: "1.11.20", PURL: "pkg:pub/key_binder@1.11.20?vcs_url=git%40github.com%3AWorkiva%2Fkey_binder.git%403f7b3a6350e73c7dcac45301c0e18fbd42af02f7", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/pubspec_locks/pubspec.lock")), + Locations: file.NewLocationSet(file.NewLocation("testdata/pubspec_locks/pubspec.lock")), Language: pkg.Dart, Type: pkg.DartPubPkg, Metadata: pkg.DartPubspecLockEntry{ @@ -122,13 +122,13 @@ func TestParsePubspecLock(t *testing.T) { func Test_corruptPubspecLock(t *testing.T) { pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/corrupt/pubspec.lock"). + FromFile(t, "testdata/corrupt/pubspec.lock"). WithError(). TestParser(t, parsePubspecLock) } func Test_missingSdkEntryPubspecLock(t *testing.T) { - fixture := "test-fixtures/missing-sdk/pubspec.lock" + fixture := "testdata/missing-sdk/pubspec.lock" fixtureLocationSet := file.NewLocationSet(file.NewLocation(fixture)) // SDK version is missing, so flutter version cannot be determined and @@ -155,7 +155,7 @@ func Test_missingSdkEntryPubspecLock(t *testing.T) { } func Test_invalidSdkEntryPubspecLock(t *testing.T) { - fixture := "test-fixtures/invalid-sdk/pubspec.lock" + fixture := "testdata/invalid-sdk/pubspec.lock" fixtureLocationSet := file.NewLocationSet(file.NewLocation(fixture)) // SDK version is invalid, so flutter version cannot be determined and diff --git a/syft/pkg/cataloger/dart/parse_pubspec_test.go b/syft/pkg/cataloger/dart/parse_pubspec_test.go index 4ba3b5c23..11c28c885 100644 --- a/syft/pkg/cataloger/dart/parse_pubspec_test.go +++ b/syft/pkg/cataloger/dart/parse_pubspec_test.go @@ -18,13 +18,13 @@ func TestParsePubspec(t *testing.T) { }{ { name: "_macros", - fixture: "test-fixtures/pubspecs/macros.pubspec.yaml", + fixture: "testdata/pubspecs/macros.pubspec.yaml", expectedPackages: []pkg.Package{ { Name: "_macros", Version: "0.3.2", PURL: "pkg:pub/_macros@0.3.2", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/pubspecs/macros.pubspec.yaml")), + Locations: file.NewLocationSet(file.NewLocation("testdata/pubspecs/macros.pubspec.yaml")), Language: pkg.Dart, Type: pkg.DartPubPkg, Metadata: pkg.DartPubspec{ @@ -40,13 +40,13 @@ func TestParsePubspec(t *testing.T) { }, { name: "_macros", - fixture: "test-fixtures/pubspecs/appainter.pubspec.yaml", + fixture: "testdata/pubspecs/appainter.pubspec.yaml", expectedPackages: []pkg.Package{ { Name: "appainter", Version: "2.4.8", PURL: "pkg:pub/appainter@2.4.8", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/pubspecs/appainter.pubspec.yaml")), + Locations: file.NewLocationSet(file.NewLocation("testdata/pubspecs/appainter.pubspec.yaml")), Language: pkg.Dart, Type: pkg.DartPubPkg, Metadata: pkg.DartPubspec{ diff --git a/syft/pkg/cataloger/dart/test-fixtures/corrupt/pubspec.lock b/syft/pkg/cataloger/dart/testdata/corrupt/pubspec.lock similarity index 100% rename from syft/pkg/cataloger/dart/test-fixtures/corrupt/pubspec.lock rename to syft/pkg/cataloger/dart/testdata/corrupt/pubspec.lock diff --git a/syft/pkg/cataloger/dart/test-fixtures/glob-paths/lock/src/pubspec.lock b/syft/pkg/cataloger/dart/testdata/glob-paths/lock/src/pubspec.lock similarity index 100% rename from syft/pkg/cataloger/dart/test-fixtures/glob-paths/lock/src/pubspec.lock rename to syft/pkg/cataloger/dart/testdata/glob-paths/lock/src/pubspec.lock diff --git a/syft/pkg/cataloger/dart/test-fixtures/glob-paths/spec/pubspec.yaml b/syft/pkg/cataloger/dart/testdata/glob-paths/spec/pubspec.yaml similarity index 100% rename from syft/pkg/cataloger/dart/test-fixtures/glob-paths/spec/pubspec.yaml rename to syft/pkg/cataloger/dart/testdata/glob-paths/spec/pubspec.yaml diff --git a/syft/pkg/cataloger/dart/test-fixtures/glob-paths/spec/pubspec.yml b/syft/pkg/cataloger/dart/testdata/glob-paths/spec/pubspec.yml similarity index 100% rename from syft/pkg/cataloger/dart/test-fixtures/glob-paths/spec/pubspec.yml rename to syft/pkg/cataloger/dart/testdata/glob-paths/spec/pubspec.yml diff --git a/syft/pkg/cataloger/dart/test-fixtures/invalid-sdk/pubspec.lock b/syft/pkg/cataloger/dart/testdata/invalid-sdk/pubspec.lock similarity index 100% rename from syft/pkg/cataloger/dart/test-fixtures/invalid-sdk/pubspec.lock rename to syft/pkg/cataloger/dart/testdata/invalid-sdk/pubspec.lock diff --git a/syft/pkg/cataloger/dart/test-fixtures/missing-sdk/pubspec.lock b/syft/pkg/cataloger/dart/testdata/missing-sdk/pubspec.lock similarity index 100% rename from syft/pkg/cataloger/dart/test-fixtures/missing-sdk/pubspec.lock rename to syft/pkg/cataloger/dart/testdata/missing-sdk/pubspec.lock diff --git a/syft/pkg/cataloger/dart/test-fixtures/pubspec_locks/pubspec.lock b/syft/pkg/cataloger/dart/testdata/pubspec_locks/pubspec.lock similarity index 100% rename from syft/pkg/cataloger/dart/test-fixtures/pubspec_locks/pubspec.lock rename to syft/pkg/cataloger/dart/testdata/pubspec_locks/pubspec.lock diff --git a/syft/pkg/cataloger/dart/test-fixtures/pubspecs/appainter.pubspec.yaml b/syft/pkg/cataloger/dart/testdata/pubspecs/appainter.pubspec.yaml similarity index 100% rename from syft/pkg/cataloger/dart/test-fixtures/pubspecs/appainter.pubspec.yaml rename to syft/pkg/cataloger/dart/testdata/pubspecs/appainter.pubspec.yaml diff --git a/syft/pkg/cataloger/dart/test-fixtures/pubspecs/macros.pubspec.yaml b/syft/pkg/cataloger/dart/testdata/pubspecs/macros.pubspec.yaml similarity index 100% rename from syft/pkg/cataloger/dart/test-fixtures/pubspecs/macros.pubspec.yaml rename to syft/pkg/cataloger/dart/testdata/pubspecs/macros.pubspec.yaml diff --git a/syft/pkg/cataloger/debian/cataloger_test.go b/syft/pkg/cataloger/debian/cataloger_test.go index 02bd23c9e..4d5deb9fb 100644 --- a/syft/pkg/cataloger/debian/cataloger_test.go +++ b/syft/pkg/cataloger/debian/cataloger_test.go @@ -176,7 +176,7 @@ func Test_CatalogerRelationships(t *testing.T) { }{ { name: "relationships for coreutils", - fixture: "test-fixtures/var/lib/dpkg/status.d/coreutils-relationships", + fixture: "testdata/var/lib/dpkg/status.d/coreutils-relationships", wantRelationships: map[string][]string{ "coreutils": {"libacl1", "libattr1", "libc6", "libgmp10", "libselinux1"}, "libacl1": {"libc6"}, @@ -190,7 +190,7 @@ func Test_CatalogerRelationships(t *testing.T) { }, { name: "relationships from dpkg example docs", - fixture: "test-fixtures/var/lib/dpkg/status.d/doc-examples", + fixture: "testdata/var/lib/dpkg/status.d/doc-examples", wantRelationships: map[string][]string{ "made-up-package-1": {"gnumach-dev", "hurd-dev", "kernel-headers-2.2.10"}, "made-up-package-2": {"liblua5.1-dev", "libluajit5.1-dev"}, @@ -206,7 +206,7 @@ func Test_CatalogerRelationships(t *testing.T) { }, { name: "relationships for libpam-runtime", - fixture: "test-fixtures/var/lib/dpkg/status.d/libpam-runtime", + fixture: "testdata/var/lib/dpkg/status.d/libpam-runtime", wantRelationships: map[string][]string{ "libpam-runtime": {"cdebconf", "debconf-2.0", "debconf1", "debconf2", "libpam-modules"}, }, @@ -298,7 +298,7 @@ func TestCataloger_Globs(t *testing.T) { }{ { name: "obtain db status files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "usr/lib/dpkg/status", "var/lib/dpkg/status", diff --git a/syft/pkg/cataloger/debian/parse_copyright_test.go b/syft/pkg/cataloger/debian/parse_copyright_test.go index e16929496..dca0188ca 100644 --- a/syft/pkg/cataloger/debian/parse_copyright_test.go +++ b/syft/pkg/cataloger/debian/parse_copyright_test.go @@ -14,37 +14,37 @@ func TestParseLicensesFromCopyright(t *testing.T) { expected []string }{ { - fixture: "test-fixtures/copyright/libc6", + fixture: "testdata/copyright/libc6", // note: there are other licenses in this file that are not matched --we don't do full text license identification yet expected: []string{"GPL-2", "LGPL-2.1"}, }, { - fixture: "test-fixtures/copyright/trilicense", + fixture: "testdata/copyright/trilicense", expected: []string{"GPL-2", "LGPL-2.1", "MPL-1.1"}, }, { - fixture: "test-fixtures/copyright/liblzma5", + fixture: "testdata/copyright/liblzma5", expected: []string{"Autoconf", "GPL-2", "GPL-2+", "GPL-3", "LGPL-2", "LGPL-2.1", "LGPL-2.1+", "PD", "PD-debian", "config-h", "noderivs", "permissive-fsf", "permissive-nowarranty", "probably-PD"}, }, { - fixture: "test-fixtures/copyright/libaudit-common", + fixture: "testdata/copyright/libaudit-common", expected: []string{"GPL-1", "GPL-2", "LGPL-2.1"}, }, { - fixture: "test-fixtures/copyright/python", + fixture: "testdata/copyright/python", // note: this should not capture #, Permission, This, see ... however it's not clear how to fix this (this is probably good enough) expected: []string{"#", "Apache", "Apache-2", "Apache-2.0", "Expat", "GPL-2", "ISC", "LGPL-2.1+", "PSF-2", "Permission", "Python", "This", "see"}, }, { - fixture: "test-fixtures/copyright/cuda", + fixture: "testdata/copyright/cuda", expected: []string{"NVIDIA Software License Agreement and CUDA Supplement to Software License Agreement"}, }, { - fixture: "test-fixtures/copyright/dev-kit", + fixture: "testdata/copyright/dev-kit", expected: []string{"LICENSE AGREEMENT FOR NVIDIA SOFTWARE DEVELOPMENT KITS"}, }, { - fixture: "test-fixtures/copyright/microsoft", + fixture: "testdata/copyright/microsoft", expected: []string{"LICENSE AGREEMENT FOR MICROSOFT PRODUCTS"}, }, } diff --git a/syft/pkg/cataloger/debian/parse_dpkg_db_test.go b/syft/pkg/cataloger/debian/parse_dpkg_db_test.go index c0659a0e0..49851d596 100644 --- a/syft/pkg/cataloger/debian/parse_dpkg_db_test.go +++ b/syft/pkg/cataloger/debian/parse_dpkg_db_test.go @@ -26,7 +26,7 @@ func Test_parseDpkgStatus(t *testing.T) { }{ { name: "single package", - fixturePath: "test-fixtures/var/lib/dpkg/status.d/single", + fixturePath: "testdata/var/lib/dpkg/status.d/single", expected: []pkg.DpkgDBEntry{ { Package: "apt", @@ -100,7 +100,7 @@ func Test_parseDpkgStatus(t *testing.T) { }, { name: "single package with installed size", - fixturePath: "test-fixtures/var/lib/dpkg/status.d/installed-size-4KB", + fixturePath: "testdata/var/lib/dpkg/status.d/installed-size-4KB", expected: []pkg.DpkgDBEntry{ { Package: "apt", @@ -141,7 +141,7 @@ func Test_parseDpkgStatus(t *testing.T) { }, { name: "multiple entries", - fixturePath: "test-fixtures/var/lib/dpkg/status.d/multiple", + fixturePath: "testdata/var/lib/dpkg/status.d/multiple", expected: []pkg.DpkgDBEntry{ { Package: "no-version", @@ -239,7 +239,7 @@ func Test_parseDpkgStatus(t *testing.T) { }, { name: "deinstall status packages are ignored", - fixturePath: "test-fixtures/var/lib/dpkg/status.d/deinstall", + fixturePath: "testdata/var/lib/dpkg/status.d/deinstall", expected: []pkg.DpkgDBEntry{ { Package: "linux-image-6.14.0-1012-aws", @@ -289,7 +289,7 @@ func Test_parseDpkgStatus(t *testing.T) { } func Test_corruptEntry(t *testing.T) { - f, err := os.Open("test-fixtures/var/lib/dpkg/status.d/corrupt") + f, err := os.Open("testdata/var/lib/dpkg/status.d/corrupt") require.NoError(t, err) t.Cleanup(func() { require.NoError(t, f.Close()) }) diff --git a/syft/pkg/cataloger/debian/parse_dpkg_info_files_test.go b/syft/pkg/cataloger/debian/parse_dpkg_info_files_test.go index 88ace2330..90aafd904 100644 --- a/syft/pkg/cataloger/debian/parse_dpkg_info_files_test.go +++ b/syft/pkg/cataloger/debian/parse_dpkg_info_files_test.go @@ -17,7 +17,7 @@ func TestMD5SumInfoParsing(t *testing.T) { expected []pkg.DpkgFileRecord }{ { - fixture: "test-fixtures/info/zlib1g.md5sums", + fixture: "testdata/info/zlib1g.md5sums", expected: []pkg.DpkgFileRecord{ {Path: "/lib/x86_64-linux-gnu/libz.so.1.2.11", Digest: &file.Digest{ Algorithm: "md5", @@ -61,7 +61,7 @@ func TestConffileInfoParsing(t *testing.T) { expected []pkg.DpkgFileRecord }{ { - fixture: "test-fixtures/info/util-linux.conffiles", + fixture: "testdata/info/util-linux.conffiles", expected: []pkg.DpkgFileRecord{ {Path: "/etc/default/hwclock", IsConfigFile: true}, {Path: "/etc/init.d/hwclock.sh", IsConfigFile: true}, diff --git a/syft/pkg/cataloger/debian/test-fixtures/copyright/cuda b/syft/pkg/cataloger/debian/testdata/copyright/cuda similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/copyright/cuda rename to syft/pkg/cataloger/debian/testdata/copyright/cuda diff --git a/syft/pkg/cataloger/debian/test-fixtures/copyright/dev-kit b/syft/pkg/cataloger/debian/testdata/copyright/dev-kit similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/copyright/dev-kit rename to syft/pkg/cataloger/debian/testdata/copyright/dev-kit diff --git a/syft/pkg/cataloger/debian/test-fixtures/copyright/libaudit-common b/syft/pkg/cataloger/debian/testdata/copyright/libaudit-common similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/copyright/libaudit-common rename to syft/pkg/cataloger/debian/testdata/copyright/libaudit-common diff --git a/syft/pkg/cataloger/debian/test-fixtures/copyright/libc6 b/syft/pkg/cataloger/debian/testdata/copyright/libc6 similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/copyright/libc6 rename to syft/pkg/cataloger/debian/testdata/copyright/libc6 diff --git a/syft/pkg/cataloger/debian/test-fixtures/copyright/liblzma5 b/syft/pkg/cataloger/debian/testdata/copyright/liblzma5 similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/copyright/liblzma5 rename to syft/pkg/cataloger/debian/testdata/copyright/liblzma5 diff --git a/syft/pkg/cataloger/debian/test-fixtures/copyright/microsoft b/syft/pkg/cataloger/debian/testdata/copyright/microsoft similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/copyright/microsoft rename to syft/pkg/cataloger/debian/testdata/copyright/microsoft diff --git a/syft/pkg/cataloger/debian/test-fixtures/copyright/python b/syft/pkg/cataloger/debian/testdata/copyright/python similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/copyright/python rename to syft/pkg/cataloger/debian/testdata/copyright/python diff --git a/syft/pkg/cataloger/debian/test-fixtures/copyright/trilicense b/syft/pkg/cataloger/debian/testdata/copyright/trilicense similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/copyright/trilicense rename to syft/pkg/cataloger/debian/testdata/copyright/trilicense diff --git a/syft/pkg/cataloger/debian/test-fixtures/glob-paths/usr/lib/dpkg/info/libpam-runtime.conffiles b/syft/pkg/cataloger/debian/testdata/glob-paths/usr/lib/dpkg/info/libpam-runtime.conffiles similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/glob-paths/usr/lib/dpkg/info/libpam-runtime.conffiles rename to syft/pkg/cataloger/debian/testdata/glob-paths/usr/lib/dpkg/info/libpam-runtime.conffiles diff --git a/syft/pkg/cataloger/debian/test-fixtures/glob-paths/usr/lib/dpkg/info/libpam-runtime.md5sums b/syft/pkg/cataloger/debian/testdata/glob-paths/usr/lib/dpkg/info/libpam-runtime.md5sums similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/glob-paths/usr/lib/dpkg/info/libpam-runtime.md5sums rename to syft/pkg/cataloger/debian/testdata/glob-paths/usr/lib/dpkg/info/libpam-runtime.md5sums diff --git a/syft/pkg/cataloger/debian/test-fixtures/glob-paths/usr/lib/dpkg/info/libpam-runtime.preinst b/syft/pkg/cataloger/debian/testdata/glob-paths/usr/lib/dpkg/info/libpam-runtime.preinst similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/glob-paths/usr/lib/dpkg/info/libpam-runtime.preinst rename to syft/pkg/cataloger/debian/testdata/glob-paths/usr/lib/dpkg/info/libpam-runtime.preinst diff --git a/syft/pkg/cataloger/debian/test-fixtures/glob-paths/usr/lib/dpkg/status b/syft/pkg/cataloger/debian/testdata/glob-paths/usr/lib/dpkg/status similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/glob-paths/usr/lib/dpkg/status rename to syft/pkg/cataloger/debian/testdata/glob-paths/usr/lib/dpkg/status diff --git a/syft/pkg/cataloger/debian/test-fixtures/glob-paths/usr/lib/dpkg/status.d/pkg-1.0 b/syft/pkg/cataloger/debian/testdata/glob-paths/usr/lib/dpkg/status.d/pkg-1.0 similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/glob-paths/usr/lib/dpkg/status.d/pkg-1.0 rename to syft/pkg/cataloger/debian/testdata/glob-paths/usr/lib/dpkg/status.d/pkg-1.0 diff --git a/syft/pkg/cataloger/debian/test-fixtures/glob-paths/usr/lib/opkg/info/pkg-1.0.control b/syft/pkg/cataloger/debian/testdata/glob-paths/usr/lib/opkg/info/pkg-1.0.control similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/glob-paths/usr/lib/opkg/info/pkg-1.0.control rename to syft/pkg/cataloger/debian/testdata/glob-paths/usr/lib/opkg/info/pkg-1.0.control diff --git a/syft/pkg/cataloger/debian/test-fixtures/glob-paths/usr/lib/opkg/status b/syft/pkg/cataloger/debian/testdata/glob-paths/usr/lib/opkg/status similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/glob-paths/usr/lib/opkg/status rename to syft/pkg/cataloger/debian/testdata/glob-paths/usr/lib/opkg/status diff --git a/syft/pkg/cataloger/debian/test-fixtures/glob-paths/usr/share/doc/libpam-runtime/copyright b/syft/pkg/cataloger/debian/testdata/glob-paths/usr/share/doc/libpam-runtime/copyright similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/glob-paths/usr/share/doc/libpam-runtime/copyright rename to syft/pkg/cataloger/debian/testdata/glob-paths/usr/share/doc/libpam-runtime/copyright diff --git a/syft/pkg/cataloger/debian/test-fixtures/glob-paths/var/lib/dpkg/status b/syft/pkg/cataloger/debian/testdata/glob-paths/var/lib/dpkg/status similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/glob-paths/var/lib/dpkg/status rename to syft/pkg/cataloger/debian/testdata/glob-paths/var/lib/dpkg/status diff --git a/syft/pkg/cataloger/debian/test-fixtures/glob-paths/var/lib/dpkg/status.d/pkg-1.0 b/syft/pkg/cataloger/debian/testdata/glob-paths/var/lib/dpkg/status.d/pkg-1.0 similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/glob-paths/var/lib/dpkg/status.d/pkg-1.0 rename to syft/pkg/cataloger/debian/testdata/glob-paths/var/lib/dpkg/status.d/pkg-1.0 diff --git a/syft/pkg/cataloger/debian/test-fixtures/image-distroless-deb/Dockerfile b/syft/pkg/cataloger/debian/testdata/image-distroless-deb/Dockerfile similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/image-distroless-deb/Dockerfile rename to syft/pkg/cataloger/debian/testdata/image-distroless-deb/Dockerfile diff --git a/syft/pkg/cataloger/debian/test-fixtures/image-distroless-deb/usr/share/doc/libsqlite3-0/copyright b/syft/pkg/cataloger/debian/testdata/image-distroless-deb/usr/share/doc/libsqlite3-0/copyright similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/image-distroless-deb/usr/share/doc/libsqlite3-0/copyright rename to syft/pkg/cataloger/debian/testdata/image-distroless-deb/usr/share/doc/libsqlite3-0/copyright diff --git a/syft/pkg/cataloger/debian/test-fixtures/image-distroless-deb/var/lib/dpkg/status.d/libsqlite3-0 b/syft/pkg/cataloger/debian/testdata/image-distroless-deb/var/lib/dpkg/status.d/libsqlite3-0 similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/image-distroless-deb/var/lib/dpkg/status.d/libsqlite3-0 rename to syft/pkg/cataloger/debian/testdata/image-distroless-deb/var/lib/dpkg/status.d/libsqlite3-0 diff --git a/syft/pkg/cataloger/debian/test-fixtures/image-distroless-deb/var/lib/dpkg/status.d/libsqlite3-0.md5sums b/syft/pkg/cataloger/debian/testdata/image-distroless-deb/var/lib/dpkg/status.d/libsqlite3-0.md5sums similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/image-distroless-deb/var/lib/dpkg/status.d/libsqlite3-0.md5sums rename to syft/pkg/cataloger/debian/testdata/image-distroless-deb/var/lib/dpkg/status.d/libsqlite3-0.md5sums diff --git a/syft/pkg/cataloger/debian/test-fixtures/image-distroless-deb/var/lib/dpkg/status.d/libsqlite3-0.preinst b/syft/pkg/cataloger/debian/testdata/image-distroless-deb/var/lib/dpkg/status.d/libsqlite3-0.preinst similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/image-distroless-deb/var/lib/dpkg/status.d/libsqlite3-0.preinst rename to syft/pkg/cataloger/debian/testdata/image-distroless-deb/var/lib/dpkg/status.d/libsqlite3-0.preinst diff --git a/syft/pkg/cataloger/debian/test-fixtures/image-dpkg/Dockerfile b/syft/pkg/cataloger/debian/testdata/image-dpkg/Dockerfile similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/image-dpkg/Dockerfile rename to syft/pkg/cataloger/debian/testdata/image-dpkg/Dockerfile diff --git a/syft/pkg/cataloger/debian/test-fixtures/image-dpkg/etc/os-release b/syft/pkg/cataloger/debian/testdata/image-dpkg/etc/os-release similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/image-dpkg/etc/os-release rename to syft/pkg/cataloger/debian/testdata/image-dpkg/etc/os-release diff --git a/syft/pkg/cataloger/debian/test-fixtures/image-dpkg/usr/share/doc/libpam-runtime/copyright b/syft/pkg/cataloger/debian/testdata/image-dpkg/usr/share/doc/libpam-runtime/copyright similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/image-dpkg/usr/share/doc/libpam-runtime/copyright rename to syft/pkg/cataloger/debian/testdata/image-dpkg/usr/share/doc/libpam-runtime/copyright diff --git a/syft/pkg/cataloger/debian/test-fixtures/image-dpkg/var/lib/dpkg/info/libpam-runtime.conffiles b/syft/pkg/cataloger/debian/testdata/image-dpkg/var/lib/dpkg/info/libpam-runtime.conffiles similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/image-dpkg/var/lib/dpkg/info/libpam-runtime.conffiles rename to syft/pkg/cataloger/debian/testdata/image-dpkg/var/lib/dpkg/info/libpam-runtime.conffiles diff --git a/syft/pkg/cataloger/debian/test-fixtures/image-dpkg/var/lib/dpkg/info/libpam-runtime.md5sums b/syft/pkg/cataloger/debian/testdata/image-dpkg/var/lib/dpkg/info/libpam-runtime.md5sums similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/image-dpkg/var/lib/dpkg/info/libpam-runtime.md5sums rename to syft/pkg/cataloger/debian/testdata/image-dpkg/var/lib/dpkg/info/libpam-runtime.md5sums diff --git a/syft/pkg/cataloger/debian/test-fixtures/image-dpkg/var/lib/dpkg/info/libpam-runtime.preinst b/syft/pkg/cataloger/debian/testdata/image-dpkg/var/lib/dpkg/info/libpam-runtime.preinst similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/image-dpkg/var/lib/dpkg/info/libpam-runtime.preinst rename to syft/pkg/cataloger/debian/testdata/image-dpkg/var/lib/dpkg/info/libpam-runtime.preinst diff --git a/syft/pkg/cataloger/debian/test-fixtures/image-dpkg/var/lib/dpkg/status b/syft/pkg/cataloger/debian/testdata/image-dpkg/var/lib/dpkg/status similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/image-dpkg/var/lib/dpkg/status rename to syft/pkg/cataloger/debian/testdata/image-dpkg/var/lib/dpkg/status diff --git a/syft/pkg/cataloger/debian/test-fixtures/image-single-dpkg/Dockerfile b/syft/pkg/cataloger/debian/testdata/image-single-dpkg/Dockerfile similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/image-single-dpkg/Dockerfile rename to syft/pkg/cataloger/debian/testdata/image-single-dpkg/Dockerfile diff --git a/syft/pkg/cataloger/debian/test-fixtures/info/util-linux.conffiles b/syft/pkg/cataloger/debian/testdata/info/util-linux.conffiles similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/info/util-linux.conffiles rename to syft/pkg/cataloger/debian/testdata/info/util-linux.conffiles diff --git a/syft/pkg/cataloger/debian/test-fixtures/info/zlib1g.md5sums b/syft/pkg/cataloger/debian/testdata/info/zlib1g.md5sums similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/info/zlib1g.md5sums rename to syft/pkg/cataloger/debian/testdata/info/zlib1g.md5sums diff --git a/syft/pkg/cataloger/debian/test-fixtures/var/lib/dpkg/status.d/coreutils-relationships b/syft/pkg/cataloger/debian/testdata/var/lib/dpkg/status.d/coreutils-relationships similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/var/lib/dpkg/status.d/coreutils-relationships rename to syft/pkg/cataloger/debian/testdata/var/lib/dpkg/status.d/coreutils-relationships diff --git a/syft/pkg/cataloger/debian/test-fixtures/var/lib/dpkg/status.d/corrupt b/syft/pkg/cataloger/debian/testdata/var/lib/dpkg/status.d/corrupt similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/var/lib/dpkg/status.d/corrupt rename to syft/pkg/cataloger/debian/testdata/var/lib/dpkg/status.d/corrupt diff --git a/syft/pkg/cataloger/debian/test-fixtures/var/lib/dpkg/status.d/deinstall b/syft/pkg/cataloger/debian/testdata/var/lib/dpkg/status.d/deinstall similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/var/lib/dpkg/status.d/deinstall rename to syft/pkg/cataloger/debian/testdata/var/lib/dpkg/status.d/deinstall diff --git a/syft/pkg/cataloger/debian/test-fixtures/var/lib/dpkg/status.d/doc-examples b/syft/pkg/cataloger/debian/testdata/var/lib/dpkg/status.d/doc-examples similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/var/lib/dpkg/status.d/doc-examples rename to syft/pkg/cataloger/debian/testdata/var/lib/dpkg/status.d/doc-examples diff --git a/syft/pkg/cataloger/debian/test-fixtures/var/lib/dpkg/status.d/empty b/syft/pkg/cataloger/debian/testdata/var/lib/dpkg/status.d/empty similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/var/lib/dpkg/status.d/empty rename to syft/pkg/cataloger/debian/testdata/var/lib/dpkg/status.d/empty diff --git a/syft/pkg/cataloger/debian/test-fixtures/var/lib/dpkg/status.d/installed-size-4KB b/syft/pkg/cataloger/debian/testdata/var/lib/dpkg/status.d/installed-size-4KB similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/var/lib/dpkg/status.d/installed-size-4KB rename to syft/pkg/cataloger/debian/testdata/var/lib/dpkg/status.d/installed-size-4KB diff --git a/syft/pkg/cataloger/debian/test-fixtures/var/lib/dpkg/status.d/libpam-runtime b/syft/pkg/cataloger/debian/testdata/var/lib/dpkg/status.d/libpam-runtime similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/var/lib/dpkg/status.d/libpam-runtime rename to syft/pkg/cataloger/debian/testdata/var/lib/dpkg/status.d/libpam-runtime diff --git a/syft/pkg/cataloger/debian/test-fixtures/var/lib/dpkg/status.d/multiple b/syft/pkg/cataloger/debian/testdata/var/lib/dpkg/status.d/multiple similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/var/lib/dpkg/status.d/multiple rename to syft/pkg/cataloger/debian/testdata/var/lib/dpkg/status.d/multiple diff --git a/syft/pkg/cataloger/debian/test-fixtures/var/lib/dpkg/status.d/single b/syft/pkg/cataloger/debian/testdata/var/lib/dpkg/status.d/single similarity index 100% rename from syft/pkg/cataloger/debian/test-fixtures/var/lib/dpkg/status.d/single rename to syft/pkg/cataloger/debian/testdata/var/lib/dpkg/status.d/single diff --git a/syft/pkg/cataloger/dotnet/cataloger_test.go b/syft/pkg/cataloger/dotnet/cataloger_test.go index 3db3122ef..83f481115 100644 --- a/syft/pkg/cataloger/dotnet/cataloger_test.go +++ b/syft/pkg/cataloger/dotnet/cataloger_test.go @@ -21,7 +21,7 @@ func TestCataloger_Globs(t *testing.T) { }{ { name: "obtain deps.json files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", cataloger: NewDotnetDepsCataloger(), expected: []string{ "src/something.deps.json", @@ -29,7 +29,7 @@ func TestCataloger_Globs(t *testing.T) { }, { name: "obtain portable executable files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", cataloger: NewDotnetPortableExecutableCataloger(), expected: []string{ "src/something.dll", @@ -38,7 +38,7 @@ func TestCataloger_Globs(t *testing.T) { }, { name: "obtain combined files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", cataloger: NewDotnetDepsBinaryCataloger(DefaultCatalogerConfig()), expected: []string{ "src/something.deps.json", @@ -1365,20 +1365,20 @@ func TestDotnetDepsCataloger_regressions(t *testing.T) { func Test_corruptDotnetPE(t *testing.T) { pkgtest.NewCatalogTester(). - FromDirectory(t, "test-fixtures/glob-paths/src"). + FromDirectory(t, "testdata/glob-paths/src"). Expects(nil, nil). // we shouldn't find packages nor error out TestCataloger(t, NewDotnetPortableExecutableCataloger()) } func Test_corruptDotnetDeps(t *testing.T) { pkgtest.NewCatalogTester(). - FromDirectory(t, "test-fixtures/glob-paths/src"). + FromDirectory(t, "testdata/glob-paths/src"). Expects(nil, nil). // we shouldn't find packages nor error out TestCataloger(t, NewDotnetDepsCataloger()) } func TestParseDotnetDeps(t *testing.T) { - fixture := "test-fixtures/dir-example-1" + fixture := "testdata/dir-example-1" fixtureLocationSet := file.NewLocationSet(file.NewLocation("TestLibrary.deps.json")) rootPkg := pkg.Package{ Name: "TestLibrary", diff --git a/syft/pkg/cataloger/dotnet/parse_packages_lock_test.go b/syft/pkg/cataloger/dotnet/parse_packages_lock_test.go index 6059e28d8..4d8a2c2d7 100644 --- a/syft/pkg/cataloger/dotnet/parse_packages_lock_test.go +++ b/syft/pkg/cataloger/dotnet/parse_packages_lock_test.go @@ -11,13 +11,13 @@ import ( func Test_corruptDotnetPackagesLock(t *testing.T) { pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/glob-paths/src/packages.lock.json"). + FromFile(t, "testdata/glob-paths/src/packages.lock.json"). WithError(). TestParser(t, parseDotnetPackagesLock) } func TestParseDotnetPackagesLock(t *testing.T) { - fixture := "test-fixtures/packages.lock.json" + fixture := "testdata/packages.lock.json" fixtureLocationSet := file.NewLocationSet(file.NewLocation(fixture)) autoMapperPkg := pkg.Package{ diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/.gitignore b/syft/pkg/cataloger/dotnet/testdata/.gitignore similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/.gitignore rename to syft/pkg/cataloger/dotnet/testdata/.gitignore diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/Makefile b/syft/pkg/cataloger/dotnet/testdata/Makefile similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/Makefile rename to syft/pkg/cataloger/dotnet/testdata/Makefile diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/dir-example-1/TestLibrary.deps.json b/syft/pkg/cataloger/dotnet/testdata/dir-example-1/TestLibrary.deps.json similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/dir-example-1/TestLibrary.deps.json rename to syft/pkg/cataloger/dotnet/testdata/dir-example-1/TestLibrary.deps.json diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/glob-paths/src/packages.lock.json b/syft/pkg/cataloger/dotnet/testdata/glob-paths/src/packages.lock.json similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/glob-paths/src/packages.lock.json rename to syft/pkg/cataloger/dotnet/testdata/glob-paths/src/packages.lock.json diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/glob-paths/src/something.deps.json b/syft/pkg/cataloger/dotnet/testdata/glob-paths/src/something.deps.json similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/glob-paths/src/something.deps.json rename to syft/pkg/cataloger/dotnet/testdata/glob-paths/src/something.deps.json diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/glob-paths/src/something.dll b/syft/pkg/cataloger/dotnet/testdata/glob-paths/src/something.dll similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/glob-paths/src/something.dll rename to syft/pkg/cataloger/dotnet/testdata/glob-paths/src/something.dll diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/glob-paths/src/something.exe b/syft/pkg/cataloger/dotnet/testdata/glob-paths/src/something.exe similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/glob-paths/src/something.exe rename to syft/pkg/cataloger/dotnet/testdata/glob-paths/src/something.exe diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net2-app/.gitignore b/syft/pkg/cataloger/dotnet/testdata/image-net2-app/.gitignore similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net2-app/.gitignore rename to syft/pkg/cataloger/dotnet/testdata/image-net2-app/.gitignore diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net2-app/Dockerfile b/syft/pkg/cataloger/dotnet/testdata/image-net2-app/Dockerfile similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net2-app/Dockerfile rename to syft/pkg/cataloger/dotnet/testdata/image-net2-app/Dockerfile diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net2-app/src/Program.cs b/syft/pkg/cataloger/dotnet/testdata/image-net2-app/src/Program.cs similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net2-app/src/Program.cs rename to syft/pkg/cataloger/dotnet/testdata/image-net2-app/src/Program.cs diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net2-app/src/helloworld.csproj b/syft/pkg/cataloger/dotnet/testdata/image-net2-app/src/helloworld.csproj similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net2-app/src/helloworld.csproj rename to syft/pkg/cataloger/dotnet/testdata/image-net2-app/src/helloworld.csproj diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net6-asp-libman/.dockerignore b/syft/pkg/cataloger/dotnet/testdata/image-net6-asp-libman/.dockerignore similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net6-asp-libman/.dockerignore rename to syft/pkg/cataloger/dotnet/testdata/image-net6-asp-libman/.dockerignore diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net6-asp-libman/.gitignore b/syft/pkg/cataloger/dotnet/testdata/image-net6-asp-libman/.gitignore similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net6-asp-libman/.gitignore rename to syft/pkg/cataloger/dotnet/testdata/image-net6-asp-libman/.gitignore diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net6-asp-libman/Dockerfile b/syft/pkg/cataloger/dotnet/testdata/image-net6-asp-libman/Dockerfile similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net6-asp-libman/Dockerfile rename to syft/pkg/cataloger/dotnet/testdata/image-net6-asp-libman/Dockerfile diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net6-asp-libman/src/.gitignore b/syft/pkg/cataloger/dotnet/testdata/image-net6-asp-libman/src/.gitignore similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net6-asp-libman/src/.gitignore rename to syft/pkg/cataloger/dotnet/testdata/image-net6-asp-libman/src/.gitignore diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net6-asp-libman/src/LibManSample.csproj b/syft/pkg/cataloger/dotnet/testdata/image-net6-asp-libman/src/LibManSample.csproj similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net6-asp-libman/src/LibManSample.csproj rename to syft/pkg/cataloger/dotnet/testdata/image-net6-asp-libman/src/LibManSample.csproj diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net6-asp-libman/src/Program.cs b/syft/pkg/cataloger/dotnet/testdata/image-net6-asp-libman/src/Program.cs similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net6-asp-libman/src/Program.cs rename to syft/pkg/cataloger/dotnet/testdata/image-net6-asp-libman/src/Program.cs diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net6-asp-libman/src/Startup.cs b/syft/pkg/cataloger/dotnet/testdata/image-net6-asp-libman/src/Startup.cs similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net6-asp-libman/src/Startup.cs rename to syft/pkg/cataloger/dotnet/testdata/image-net6-asp-libman/src/Startup.cs diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net6-asp-libman/src/libman.json b/syft/pkg/cataloger/dotnet/testdata/image-net6-asp-libman/src/libman.json similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net6-asp-libman/src/libman.json rename to syft/pkg/cataloger/dotnet/testdata/image-net6-asp-libman/src/libman.json diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net6-asp-libman/src/vendor/lodash.js b/syft/pkg/cataloger/dotnet/testdata/image-net6-asp-libman/src/vendor/lodash.js similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net6-asp-libman/src/vendor/lodash.js rename to syft/pkg/cataloger/dotnet/testdata/image-net6-asp-libman/src/vendor/lodash.js diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net6-asp-libman/src/vendor/lodash.min.js b/syft/pkg/cataloger/dotnet/testdata/image-net6-asp-libman/src/vendor/lodash.min.js similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net6-asp-libman/src/vendor/lodash.min.js rename to syft/pkg/cataloger/dotnet/testdata/image-net6-asp-libman/src/vendor/lodash.min.js diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-no-depjson/.gitignore b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-no-depjson/.gitignore similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-no-depjson/.gitignore rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-no-depjson/.gitignore diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-no-depjson/Dockerfile b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-no-depjson/Dockerfile similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-no-depjson/Dockerfile rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-no-depjson/Dockerfile diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-no-depjson/src/Program.cs b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-no-depjson/src/Program.cs similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-no-depjson/src/Program.cs rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-no-depjson/src/Program.cs diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-no-depjson/src/dotnetapp.csproj b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-no-depjson/src/dotnetapp.csproj similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-no-depjson/src/dotnetapp.csproj rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-no-depjson/src/dotnetapp.csproj diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-no-depjson/src/packages.lock.json b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-no-depjson/src/packages.lock.json similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-no-depjson/src/packages.lock.json rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-no-depjson/src/packages.lock.json diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-self-contained/.gitignore b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-self-contained/.gitignore similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-self-contained/.gitignore rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-self-contained/.gitignore diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-self-contained/Dockerfile b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-self-contained/Dockerfile similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-self-contained/Dockerfile rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-self-contained/Dockerfile diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-self-contained/src/Program.cs b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-self-contained/src/Program.cs similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-self-contained/src/Program.cs rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-self-contained/src/Program.cs diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-self-contained/src/dotnetapp.csproj b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-self-contained/src/dotnetapp.csproj similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-self-contained/src/dotnetapp.csproj rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-self-contained/src/dotnetapp.csproj diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-self-contained/src/packages.lock.json b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-self-contained/src/packages.lock.json similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-self-contained/src/packages.lock.json rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-self-contained/src/packages.lock.json diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-single-file/.gitignore b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-single-file/.gitignore similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-single-file/.gitignore rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-single-file/.gitignore diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-single-file/Dockerfile b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-single-file/Dockerfile similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-single-file/Dockerfile rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-single-file/Dockerfile diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-single-file/src/Program.cs b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-single-file/src/Program.cs similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-single-file/src/Program.cs rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-single-file/src/Program.cs diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-single-file/src/dotnetapp.csproj b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-single-file/src/dotnetapp.csproj similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-single-file/src/dotnetapp.csproj rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-single-file/src/dotnetapp.csproj diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-single-file/src/packages.lock.json b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-single-file/src/packages.lock.json similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-single-file/src/packages.lock.json rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-single-file/src/packages.lock.json diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-with-runtime-nodepsjson/.gitignore b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-with-runtime-nodepsjson/.gitignore similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-with-runtime-nodepsjson/.gitignore rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-with-runtime-nodepsjson/.gitignore diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-with-runtime-nodepsjson/Dockerfile b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-with-runtime-nodepsjson/Dockerfile similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-with-runtime-nodepsjson/Dockerfile rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-with-runtime-nodepsjson/Dockerfile diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-with-runtime-nodepsjson/src/Program.cs b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-with-runtime-nodepsjson/src/Program.cs similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-with-runtime-nodepsjson/src/Program.cs rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-with-runtime-nodepsjson/src/Program.cs diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-with-runtime-nodepsjson/src/dotnetapp.csproj b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-with-runtime-nodepsjson/src/dotnetapp.csproj similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-with-runtime-nodepsjson/src/dotnetapp.csproj rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-with-runtime-nodepsjson/src/dotnetapp.csproj diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-with-runtime-nodepsjson/src/packages.lock.json b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-with-runtime-nodepsjson/src/packages.lock.json similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-with-runtime-nodepsjson/src/packages.lock.json rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-with-runtime-nodepsjson/src/packages.lock.json diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-with-runtime/.gitignore b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-with-runtime/.gitignore similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-with-runtime/.gitignore rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-with-runtime/.gitignore diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-with-runtime/Dockerfile b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-with-runtime/Dockerfile similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-with-runtime/Dockerfile rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-with-runtime/Dockerfile diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-with-runtime/src/Program.cs b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-with-runtime/src/Program.cs similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-with-runtime/src/Program.cs rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-with-runtime/src/Program.cs diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-with-runtime/src/dotnetapp.csproj b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-with-runtime/src/dotnetapp.csproj similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-with-runtime/src/dotnetapp.csproj rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-with-runtime/src/dotnetapp.csproj diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-with-runtime/src/packages.lock.json b/syft/pkg/cataloger/dotnet/testdata/image-net8-app-with-runtime/src/packages.lock.json similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app-with-runtime/src/packages.lock.json rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app-with-runtime/src/packages.lock.json diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app/.gitignore b/syft/pkg/cataloger/dotnet/testdata/image-net8-app/.gitignore similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app/.gitignore rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app/.gitignore diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app/Dockerfile b/syft/pkg/cataloger/dotnet/testdata/image-net8-app/Dockerfile similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app/Dockerfile rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app/Dockerfile diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app/src/Program.cs b/syft/pkg/cataloger/dotnet/testdata/image-net8-app/src/Program.cs similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app/src/Program.cs rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app/src/Program.cs diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app/src/dotnetapp.csproj b/syft/pkg/cataloger/dotnet/testdata/image-net8-app/src/dotnetapp.csproj similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app/src/dotnetapp.csproj rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app/src/dotnetapp.csproj diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app/src/packages.lock.json b/syft/pkg/cataloger/dotnet/testdata/image-net8-app/src/packages.lock.json similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-app/src/packages.lock.json rename to syft/pkg/cataloger/dotnet/testdata/image-net8-app/src/packages.lock.json diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-compile-target/.gitignore b/syft/pkg/cataloger/dotnet/testdata/image-net8-compile-target/.gitignore similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-compile-target/.gitignore rename to syft/pkg/cataloger/dotnet/testdata/image-net8-compile-target/.gitignore diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-compile-target/Dockerfile b/syft/pkg/cataloger/dotnet/testdata/image-net8-compile-target/Dockerfile similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-compile-target/Dockerfile rename to syft/pkg/cataloger/dotnet/testdata/image-net8-compile-target/Dockerfile diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-compile-target/src/Program.cs b/syft/pkg/cataloger/dotnet/testdata/image-net8-compile-target/src/Program.cs similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-compile-target/src/Program.cs rename to syft/pkg/cataloger/dotnet/testdata/image-net8-compile-target/src/Program.cs diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-compile-target/src/helloworld.csproj b/syft/pkg/cataloger/dotnet/testdata/image-net8-compile-target/src/helloworld.csproj similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-compile-target/src/helloworld.csproj rename to syft/pkg/cataloger/dotnet/testdata/image-net8-compile-target/src/helloworld.csproj diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-ilrepack/.gitignore b/syft/pkg/cataloger/dotnet/testdata/image-net8-ilrepack/.gitignore similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-ilrepack/.gitignore rename to syft/pkg/cataloger/dotnet/testdata/image-net8-ilrepack/.gitignore diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-ilrepack/Dockerfile b/syft/pkg/cataloger/dotnet/testdata/image-net8-ilrepack/Dockerfile similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-ilrepack/Dockerfile rename to syft/pkg/cataloger/dotnet/testdata/image-net8-ilrepack/Dockerfile diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-ilrepack/src/.gitignore b/syft/pkg/cataloger/dotnet/testdata/image-net8-ilrepack/src/.gitignore similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-ilrepack/src/.gitignore rename to syft/pkg/cataloger/dotnet/testdata/image-net8-ilrepack/src/.gitignore diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-ilrepack/src/Program.cs b/syft/pkg/cataloger/dotnet/testdata/image-net8-ilrepack/src/Program.cs similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-ilrepack/src/Program.cs rename to syft/pkg/cataloger/dotnet/testdata/image-net8-ilrepack/src/Program.cs diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-ilrepack/src/dotnetapp.csproj b/syft/pkg/cataloger/dotnet/testdata/image-net8-ilrepack/src/dotnetapp.csproj similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-ilrepack/src/dotnetapp.csproj rename to syft/pkg/cataloger/dotnet/testdata/image-net8-ilrepack/src/dotnetapp.csproj diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-privateassets/.gitignore b/syft/pkg/cataloger/dotnet/testdata/image-net8-privateassets/.gitignore similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-privateassets/.gitignore rename to syft/pkg/cataloger/dotnet/testdata/image-net8-privateassets/.gitignore diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-privateassets/Dockerfile b/syft/pkg/cataloger/dotnet/testdata/image-net8-privateassets/Dockerfile similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-privateassets/Dockerfile rename to syft/pkg/cataloger/dotnet/testdata/image-net8-privateassets/Dockerfile diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-privateassets/src/.gitignore b/syft/pkg/cataloger/dotnet/testdata/image-net8-privateassets/src/.gitignore similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-privateassets/src/.gitignore rename to syft/pkg/cataloger/dotnet/testdata/image-net8-privateassets/src/.gitignore diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-privateassets/src/Program.cs b/syft/pkg/cataloger/dotnet/testdata/image-net8-privateassets/src/Program.cs similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-privateassets/src/Program.cs rename to syft/pkg/cataloger/dotnet/testdata/image-net8-privateassets/src/Program.cs diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/image-net8-privateassets/src/dotnetapp.csproj b/syft/pkg/cataloger/dotnet/testdata/image-net8-privateassets/src/dotnetapp.csproj similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/image-net8-privateassets/src/dotnetapp.csproj rename to syft/pkg/cataloger/dotnet/testdata/image-net8-privateassets/src/dotnetapp.csproj diff --git a/syft/pkg/cataloger/dotnet/test-fixtures/packages.lock.json b/syft/pkg/cataloger/dotnet/testdata/packages.lock.json similarity index 100% rename from syft/pkg/cataloger/dotnet/test-fixtures/packages.lock.json rename to syft/pkg/cataloger/dotnet/testdata/packages.lock.json diff --git a/syft/pkg/cataloger/elixir/cataloger_test.go b/syft/pkg/cataloger/elixir/cataloger_test.go index 538da15a5..3f5fd6213 100644 --- a/syft/pkg/cataloger/elixir/cataloger_test.go +++ b/syft/pkg/cataloger/elixir/cataloger_test.go @@ -14,7 +14,7 @@ func TestCataloger_Globs(t *testing.T) { }{ { name: "obtain mix.lock files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "src/mix.lock", }, diff --git a/syft/pkg/cataloger/elixir/parse_mix_lock_test.go b/syft/pkg/cataloger/elixir/parse_mix_lock_test.go index a8e09e257..575620406 100644 --- a/syft/pkg/cataloger/elixir/parse_mix_lock_test.go +++ b/syft/pkg/cataloger/elixir/parse_mix_lock_test.go @@ -10,7 +10,7 @@ import ( ) func TestParseMixLock(t *testing.T) { - locations := file.NewLocationSet(file.NewLocation("test-fixtures/mix.lock")) + locations := file.NewLocationSet(file.NewLocation("testdata/mix.lock")) expected := []pkg.Package{ { Name: "castore", @@ -224,7 +224,7 @@ func TestParseMixLock(t *testing.T) { }, } - fixture := "test-fixtures/mix.lock" + fixture := "testdata/mix.lock" // TODO: relationships are not under test var expectedRelationships []artifact.Relationship diff --git a/syft/pkg/cataloger/elixir/test-fixtures/glob-paths/src/mix.lock b/syft/pkg/cataloger/elixir/testdata/glob-paths/src/mix.lock similarity index 100% rename from syft/pkg/cataloger/elixir/test-fixtures/glob-paths/src/mix.lock rename to syft/pkg/cataloger/elixir/testdata/glob-paths/src/mix.lock diff --git a/syft/pkg/cataloger/elixir/test-fixtures/mix.lock b/syft/pkg/cataloger/elixir/testdata/mix.lock similarity index 100% rename from syft/pkg/cataloger/elixir/test-fixtures/mix.lock rename to syft/pkg/cataloger/elixir/testdata/mix.lock diff --git a/syft/pkg/cataloger/erlang/cataloger_test.go b/syft/pkg/cataloger/erlang/cataloger_test.go index d29ce3e14..4860ec5e0 100644 --- a/syft/pkg/cataloger/erlang/cataloger_test.go +++ b/syft/pkg/cataloger/erlang/cataloger_test.go @@ -14,7 +14,7 @@ func TestCatalogerRebar_Globs(t *testing.T) { }{ { name: "obtain rebar.lock files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "src/rebar.lock", }, @@ -39,7 +39,7 @@ func TestCatalogerOTP_Globs(t *testing.T) { }{ { name: "obtain OTP resource files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "src/rabbitmq.app", }, diff --git a/syft/pkg/cataloger/erlang/parse_otp_app_test.go b/syft/pkg/cataloger/erlang/parse_otp_app_test.go index 93c0aa238..f890a50de 100644 --- a/syft/pkg/cataloger/erlang/parse_otp_app_test.go +++ b/syft/pkg/cataloger/erlang/parse_otp_app_test.go @@ -15,7 +15,7 @@ func TestParseOTPApplication(t *testing.T) { expected []pkg.Package }{ { - fixture: "test-fixtures/rabbitmq.app", + fixture: "testdata/rabbitmq.app", expected: []pkg.Package{ { Name: "rabbit", @@ -44,7 +44,7 @@ func TestParseOTPApplication(t *testing.T) { func Test_corruptOtpApp(t *testing.T) { pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/corrupt/rabbitmq.app"). + FromFile(t, "testdata/corrupt/rabbitmq.app"). WithError(). TestParser(t, parseOTPApp) } diff --git a/syft/pkg/cataloger/erlang/parse_rebar_lock_test.go b/syft/pkg/cataloger/erlang/parse_rebar_lock_test.go index 67e309cd3..5360a3555 100644 --- a/syft/pkg/cataloger/erlang/parse_rebar_lock_test.go +++ b/syft/pkg/cataloger/erlang/parse_rebar_lock_test.go @@ -15,7 +15,7 @@ func TestParseRebarLock(t *testing.T) { expected []pkg.Package }{ { - fixture: "test-fixtures/rebar.lock", + fixture: "testdata/rebar.lock", expected: []pkg.Package{ { Name: "certifi", @@ -111,7 +111,7 @@ func TestParseRebarLock(t *testing.T) { }, }, { - fixture: "test-fixtures/rebar-2.lock", + fixture: "testdata/rebar-2.lock", expected: []pkg.Package{ //[{<<"bcrypt">>,{pkg,<<"bcrypt">>,<<"1.1.5">>},0}, // {<<"bcrypt">>, <<"A6763BD4E1AF46D34776F85B7995E63A02978DE110C077E9570ED17006E03386">>}, @@ -258,7 +258,7 @@ func TestParseRebarLock(t *testing.T) { func Test_corruptRebarLock(t *testing.T) { pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/corrupt/rebar.lock"). + FromFile(t, "testdata/corrupt/rebar.lock"). WithError(). TestParser(t, parseRebarLock) } diff --git a/syft/pkg/cataloger/erlang/test-fixtures/corrupt/rabbitmq.app b/syft/pkg/cataloger/erlang/testdata/corrupt/rabbitmq.app similarity index 100% rename from syft/pkg/cataloger/erlang/test-fixtures/corrupt/rabbitmq.app rename to syft/pkg/cataloger/erlang/testdata/corrupt/rabbitmq.app diff --git a/syft/pkg/cataloger/erlang/test-fixtures/corrupt/rebar.lock b/syft/pkg/cataloger/erlang/testdata/corrupt/rebar.lock similarity index 100% rename from syft/pkg/cataloger/erlang/test-fixtures/corrupt/rebar.lock rename to syft/pkg/cataloger/erlang/testdata/corrupt/rebar.lock diff --git a/syft/pkg/cataloger/erlang/test-fixtures/glob-paths/src/rabbitmq.app b/syft/pkg/cataloger/erlang/testdata/glob-paths/src/rabbitmq.app similarity index 100% rename from syft/pkg/cataloger/erlang/test-fixtures/glob-paths/src/rabbitmq.app rename to syft/pkg/cataloger/erlang/testdata/glob-paths/src/rabbitmq.app diff --git a/syft/pkg/cataloger/erlang/test-fixtures/glob-paths/src/rebar.lock b/syft/pkg/cataloger/erlang/testdata/glob-paths/src/rebar.lock similarity index 100% rename from syft/pkg/cataloger/erlang/test-fixtures/glob-paths/src/rebar.lock rename to syft/pkg/cataloger/erlang/testdata/glob-paths/src/rebar.lock diff --git a/syft/pkg/cataloger/erlang/test-fixtures/rabbitmq.app b/syft/pkg/cataloger/erlang/testdata/rabbitmq.app similarity index 100% rename from syft/pkg/cataloger/erlang/test-fixtures/rabbitmq.app rename to syft/pkg/cataloger/erlang/testdata/rabbitmq.app diff --git a/syft/pkg/cataloger/erlang/test-fixtures/rebar-2.lock b/syft/pkg/cataloger/erlang/testdata/rebar-2.lock similarity index 100% rename from syft/pkg/cataloger/erlang/test-fixtures/rebar-2.lock rename to syft/pkg/cataloger/erlang/testdata/rebar-2.lock diff --git a/syft/pkg/cataloger/erlang/test-fixtures/rebar.lock b/syft/pkg/cataloger/erlang/testdata/rebar.lock similarity index 100% rename from syft/pkg/cataloger/erlang/test-fixtures/rebar.lock rename to syft/pkg/cataloger/erlang/testdata/rebar.lock diff --git a/syft/pkg/cataloger/generic/cataloger_test.go b/syft/pkg/cataloger/generic/cataloger_test.go index 46524771f..52431b5e0 100644 --- a/syft/pkg/cataloger/generic/cataloger_test.go +++ b/syft/pkg/cataloger/generic/cataloger_test.go @@ -42,10 +42,10 @@ func Test_Cataloger(t *testing.T) { upstream := "some-other-cataloger" - expectedSelection := []string{"test-fixtures/last/path.txt", "test-fixtures/another-path.txt", "test-fixtures/a-path.txt", "test-fixtures/empty.txt"} + expectedSelection := []string{"testdata/last/path.txt", "testdata/another-path.txt", "testdata/a-path.txt", "testdata/empty.txt"} resolver := file.NewMockResolverForPaths(expectedSelection...) cataloger := NewCataloger(upstream). - WithParserByPath(parser, "test-fixtures/another-path.txt", "test-fixtures/last/path.txt"). + WithParserByPath(parser, "testdata/another-path.txt", "testdata/last/path.txt"). WithParserByGlobs(parser, "**/a-path.txt", "**/empty.txt") actualPkgs, relationships, err := cataloger.Catalog(context.Background(), resolver) @@ -54,7 +54,7 @@ func Test_Cataloger(t *testing.T) { expectedPkgs := make(map[string]pkg.Package) for _, path := range expectedSelection { require.True(t, allParsedPaths[path]) - if path == "test-fixtures/empty.txt" { + if path == "testdata/empty.txt" { continue // note: empty.txt won't become a package } expectedPkgs[path] = pkg.Package{ @@ -161,7 +161,7 @@ func TestClosesFileOnParserPanic(t *testing.T) { spy := spyingIoReadCloser{ rc: rc, } - resolver := newSpyReturningFileResolver(&spy, "test-fixtures/another-path.txt") + resolver := newSpyReturningFileResolver(&spy, "testdata/another-path.txt") ctx := context.TODO() processors := []requester{ @@ -215,8 +215,8 @@ func Test_CatalogerWithParserByMediaType(t *testing.T) { upstream := "media-type-cataloger" // Create locations with test fixtures that exist on disk - loc1 := file.NewLocation("test-fixtures/a-path.txt") - loc2 := file.NewLocation("test-fixtures/another-path.txt") + loc1 := file.NewLocation("testdata/a-path.txt") + loc2 := file.NewLocation("testdata/another-path.txt") // Create a mock resolver that maps media types to locations resolver := file.NewMockResolverForMediaTypes(map[string][]file.Location{ @@ -230,8 +230,8 @@ func Test_CatalogerWithParserByMediaType(t *testing.T) { assert.NoError(t, err) // Verify both files were parsed - assert.True(t, allParsedPaths["test-fixtures/a-path.txt"], "expected a-path.txt to be parsed") - assert.True(t, allParsedPaths["test-fixtures/another-path.txt"], "expected another-path.txt to be parsed") + assert.True(t, allParsedPaths["testdata/a-path.txt"], "expected a-path.txt to be parsed") + assert.True(t, allParsedPaths["testdata/another-path.txt"], "expected another-path.txt to be parsed") // Verify packages were created assert.Len(t, actualPkgs, 2) @@ -252,8 +252,8 @@ func Test_genericCatalogerReturnsErrors(t *testing.T) { }, "**/*") m := file.NewMockResolverForPaths( - "test-fixtures/a-path.txt", - "test-fixtures/empty.txt", + "testdata/a-path.txt", + "testdata/empty.txt", ) got, _, errs := genericErrorReturning.Catalog(context.TODO(), m) diff --git a/syft/pkg/cataloger/generic/test-fixtures/a-path.txt b/syft/pkg/cataloger/generic/test-fixtures/a-path.txt deleted file mode 100644 index 67e954034..000000000 --- a/syft/pkg/cataloger/generic/test-fixtures/a-path.txt +++ /dev/null @@ -1 +0,0 @@ -test-fixtures/a-path.txt file contents! \ No newline at end of file diff --git a/syft/pkg/cataloger/generic/test-fixtures/another-path.txt b/syft/pkg/cataloger/generic/test-fixtures/another-path.txt deleted file mode 100644 index 0d654f8fe..000000000 --- a/syft/pkg/cataloger/generic/test-fixtures/another-path.txt +++ /dev/null @@ -1 +0,0 @@ -test-fixtures/another-path.txt file contents! \ No newline at end of file diff --git a/syft/pkg/cataloger/generic/test-fixtures/last/path.txt b/syft/pkg/cataloger/generic/test-fixtures/last/path.txt deleted file mode 100644 index 3d4a165ab..000000000 --- a/syft/pkg/cataloger/generic/test-fixtures/last/path.txt +++ /dev/null @@ -1 +0,0 @@ -test-fixtures/last/path.txt file contents! \ No newline at end of file diff --git a/syft/pkg/cataloger/generic/testdata/a-path.txt b/syft/pkg/cataloger/generic/testdata/a-path.txt new file mode 100644 index 000000000..7728f4708 --- /dev/null +++ b/syft/pkg/cataloger/generic/testdata/a-path.txt @@ -0,0 +1 @@ +testdata/a-path.txt file contents! \ No newline at end of file diff --git a/syft/pkg/cataloger/generic/testdata/another-path.txt b/syft/pkg/cataloger/generic/testdata/another-path.txt new file mode 100644 index 000000000..07498f8de --- /dev/null +++ b/syft/pkg/cataloger/generic/testdata/another-path.txt @@ -0,0 +1 @@ +testdata/another-path.txt file contents! \ No newline at end of file diff --git a/syft/pkg/cataloger/generic/test-fixtures/empty.txt b/syft/pkg/cataloger/generic/testdata/empty.txt similarity index 100% rename from syft/pkg/cataloger/generic/test-fixtures/empty.txt rename to syft/pkg/cataloger/generic/testdata/empty.txt diff --git a/syft/pkg/cataloger/generic/testdata/last/path.txt b/syft/pkg/cataloger/generic/testdata/last/path.txt new file mode 100644 index 000000000..953e2667f --- /dev/null +++ b/syft/pkg/cataloger/generic/testdata/last/path.txt @@ -0,0 +1 @@ +testdata/last/path.txt file contents! \ No newline at end of file diff --git a/syft/pkg/cataloger/gentoo/cataloger_test.go b/syft/pkg/cataloger/gentoo/cataloger_test.go index 79a4387be..bff79a412 100644 --- a/syft/pkg/cataloger/gentoo/cataloger_test.go +++ b/syft/pkg/cataloger/gentoo/cataloger_test.go @@ -18,7 +18,7 @@ func TestPortageCataloger(t *testing.T) { }{ { name: "standard skopeo package", - fixture: "test-fixtures/layout", + fixture: "testdata/layout", expectedPackages: []pkg.Package{ { Name: "app-containers/skopeo", @@ -77,7 +77,7 @@ func TestPortageCataloger(t *testing.T) { }, { name: "standard skopeo package with license groups", - fixture: "test-fixtures/layout-license-groups", + fixture: "testdata/layout-license-groups", expectedPackages: []pkg.Package{ { Name: "app-containers/skopeo", @@ -154,7 +154,7 @@ func TestCataloger_Globs(t *testing.T) { }{ { name: "obtain portage contents file", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "var/db/pkg/x/y/CONTENTS", }, diff --git a/syft/pkg/cataloger/gentoo/license_test.go b/syft/pkg/cataloger/gentoo/license_test.go index 1d58fd7a0..e533c2636 100644 --- a/syft/pkg/cataloger/gentoo/license_test.go +++ b/syft/pkg/cataloger/gentoo/license_test.go @@ -66,7 +66,7 @@ func TestParseLicenseGroups(t *testing.T) { }{ { name: "basic nesting example", - input: "test-fixtures/license-groups/example1", + input: "testdata/license-groups/example1", expected: map[string][]string{ "FSF-APPROVED": { "Apache-2.0", "BSD", "BSD-2", "GPL-2", "GPL-3", "LGPL-2.1", "LGPL-3", "X11", "ZLIB", @@ -79,17 +79,17 @@ func TestParseLicenseGroups(t *testing.T) { }, { name: "error on cycles", - input: "test-fixtures/license-groups/cycle", + input: "testdata/license-groups/cycle", expectError: require.Error, }, { name: "error on self references", - input: "test-fixtures/license-groups/self", + input: "testdata/license-groups/self", expectError: require.Error, }, { name: "error on missing reference", - input: "test-fixtures/license-groups/missing", + input: "testdata/license-groups/missing", expectError: require.Error, }, } diff --git a/syft/pkg/cataloger/gentoo/test-fixtures/glob-paths/var/db/pkg/x/y/CONTENTS b/syft/pkg/cataloger/gentoo/testdata/glob-paths/var/db/pkg/x/y/CONTENTS similarity index 100% rename from syft/pkg/cataloger/gentoo/test-fixtures/glob-paths/var/db/pkg/x/y/CONTENTS rename to syft/pkg/cataloger/gentoo/testdata/glob-paths/var/db/pkg/x/y/CONTENTS diff --git a/syft/pkg/cataloger/gentoo/test-fixtures/layout-license-groups/etc/portage/license_groups b/syft/pkg/cataloger/gentoo/testdata/layout-license-groups/etc/portage/license_groups similarity index 100% rename from syft/pkg/cataloger/gentoo/test-fixtures/layout-license-groups/etc/portage/license_groups rename to syft/pkg/cataloger/gentoo/testdata/layout-license-groups/etc/portage/license_groups diff --git a/syft/pkg/cataloger/gentoo/test-fixtures/layout-license-groups/var/db/pkg/app-containers/skopeo-1.5.1/CONTENTS b/syft/pkg/cataloger/gentoo/testdata/layout-license-groups/var/db/pkg/app-containers/skopeo-1.5.1/CONTENTS similarity index 100% rename from syft/pkg/cataloger/gentoo/test-fixtures/layout-license-groups/var/db/pkg/app-containers/skopeo-1.5.1/CONTENTS rename to syft/pkg/cataloger/gentoo/testdata/layout-license-groups/var/db/pkg/app-containers/skopeo-1.5.1/CONTENTS diff --git a/syft/pkg/cataloger/gentoo/test-fixtures/layout-license-groups/var/db/pkg/app-containers/skopeo-1.5.1/LICENSE b/syft/pkg/cataloger/gentoo/testdata/layout-license-groups/var/db/pkg/app-containers/skopeo-1.5.1/LICENSE similarity index 100% rename from syft/pkg/cataloger/gentoo/test-fixtures/layout-license-groups/var/db/pkg/app-containers/skopeo-1.5.1/LICENSE rename to syft/pkg/cataloger/gentoo/testdata/layout-license-groups/var/db/pkg/app-containers/skopeo-1.5.1/LICENSE diff --git a/syft/pkg/cataloger/gentoo/test-fixtures/layout-license-groups/var/db/pkg/app-containers/skopeo-1.5.1/SIZE b/syft/pkg/cataloger/gentoo/testdata/layout-license-groups/var/db/pkg/app-containers/skopeo-1.5.1/SIZE similarity index 100% rename from syft/pkg/cataloger/gentoo/test-fixtures/layout-license-groups/var/db/pkg/app-containers/skopeo-1.5.1/SIZE rename to syft/pkg/cataloger/gentoo/testdata/layout-license-groups/var/db/pkg/app-containers/skopeo-1.5.1/SIZE diff --git a/syft/pkg/cataloger/gentoo/test-fixtures/layout/var/db/pkg/app-containers/skopeo-1.5.1/CONTENTS b/syft/pkg/cataloger/gentoo/testdata/layout/var/db/pkg/app-containers/skopeo-1.5.1/CONTENTS similarity index 100% rename from syft/pkg/cataloger/gentoo/test-fixtures/layout/var/db/pkg/app-containers/skopeo-1.5.1/CONTENTS rename to syft/pkg/cataloger/gentoo/testdata/layout/var/db/pkg/app-containers/skopeo-1.5.1/CONTENTS diff --git a/syft/pkg/cataloger/gentoo/test-fixtures/layout/var/db/pkg/app-containers/skopeo-1.5.1/LICENSE b/syft/pkg/cataloger/gentoo/testdata/layout/var/db/pkg/app-containers/skopeo-1.5.1/LICENSE similarity index 100% rename from syft/pkg/cataloger/gentoo/test-fixtures/layout/var/db/pkg/app-containers/skopeo-1.5.1/LICENSE rename to syft/pkg/cataloger/gentoo/testdata/layout/var/db/pkg/app-containers/skopeo-1.5.1/LICENSE diff --git a/syft/pkg/cataloger/gentoo/test-fixtures/layout/var/db/pkg/app-containers/skopeo-1.5.1/SIZE b/syft/pkg/cataloger/gentoo/testdata/layout/var/db/pkg/app-containers/skopeo-1.5.1/SIZE similarity index 100% rename from syft/pkg/cataloger/gentoo/test-fixtures/layout/var/db/pkg/app-containers/skopeo-1.5.1/SIZE rename to syft/pkg/cataloger/gentoo/testdata/layout/var/db/pkg/app-containers/skopeo-1.5.1/SIZE diff --git a/syft/pkg/cataloger/gentoo/test-fixtures/license-groups/cycle b/syft/pkg/cataloger/gentoo/testdata/license-groups/cycle similarity index 100% rename from syft/pkg/cataloger/gentoo/test-fixtures/license-groups/cycle rename to syft/pkg/cataloger/gentoo/testdata/license-groups/cycle diff --git a/syft/pkg/cataloger/gentoo/test-fixtures/license-groups/example1 b/syft/pkg/cataloger/gentoo/testdata/license-groups/example1 similarity index 100% rename from syft/pkg/cataloger/gentoo/test-fixtures/license-groups/example1 rename to syft/pkg/cataloger/gentoo/testdata/license-groups/example1 diff --git a/syft/pkg/cataloger/gentoo/test-fixtures/license-groups/missing b/syft/pkg/cataloger/gentoo/testdata/license-groups/missing similarity index 100% rename from syft/pkg/cataloger/gentoo/test-fixtures/license-groups/missing rename to syft/pkg/cataloger/gentoo/testdata/license-groups/missing diff --git a/syft/pkg/cataloger/gentoo/test-fixtures/license-groups/self b/syft/pkg/cataloger/gentoo/testdata/license-groups/self similarity index 100% rename from syft/pkg/cataloger/gentoo/test-fixtures/license-groups/self rename to syft/pkg/cataloger/gentoo/testdata/license-groups/self diff --git a/syft/pkg/cataloger/githubactions/cataloger_test.go b/syft/pkg/cataloger/githubactions/cataloger_test.go index 430f5e100..ebbc8b07a 100644 --- a/syft/pkg/cataloger/githubactions/cataloger_test.go +++ b/syft/pkg/cataloger/githubactions/cataloger_test.go @@ -16,7 +16,7 @@ func TestCataloger_Globs(t *testing.T) { }{ { name: "obtain all workflow and composite action files", - fixture: "test-fixtures/glob", + fixture: "testdata/glob", cataloger: NewActionUsageCataloger(), expected: []string{ // composite actions @@ -29,7 +29,7 @@ func TestCataloger_Globs(t *testing.T) { }, { name: "obtain all workflow files", - fixture: "test-fixtures/glob", + fixture: "testdata/glob", cataloger: NewWorkflowUsageCataloger(), expected: []string{ // workflows diff --git a/syft/pkg/cataloger/githubactions/parse_composite_action_test.go b/syft/pkg/cataloger/githubactions/parse_composite_action_test.go index ad718f2fe..2ed607fe3 100644 --- a/syft/pkg/cataloger/githubactions/parse_composite_action_test.go +++ b/syft/pkg/cataloger/githubactions/parse_composite_action_test.go @@ -10,7 +10,7 @@ import ( ) func Test_parseCompositeActionForActionUsage(t *testing.T) { - fixture := "test-fixtures/composite-action.yaml" + fixture := "testdata/composite-action.yaml" fixtureLocationSet := file.NewLocationSet(file.NewLocation(fixture).WithAnnotation(pkg.EvidenceAnnotationKey, pkg.PrimaryEvidenceAnnotation)) expected := []pkg.Package{ @@ -38,7 +38,7 @@ func Test_parseCompositeActionForActionUsage(t *testing.T) { func Test_corruptCompositeAction(t *testing.T) { pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/corrupt/composite-action.yaml"). + FromFile(t, "testdata/corrupt/composite-action.yaml"). WithError(). TestParser(t, parseCompositeActionForActionUsage) } diff --git a/syft/pkg/cataloger/githubactions/parse_workflow_test.go b/syft/pkg/cataloger/githubactions/parse_workflow_test.go index 96d35586d..56a137240 100644 --- a/syft/pkg/cataloger/githubactions/parse_workflow_test.go +++ b/syft/pkg/cataloger/githubactions/parse_workflow_test.go @@ -10,7 +10,7 @@ import ( ) func Test_parseWorkflowForActionUsage(t *testing.T) { - fixture := "test-fixtures/workflow-multi-job.yaml" + fixture := "testdata/workflow-multi-job.yaml" fixtureLocationSet := file.NewLocationSet(file.NewLocation(fixture).WithAnnotation(pkg.EvidenceAnnotationKey, pkg.PrimaryEvidenceAnnotation)) expected := []pkg.Package{ @@ -61,7 +61,7 @@ func Test_parseWorkflowForActionUsage(t *testing.T) { } func Test_parseWorkflowForWorkflowUsage(t *testing.T) { - fixture := "test-fixtures/call-shared-workflow.yaml" + fixture := "testdata/call-shared-workflow.yaml" fixtureLocationSet := file.NewLocationSet(file.NewLocation(fixture).WithAnnotation(pkg.EvidenceAnnotationKey, pkg.PrimaryEvidenceAnnotation)) expected := []pkg.Package{ @@ -98,7 +98,7 @@ func Test_parseWorkflowForWorkflowUsage(t *testing.T) { } func Test_parseWorkflowForVersionComments(t *testing.T) { - fixture := "test-fixtures/workflow-with-version-comments.yaml" + fixture := "testdata/workflow-with-version-comments.yaml" fixtureLocationSet := file.NewLocationSet(file.NewLocation(fixture).WithAnnotation(pkg.EvidenceAnnotationKey, pkg.PrimaryEvidenceAnnotation)) expected := []pkg.Package{ @@ -131,14 +131,14 @@ func Test_parseWorkflowForVersionComments(t *testing.T) { func Test_corruptActionWorkflow(t *testing.T) { pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/corrupt/workflow-multi-job.yaml"). + FromFile(t, "testdata/corrupt/workflow-multi-job.yaml"). WithError(). TestParser(t, parseWorkflowForActionUsage) } func Test_corruptWorkflowWorkflow(t *testing.T) { pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/corrupt/workflow-multi-job.yaml"). + FromFile(t, "testdata/corrupt/workflow-multi-job.yaml"). WithError(). TestParser(t, parseWorkflowForWorkflowUsage) } diff --git a/syft/pkg/cataloger/githubactions/test-fixtures/call-shared-workflow.yaml b/syft/pkg/cataloger/githubactions/testdata/call-shared-workflow.yaml similarity index 100% rename from syft/pkg/cataloger/githubactions/test-fixtures/call-shared-workflow.yaml rename to syft/pkg/cataloger/githubactions/testdata/call-shared-workflow.yaml diff --git a/syft/pkg/cataloger/githubactions/test-fixtures/composite-action.yaml b/syft/pkg/cataloger/githubactions/testdata/composite-action.yaml similarity index 100% rename from syft/pkg/cataloger/githubactions/test-fixtures/composite-action.yaml rename to syft/pkg/cataloger/githubactions/testdata/composite-action.yaml diff --git a/syft/pkg/cataloger/githubactions/test-fixtures/corrupt/composite-action.yaml b/syft/pkg/cataloger/githubactions/testdata/corrupt/composite-action.yaml similarity index 100% rename from syft/pkg/cataloger/githubactions/test-fixtures/corrupt/composite-action.yaml rename to syft/pkg/cataloger/githubactions/testdata/corrupt/composite-action.yaml diff --git a/syft/pkg/cataloger/githubactions/test-fixtures/corrupt/workflow-multi-job.yaml b/syft/pkg/cataloger/githubactions/testdata/corrupt/workflow-multi-job.yaml similarity index 100% rename from syft/pkg/cataloger/githubactions/test-fixtures/corrupt/workflow-multi-job.yaml rename to syft/pkg/cataloger/githubactions/testdata/corrupt/workflow-multi-job.yaml diff --git a/syft/pkg/cataloger/githubactions/test-fixtures/glob/.github/actions/bootstrap/action.yaml b/syft/pkg/cataloger/githubactions/testdata/glob/.github/actions/bootstrap/action.yaml similarity index 100% rename from syft/pkg/cataloger/githubactions/test-fixtures/glob/.github/actions/bootstrap/action.yaml rename to syft/pkg/cataloger/githubactions/testdata/glob/.github/actions/bootstrap/action.yaml diff --git a/syft/pkg/cataloger/githubactions/test-fixtures/glob/.github/actions/unbootstrap/action.yml b/syft/pkg/cataloger/githubactions/testdata/glob/.github/actions/unbootstrap/action.yml similarity index 100% rename from syft/pkg/cataloger/githubactions/test-fixtures/glob/.github/actions/unbootstrap/action.yml rename to syft/pkg/cataloger/githubactions/testdata/glob/.github/actions/unbootstrap/action.yml diff --git a/syft/pkg/cataloger/githubactions/test-fixtures/glob/.github/workflows/release.yml b/syft/pkg/cataloger/githubactions/testdata/glob/.github/workflows/release.yml similarity index 100% rename from syft/pkg/cataloger/githubactions/test-fixtures/glob/.github/workflows/release.yml rename to syft/pkg/cataloger/githubactions/testdata/glob/.github/workflows/release.yml diff --git a/syft/pkg/cataloger/githubactions/test-fixtures/glob/.github/workflows/validations.yaml b/syft/pkg/cataloger/githubactions/testdata/glob/.github/workflows/validations.yaml similarity index 100% rename from syft/pkg/cataloger/githubactions/test-fixtures/glob/.github/workflows/validations.yaml rename to syft/pkg/cataloger/githubactions/testdata/glob/.github/workflows/validations.yaml diff --git a/syft/pkg/cataloger/githubactions/test-fixtures/workflow-multi-job.yaml b/syft/pkg/cataloger/githubactions/testdata/workflow-multi-job.yaml similarity index 100% rename from syft/pkg/cataloger/githubactions/test-fixtures/workflow-multi-job.yaml rename to syft/pkg/cataloger/githubactions/testdata/workflow-multi-job.yaml diff --git a/syft/pkg/cataloger/githubactions/test-fixtures/workflow-with-version-comments.yaml b/syft/pkg/cataloger/githubactions/testdata/workflow-with-version-comments.yaml similarity index 100% rename from syft/pkg/cataloger/githubactions/test-fixtures/workflow-with-version-comments.yaml rename to syft/pkg/cataloger/githubactions/testdata/workflow-with-version-comments.yaml diff --git a/syft/pkg/cataloger/golang/billy_adapter_test.go b/syft/pkg/cataloger/golang/billy_adapter_test.go index f684de9cf..77bf93267 100644 --- a/syft/pkg/cataloger/golang/billy_adapter_test.go +++ b/syft/pkg/cataloger/golang/billy_adapter_test.go @@ -10,10 +10,10 @@ import ( ) func Test_billyFSAdapter(t *testing.T) { - r, err := git.PlainInit("test-fixtures/repo", false) + r, err := git.PlainInit("testdata/repo", false) t.Cleanup(func() { - _ = os.RemoveAll("test-fixtures/repo/.git") + _ = os.RemoveAll("testdata/repo/.git") }) wt, err := r.Worktree() diff --git a/syft/pkg/cataloger/golang/cataloger_test.go b/syft/pkg/cataloger/golang/cataloger_test.go index 776c9b4e4..96c05e37d 100644 --- a/syft/pkg/cataloger/golang/cataloger_test.go +++ b/syft/pkg/cataloger/golang/cataloger_test.go @@ -133,7 +133,7 @@ func Test_Mod_Cataloger_Globs(t *testing.T) { }{ { name: "obtain go.mod files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "src/go.mod", }, @@ -159,7 +159,7 @@ func Test_Binary_Cataloger_Globs(t *testing.T) { }{ { name: "obtain binary files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "partial-binary", }, diff --git a/syft/pkg/cataloger/golang/internal/gotestdata/README.md b/syft/pkg/cataloger/golang/internal/gotestdata/README.md new file mode 100644 index 000000000..b26f1142d --- /dev/null +++ b/syft/pkg/cataloger/golang/internal/gotestdata/README.md @@ -0,0 +1,32 @@ +# gotestdata + +This directory contains test fixtures that require Go tooling to process them. + +## Why `internal/`? + +This directory is inside `internal/` to prevent external packages from importing anything +from here. Go's import restrictions on `internal/` directories ensure these fixtures are +only accessible to tests within this package. + +## Why not use `testdata`? + +Go's build system and module tooling **explicitly ignores directories named `testdata`**. This is documented behavior - when running commands like `go list`, `go mod`, or using `golang.org/x/tools/go/packages`, Go skips any directory named `testdata`. + +This becomes a problem for tests that: +- Use `packages.Load()` to resolve Go module dependencies +- Need `go mod` commands to work on fixture `go.mod` files +- Rely on any Go tooling that traverses the module graph + +## What goes here? + +Place fixtures here that contain `go.mod` files and need Go's module resolution to work. For example: +- `go-source/` - fixtures for testing Go source cataloging with dependency resolution +- Any fixture that uses `WithUsePackagesLib(true)` in tests + +## What stays in `testdata`? + +Fixtures that don't require Go tooling can remain in `testdata`: +- Static file parsing tests (e.g., parsing `go.mod` without resolution) +- Binary fixtures +- Golden files and snapshots +- Any test using `WithUsePackagesLib(false)` diff --git a/syft/pkg/cataloger/golang/test-fixtures/go-source/cmd/bin1/main.go b/syft/pkg/cataloger/golang/internal/gotestdata/go-source/cmd/bin1/main.go similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/go-source/cmd/bin1/main.go rename to syft/pkg/cataloger/golang/internal/gotestdata/go-source/cmd/bin1/main.go diff --git a/syft/pkg/cataloger/golang/test-fixtures/go-source/cmd/bin2/main.go b/syft/pkg/cataloger/golang/internal/gotestdata/go-source/cmd/bin2/main.go similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/go-source/cmd/bin2/main.go rename to syft/pkg/cataloger/golang/internal/gotestdata/go-source/cmd/bin2/main.go diff --git a/syft/pkg/cataloger/golang/test-fixtures/go-source/go.mod b/syft/pkg/cataloger/golang/internal/gotestdata/go-source/go.mod similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/go-source/go.mod rename to syft/pkg/cataloger/golang/internal/gotestdata/go-source/go.mod diff --git a/syft/pkg/cataloger/golang/test-fixtures/go-source/go.sum b/syft/pkg/cataloger/golang/internal/gotestdata/go-source/go.sum similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/go-source/go.sum rename to syft/pkg/cataloger/golang/internal/gotestdata/go-source/go.sum diff --git a/syft/pkg/cataloger/golang/test-fixtures/go-source/pk1/pk1.go b/syft/pkg/cataloger/golang/internal/gotestdata/go-source/pk1/pk1.go similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/go-source/pk1/pk1.go rename to syft/pkg/cataloger/golang/internal/gotestdata/go-source/pk1/pk1.go diff --git a/syft/pkg/cataloger/golang/test-fixtures/go-source/pk1/pk1_test.go b/syft/pkg/cataloger/golang/internal/gotestdata/go-source/pk1/pk1_test.go similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/go-source/pk1/pk1_test.go rename to syft/pkg/cataloger/golang/internal/gotestdata/go-source/pk1/pk1_test.go diff --git a/syft/pkg/cataloger/golang/test-fixtures/go-source/pk2/pk2.go b/syft/pkg/cataloger/golang/internal/gotestdata/go-source/pk2/pk2.go similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/go-source/pk2/pk2.go rename to syft/pkg/cataloger/golang/internal/gotestdata/go-source/pk2/pk2.go diff --git a/syft/pkg/cataloger/golang/test-fixtures/go-source/pk3/pk3.go b/syft/pkg/cataloger/golang/internal/gotestdata/go-source/pk3/pk3.go similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/go-source/pk3/pk3.go rename to syft/pkg/cataloger/golang/internal/gotestdata/go-source/pk3/pk3.go diff --git a/syft/pkg/cataloger/golang/licenses_test.go b/syft/pkg/cataloger/golang/licenses_test.go index c6da9284a..27d079ce6 100644 --- a/syft/pkg/cataloger/golang/licenses_test.go +++ b/syft/pkg/cataloger/golang/licenses_test.go @@ -40,7 +40,7 @@ func Test_LicenseSearch(t *testing.T) { wd, err := os.Getwd() require.NoError(t, err) - testDir := filepath.Join(wd, "test-fixtures", "licenses", "pkg", "mod", processCaps(modPath)+"@"+modVersion) + testDir := filepath.Join(wd, "testdata", "licenses", "pkg", "mod", processCaps(modPath)+"@"+modVersion) archive := zip.NewWriter(buf) @@ -70,7 +70,7 @@ func Test_LicenseSearch(t *testing.T) { wd, err := os.Getwd() require.NoError(t, err) - localVendorDir := filepath.Join(wd, "test-fixtures", "licenses-vendor") + localVendorDir := filepath.Join(wd, "testdata", "licenses-vendor") tests := []struct { name string @@ -83,7 +83,7 @@ func Test_LicenseSearch(t *testing.T) { version: "v0.3.2", config: CatalogerConfig{ SearchLocalModCacheLicenses: true, - LocalModCacheDir: filepath.Join(wd, "test-fixtures", "licenses", "pkg", "mod"), + LocalModCacheDir: filepath.Join(wd, "testdata", "licenses", "pkg", "mod"), }, expected: []pkg.License{{ Value: "Apache-2.0", @@ -99,7 +99,7 @@ func Test_LicenseSearch(t *testing.T) { version: "v4.111.5", config: CatalogerConfig{ SearchLocalModCacheLicenses: true, - LocalModCacheDir: filepath.Join(wd, "test-fixtures", "licenses", "pkg", "mod"), + LocalModCacheDir: filepath.Join(wd, "testdata", "licenses", "pkg", "mod"), }, expected: []pkg.License{{ Value: "MIT", @@ -115,7 +115,7 @@ func Test_LicenseSearch(t *testing.T) { version: "v1.2.3", config: CatalogerConfig{ SearchLocalModCacheLicenses: true, - LocalModCacheDir: filepath.Join(wd, "test-fixtures", "licenses", "pkg", "mod"), + LocalModCacheDir: filepath.Join(wd, "testdata", "licenses", "pkg", "mod"), }, expected: []pkg.License{{ Value: "Apache-2.0", @@ -163,7 +163,7 @@ func Test_LicenseSearch(t *testing.T) { version: "v4.111.5", config: CatalogerConfig{ SearchLocalModCacheLicenses: true, - LocalModCacheDir: filepath.Join(wd, "test-fixtures"), // valid dir but does not find modules + LocalModCacheDir: filepath.Join(wd, "testdata"), // valid dir but does not find modules SearchRemoteLicenses: true, Proxies: []string{server.URL}, }, @@ -297,7 +297,7 @@ func Test_remotesForModule(t *testing.T) { } func Test_findVersionPath(t *testing.T) { - f := os.DirFS("test-fixtures/zip-fs") + f := os.DirFS("testdata/zip-fs") vp := findVersionPath(f, ".") require.Equal(t, "github.com/someorg/somepkg@version", vp) } @@ -364,7 +364,7 @@ func Test_noLocalGoModDir(t *testing.T) { func mustContentsFromLocation(t *testing.T, loc file.Location, offset ...int) string { t.Helper() - contentsPath := "test-fixtures/licenses/pkg/mod/" + loc.RealPath + contentsPath := "testdata/licenses/pkg/mod/" + loc.RealPath contents, err := os.ReadFile(contentsPath) require.NoErrorf(t, err, "could not open contents for fixture at %s", contentsPath) diff --git a/syft/pkg/cataloger/golang/parse_go_binary_test.go b/syft/pkg/cataloger/golang/parse_go_binary_test.go index d1b201c72..d0fda31fe 100644 --- a/syft/pkg/cataloger/golang/parse_go_binary_test.go +++ b/syft/pkg/cataloger/golang/parse_go_binary_test.go @@ -29,7 +29,7 @@ import ( func runMakeTarget(t *testing.T, fixtureName string) { cwd, err := os.Getwd() require.NoError(t, err) - fixtureDir := filepath.Join(cwd, "test-fixtures/", fixtureName) + fixtureDir := filepath.Join(cwd, "testdata/", fixtureName) t.Logf("Generating Fixture in %q", fixtureDir) @@ -84,23 +84,23 @@ func Test_getGOARCHFromBin(t *testing.T) { }{ { name: "pe", - filepath: "test-fixtures/archs/binaries/hello-win-amd64", + filepath: "testdata/archs/binaries/hello-win-amd64", // see: https://docs.microsoft.com/en-us/windows/win32/debug/pe-format#machine-types expected: strconv.Itoa(0x8664), }, { name: "elf-ppc64", - filepath: "test-fixtures/archs/binaries/hello-linux-ppc64le", + filepath: "testdata/archs/binaries/hello-linux-ppc64le", expected: "ppc64", }, { name: "mach-o-arm64", - filepath: "test-fixtures/archs/binaries/hello-mach-o-arm64", + filepath: "testdata/archs/binaries/hello-mach-o-arm64", expected: "arm64", }, { name: "linux-arm", - filepath: "test-fixtures/archs/binaries/hello-linux-arm", + filepath: "testdata/archs/binaries/hello-linux-arm", expected: "arm", }, { diff --git a/syft/pkg/cataloger/golang/parse_go_mod.go b/syft/pkg/cataloger/golang/parse_go_mod.go index bb495cc40..c3e6bcba0 100644 --- a/syft/pkg/cataloger/golang/parse_go_mod.go +++ b/syft/pkg/cataloger/golang/parse_go_mod.go @@ -6,6 +6,7 @@ import ( "fmt" "go/build" "io" + "os" "path/filepath" "slices" "strings" @@ -109,6 +110,9 @@ func (c *goModCataloger) loadPackages(modDir string, loc file.Location) (pkgs ma Mode: packages.NeedModule | packages.NeedName | packages.NeedFiles | packages.NeedDeps | packages.NeedImports, Dir: modDir, Tests: true, + // disable workspace mode so that we only use the go.mod in the target directory, + // not any parent go.work file that may exist + Env: append(os.Environ(), "GOWORK=off"), } // From Go documentation: "all" expands to all packages in the main module diff --git a/syft/pkg/cataloger/golang/parse_go_mod_test.go b/syft/pkg/cataloger/golang/parse_go_mod_test.go index 45789e441..4a8a19291 100644 --- a/syft/pkg/cataloger/golang/parse_go_mod_test.go +++ b/syft/pkg/cataloger/golang/parse_go_mod_test.go @@ -20,13 +20,13 @@ func TestParseGoMod(t *testing.T) { expected []pkg.Package }{ { - fixture: "test-fixtures/go-mod-fixtures/one-package/go.mod", + fixture: "testdata/go-mod-fixtures/one-package/go.mod", expected: []pkg.Package{ { Name: "github.com/bmatcuk/doublestar", Version: "v1.3.1", PURL: "pkg:golang/github.com/bmatcuk/doublestar@v1.3.1", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/go-mod-fixtures/one-package/go.mod")), + Locations: file.NewLocationSet(file.NewLocation("testdata/go-mod-fixtures/one-package/go.mod")), Language: pkg.Go, Type: pkg.GoModulePkg, Metadata: pkg.GolangModuleEntry{}, @@ -34,7 +34,7 @@ func TestParseGoMod(t *testing.T) { }, }, { - fixture: "test-fixtures/go-mod-fixtures/relative-replace/go.mod", + fixture: "testdata/go-mod-fixtures/relative-replace/go.mod", expected: []pkg.Package{ { Name: "github.com/aws/aws-sdk-go-v2", @@ -42,20 +42,20 @@ func TestParseGoMod(t *testing.T) { PURL: "pkg:golang/github.com/aws/aws-sdk-go-v2", Language: pkg.Go, Type: pkg.GoModulePkg, - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/go-mod-fixtures/relative-replace/go.mod")), + Locations: file.NewLocationSet(file.NewLocation("testdata/go-mod-fixtures/relative-replace/go.mod")), Metadata: pkg.GolangModuleEntry{}, }, }, }, { - fixture: "test-fixtures/go-mod-fixtures/many-packages/go.mod", + fixture: "testdata/go-mod-fixtures/many-packages/go.mod", expected: []pkg.Package{ { Name: "github.com/anchore/archiver/v3", Version: "v3.5.2", PURL: "pkg:golang/github.com/anchore/archiver/v3@v3.5.2", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/go-mod-fixtures/many-packages/go.mod")), + Locations: file.NewLocationSet(file.NewLocation("testdata/go-mod-fixtures/many-packages/go.mod")), Language: pkg.Go, Type: pkg.GoModulePkg, Metadata: pkg.GolangModuleEntry{}, @@ -64,7 +64,7 @@ func TestParseGoMod(t *testing.T) { Name: "github.com/anchore/go-testutils", Version: "v0.0.0-20200624184116-66aa578126db", PURL: "pkg:golang/github.com/anchore/go-testutils@v0.0.0-20200624184116-66aa578126db", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/go-mod-fixtures/many-packages/go.mod")), + Locations: file.NewLocationSet(file.NewLocation("testdata/go-mod-fixtures/many-packages/go.mod")), Language: pkg.Go, Type: pkg.GoModulePkg, Metadata: pkg.GolangModuleEntry{}, @@ -73,7 +73,7 @@ func TestParseGoMod(t *testing.T) { Name: "github.com/anchore/go-version", Version: "v1.2.2-0.20200701162849-18adb9c92b9b", PURL: "pkg:golang/github.com/anchore/go-version@v1.2.2-0.20200701162849-18adb9c92b9b", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/go-mod-fixtures/many-packages/go.mod")), + Locations: file.NewLocationSet(file.NewLocation("testdata/go-mod-fixtures/many-packages/go.mod")), Language: pkg.Go, Type: pkg.GoModulePkg, Metadata: pkg.GolangModuleEntry{}, @@ -82,7 +82,7 @@ func TestParseGoMod(t *testing.T) { Name: "github.com/anchore/stereoscope", Version: "v0.0.0-20200706164556-7cf39d7f4639", PURL: "pkg:golang/github.com/anchore/stereoscope@v0.0.0-20200706164556-7cf39d7f4639", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/go-mod-fixtures/many-packages/go.mod")), + Locations: file.NewLocationSet(file.NewLocation("testdata/go-mod-fixtures/many-packages/go.mod")), Language: pkg.Go, Type: pkg.GoModulePkg, Metadata: pkg.GolangModuleEntry{}, @@ -91,7 +91,7 @@ func TestParseGoMod(t *testing.T) { Name: "github.com/bmatcuk/doublestar", Version: "v8.8.8", PURL: "pkg:golang/github.com/bmatcuk/doublestar@v8.8.8", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/go-mod-fixtures/many-packages/go.mod")), + Locations: file.NewLocationSet(file.NewLocation("testdata/go-mod-fixtures/many-packages/go.mod")), Language: pkg.Go, Type: pkg.GoModulePkg, Metadata: pkg.GolangModuleEntry{}, @@ -100,7 +100,7 @@ func TestParseGoMod(t *testing.T) { Name: "github.com/go-test/deep", Version: "v1.0.6", PURL: "pkg:golang/github.com/go-test/deep@v1.0.6", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/go-mod-fixtures/many-packages/go.mod")), + Locations: file.NewLocationSet(file.NewLocation("testdata/go-mod-fixtures/many-packages/go.mod")), Language: pkg.Go, Type: pkg.GoModulePkg, Metadata: pkg.GolangModuleEntry{}, @@ -127,7 +127,7 @@ func Test_GoSumHashes(t *testing.T) { expected []pkg.Package }{ { - fixture: "test-fixtures/go-sum-hashes", + fixture: "testdata/go-sum-hashes", expected: []pkg.Package{ { Name: "github.com/CycloneDX/cyclonedx-go", @@ -182,7 +182,7 @@ func Test_GoSumHashes(t *testing.T) { func Test_corruptGoMod(t *testing.T) { c := NewGoModuleFileCataloger(DefaultCatalogerConfig().WithSearchRemoteLicenses(false)) pkgtest.NewCatalogTester(). - FromDirectory(t, "test-fixtures/corrupt"). + FromDirectory(t, "testdata/corrupt"). WithError(). TestCataloger(t, c) } @@ -197,7 +197,7 @@ func Test_parseGoSource_packageResolution(t *testing.T) { }{ { name: "go-source with direct, transitive, and deps of transitive", - fixturePath: filepath.Join("test-fixtures", "go-source"), + fixturePath: filepath.Join("internal", "gotestdata", "go-source"), expectedPkgs: []string{ "anchore.io/not/real @ (go.mod)", "github.com/davecgh/go-spew @ v1.1.1 (go.mod)", diff --git a/syft/pkg/cataloger/golang/subfs_test.go b/syft/pkg/cataloger/golang/subfs_test.go index a940f66f8..68d2dcebf 100644 --- a/syft/pkg/cataloger/golang/subfs_test.go +++ b/syft/pkg/cataloger/golang/subfs_test.go @@ -9,7 +9,7 @@ import ( ) func Test_NewSubFS(t *testing.T) { - f := os.DirFS("test-fixtures/zip-fs") + f := os.DirFS("testdata/zip-fs") f = newSubFS(f, "github.com/someorg/somepkg@version") var names []string err := fs.WalkDir(f, ".", func(path string, d fs.DirEntry, err error) error { diff --git a/syft/pkg/cataloger/golang/test-fixtures/Makefile b/syft/pkg/cataloger/golang/testdata/Makefile similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/Makefile rename to syft/pkg/cataloger/golang/testdata/Makefile diff --git a/syft/pkg/cataloger/golang/test-fixtures/archs/.gitignore b/syft/pkg/cataloger/golang/testdata/archs/.gitignore similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/archs/.gitignore rename to syft/pkg/cataloger/golang/testdata/archs/.gitignore diff --git a/syft/pkg/cataloger/golang/test-fixtures/archs/Makefile b/syft/pkg/cataloger/golang/testdata/archs/Makefile similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/archs/Makefile rename to syft/pkg/cataloger/golang/testdata/archs/Makefile diff --git a/syft/pkg/cataloger/golang/test-fixtures/archs/src/build.sh b/syft/pkg/cataloger/golang/testdata/archs/src/build.sh similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/archs/src/build.sh rename to syft/pkg/cataloger/golang/testdata/archs/src/build.sh diff --git a/syft/pkg/cataloger/golang/test-fixtures/archs/src/go.mod b/syft/pkg/cataloger/golang/testdata/archs/src/go.mod similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/archs/src/go.mod rename to syft/pkg/cataloger/golang/testdata/archs/src/go.mod diff --git a/syft/pkg/cataloger/golang/test-fixtures/archs/src/main.go b/syft/pkg/cataloger/golang/testdata/archs/src/main.go similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/archs/src/main.go rename to syft/pkg/cataloger/golang/testdata/archs/src/main.go diff --git a/syft/pkg/cataloger/golang/test-fixtures/corrupt/go.mod b/syft/pkg/cataloger/golang/testdata/corrupt/go.mod similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/corrupt/go.mod rename to syft/pkg/cataloger/golang/testdata/corrupt/go.mod diff --git a/syft/pkg/cataloger/golang/test-fixtures/corrupt/go.sum b/syft/pkg/cataloger/golang/testdata/corrupt/go.sum similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/corrupt/go.sum rename to syft/pkg/cataloger/golang/testdata/corrupt/go.sum diff --git a/syft/pkg/cataloger/golang/test-fixtures/glob-paths/partial-binary b/syft/pkg/cataloger/golang/testdata/glob-paths/partial-binary similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/glob-paths/partial-binary rename to syft/pkg/cataloger/golang/testdata/glob-paths/partial-binary diff --git a/syft/pkg/cataloger/golang/test-fixtures/glob-paths/src/go.mod b/syft/pkg/cataloger/golang/testdata/glob-paths/src/go.mod similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/glob-paths/src/go.mod rename to syft/pkg/cataloger/golang/testdata/glob-paths/src/go.mod diff --git a/syft/pkg/cataloger/golang/test-fixtures/go-mod-fixtures/many-packages/go.mod b/syft/pkg/cataloger/golang/testdata/go-mod-fixtures/many-packages/go.mod similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/go-mod-fixtures/many-packages/go.mod rename to syft/pkg/cataloger/golang/testdata/go-mod-fixtures/many-packages/go.mod diff --git a/syft/pkg/cataloger/golang/test-fixtures/go-mod-fixtures/one-package/go.mod b/syft/pkg/cataloger/golang/testdata/go-mod-fixtures/one-package/go.mod similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/go-mod-fixtures/one-package/go.mod rename to syft/pkg/cataloger/golang/testdata/go-mod-fixtures/one-package/go.mod diff --git a/syft/pkg/cataloger/golang/test-fixtures/go-mod-fixtures/one-package/go.sum b/syft/pkg/cataloger/golang/testdata/go-mod-fixtures/one-package/go.sum similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/go-mod-fixtures/one-package/go.sum rename to syft/pkg/cataloger/golang/testdata/go-mod-fixtures/one-package/go.sum diff --git a/syft/pkg/cataloger/golang/test-fixtures/go-mod-fixtures/relative-replace/go.mod b/syft/pkg/cataloger/golang/testdata/go-mod-fixtures/relative-replace/go.mod similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/go-mod-fixtures/relative-replace/go.mod rename to syft/pkg/cataloger/golang/testdata/go-mod-fixtures/relative-replace/go.mod diff --git a/syft/pkg/cataloger/golang/test-fixtures/go-sum-hashes/go.mod b/syft/pkg/cataloger/golang/testdata/go-sum-hashes/go.mod similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/go-sum-hashes/go.mod rename to syft/pkg/cataloger/golang/testdata/go-sum-hashes/go.mod diff --git a/syft/pkg/cataloger/golang/test-fixtures/go-sum-hashes/go.sum b/syft/pkg/cataloger/golang/testdata/go-sum-hashes/go.sum similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/go-sum-hashes/go.sum rename to syft/pkg/cataloger/golang/testdata/go-sum-hashes/go.sum diff --git a/syft/pkg/cataloger/golang/test-fixtures/image-not-a-module/.gitignore b/syft/pkg/cataloger/golang/testdata/image-not-a-module/.gitignore similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/image-not-a-module/.gitignore rename to syft/pkg/cataloger/golang/testdata/image-not-a-module/.gitignore diff --git a/syft/pkg/cataloger/golang/test-fixtures/image-not-a-module/Dockerfile b/syft/pkg/cataloger/golang/testdata/image-not-a-module/Dockerfile similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/image-not-a-module/Dockerfile rename to syft/pkg/cataloger/golang/testdata/image-not-a-module/Dockerfile diff --git a/syft/pkg/cataloger/golang/test-fixtures/image-not-a-module/go.mod b/syft/pkg/cataloger/golang/testdata/image-not-a-module/go.mod similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/image-not-a-module/go.mod rename to syft/pkg/cataloger/golang/testdata/image-not-a-module/go.mod diff --git a/syft/pkg/cataloger/golang/test-fixtures/image-not-a-module/go.sum b/syft/pkg/cataloger/golang/testdata/image-not-a-module/go.sum similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/image-not-a-module/go.sum rename to syft/pkg/cataloger/golang/testdata/image-not-a-module/go.sum diff --git a/syft/pkg/cataloger/golang/test-fixtures/image-not-a-module/main.go b/syft/pkg/cataloger/golang/testdata/image-not-a-module/main.go similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/image-not-a-module/main.go rename to syft/pkg/cataloger/golang/testdata/image-not-a-module/main.go diff --git a/syft/pkg/cataloger/golang/test-fixtures/image-small-upx/.gitignore b/syft/pkg/cataloger/golang/testdata/image-small-upx/.gitignore similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/image-small-upx/.gitignore rename to syft/pkg/cataloger/golang/testdata/image-small-upx/.gitignore diff --git a/syft/pkg/cataloger/golang/test-fixtures/image-small-upx/Dockerfile b/syft/pkg/cataloger/golang/testdata/image-small-upx/Dockerfile similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/image-small-upx/Dockerfile rename to syft/pkg/cataloger/golang/testdata/image-small-upx/Dockerfile diff --git a/syft/pkg/cataloger/golang/test-fixtures/image-small-upx/go.mod b/syft/pkg/cataloger/golang/testdata/image-small-upx/go.mod similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/image-small-upx/go.mod rename to syft/pkg/cataloger/golang/testdata/image-small-upx/go.mod diff --git a/syft/pkg/cataloger/golang/test-fixtures/image-small-upx/go.sum b/syft/pkg/cataloger/golang/testdata/image-small-upx/go.sum similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/image-small-upx/go.sum rename to syft/pkg/cataloger/golang/testdata/image-small-upx/go.sum diff --git a/syft/pkg/cataloger/golang/test-fixtures/image-small-upx/main.go b/syft/pkg/cataloger/golang/testdata/image-small-upx/main.go similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/image-small-upx/main.go rename to syft/pkg/cataloger/golang/testdata/image-small-upx/main.go diff --git a/syft/pkg/cataloger/golang/test-fixtures/image-small/.gitignore b/syft/pkg/cataloger/golang/testdata/image-small/.gitignore similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/image-small/.gitignore rename to syft/pkg/cataloger/golang/testdata/image-small/.gitignore diff --git a/syft/pkg/cataloger/golang/test-fixtures/image-small/Dockerfile b/syft/pkg/cataloger/golang/testdata/image-small/Dockerfile similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/image-small/Dockerfile rename to syft/pkg/cataloger/golang/testdata/image-small/Dockerfile diff --git a/syft/pkg/cataloger/golang/test-fixtures/image-small/go.mod b/syft/pkg/cataloger/golang/testdata/image-small/go.mod similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/image-small/go.mod rename to syft/pkg/cataloger/golang/testdata/image-small/go.mod diff --git a/syft/pkg/cataloger/golang/test-fixtures/image-small/go.sum b/syft/pkg/cataloger/golang/testdata/image-small/go.sum similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/image-small/go.sum rename to syft/pkg/cataloger/golang/testdata/image-small/go.sum diff --git a/syft/pkg/cataloger/golang/test-fixtures/image-small/main.go b/syft/pkg/cataloger/golang/testdata/image-small/main.go similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/image-small/main.go rename to syft/pkg/cataloger/golang/testdata/image-small/main.go diff --git a/syft/pkg/cataloger/golang/test-fixtures/licenses-vendor/github.com/!cap!o!r!g/!cap!project/LICENSE.txt b/syft/pkg/cataloger/golang/testdata/licenses-vendor/github.com/!cap!o!r!g/!cap!project/LICENSE.txt similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/licenses-vendor/github.com/!cap!o!r!g/!cap!project/LICENSE.txt rename to syft/pkg/cataloger/golang/testdata/licenses-vendor/github.com/!cap!o!r!g/!cap!project/LICENSE.txt diff --git a/syft/pkg/cataloger/golang/test-fixtures/licenses-vendor/github.com/someorg/somename/LICENSE b/syft/pkg/cataloger/golang/testdata/licenses-vendor/github.com/someorg/somename/LICENSE similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/licenses-vendor/github.com/someorg/somename/LICENSE rename to syft/pkg/cataloger/golang/testdata/licenses-vendor/github.com/someorg/somename/LICENSE diff --git a/syft/pkg/cataloger/golang/test-fixtures/licenses-vendor/github.com/someorg/strangelicense/LiCeNsE.tXt b/syft/pkg/cataloger/golang/testdata/licenses-vendor/github.com/someorg/strangelicense/LiCeNsE.tXt similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/licenses-vendor/github.com/someorg/strangelicense/LiCeNsE.tXt rename to syft/pkg/cataloger/golang/testdata/licenses-vendor/github.com/someorg/strangelicense/LiCeNsE.tXt diff --git a/syft/pkg/cataloger/golang/test-fixtures/licenses/pkg/mod/github.com/!cap!o!r!g/!cap!project@v4.111.5/LICENSE.txt b/syft/pkg/cataloger/golang/testdata/licenses/pkg/mod/github.com/!cap!o!r!g/!cap!project@v4.111.5/LICENSE.txt similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/licenses/pkg/mod/github.com/!cap!o!r!g/!cap!project@v4.111.5/LICENSE.txt rename to syft/pkg/cataloger/golang/testdata/licenses/pkg/mod/github.com/!cap!o!r!g/!cap!project@v4.111.5/LICENSE.txt diff --git a/syft/pkg/cataloger/golang/test-fixtures/licenses/pkg/mod/github.com/someorg/somename@v0.3.2/LICENSE b/syft/pkg/cataloger/golang/testdata/licenses/pkg/mod/github.com/someorg/somename@v0.3.2/LICENSE similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/licenses/pkg/mod/github.com/someorg/somename@v0.3.2/LICENSE rename to syft/pkg/cataloger/golang/testdata/licenses/pkg/mod/github.com/someorg/somename@v0.3.2/LICENSE diff --git a/syft/pkg/cataloger/golang/test-fixtures/licenses/pkg/mod/github.com/someorg/strangelicense@v1.2.3/LiCeNsE.tXt b/syft/pkg/cataloger/golang/testdata/licenses/pkg/mod/github.com/someorg/strangelicense@v1.2.3/LiCeNsE.tXt similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/licenses/pkg/mod/github.com/someorg/strangelicense@v1.2.3/LiCeNsE.tXt rename to syft/pkg/cataloger/golang/testdata/licenses/pkg/mod/github.com/someorg/strangelicense@v1.2.3/LiCeNsE.tXt diff --git a/syft/pkg/cataloger/golang/test-fixtures/repo/LICENSE b/syft/pkg/cataloger/golang/testdata/repo/LICENSE similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/repo/LICENSE rename to syft/pkg/cataloger/golang/testdata/repo/LICENSE diff --git a/syft/pkg/cataloger/golang/test-fixtures/zip-fs/github.com/someorg/somepkg@version/a-file b/syft/pkg/cataloger/golang/testdata/zip-fs/github.com/someorg/somepkg@version/a-file similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/zip-fs/github.com/someorg/somepkg@version/a-file rename to syft/pkg/cataloger/golang/testdata/zip-fs/github.com/someorg/somepkg@version/a-file diff --git a/syft/pkg/cataloger/golang/test-fixtures/zip-fs/github.com/someorg/somepkg@version/subdir/subfile b/syft/pkg/cataloger/golang/testdata/zip-fs/github.com/someorg/somepkg@version/subdir/subfile similarity index 100% rename from syft/pkg/cataloger/golang/test-fixtures/zip-fs/github.com/someorg/somepkg@version/subdir/subfile rename to syft/pkg/cataloger/golang/testdata/zip-fs/github.com/someorg/somepkg@version/subdir/subfile diff --git a/syft/pkg/cataloger/haskell/cataloger_test.go b/syft/pkg/cataloger/haskell/cataloger_test.go index 86a4b3670..98814da1a 100644 --- a/syft/pkg/cataloger/haskell/cataloger_test.go +++ b/syft/pkg/cataloger/haskell/cataloger_test.go @@ -14,7 +14,7 @@ func TestCataloger_Globs(t *testing.T) { }{ { name: "obtain stack and cabal files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "src/stack.yaml", "src/stack.yaml.lock", diff --git a/syft/pkg/cataloger/haskell/parse_cabal_freeze_test.go b/syft/pkg/cataloger/haskell/parse_cabal_freeze_test.go index acb58b74e..fb6cf70d7 100644 --- a/syft/pkg/cataloger/haskell/parse_cabal_freeze_test.go +++ b/syft/pkg/cataloger/haskell/parse_cabal_freeze_test.go @@ -10,7 +10,7 @@ import ( ) func TestParseCabalFreeze(t *testing.T) { - fixture := "test-fixtures/cabal.project.freeze" + fixture := "testdata/cabal.project.freeze" locationSet := file.NewLocationSet(file.NewLocation(fixture)) expectedPkgs := []pkg.Package{ diff --git a/syft/pkg/cataloger/haskell/parse_stack_lock_test.go b/syft/pkg/cataloger/haskell/parse_stack_lock_test.go index ee84ae092..f68bc4b2e 100644 --- a/syft/pkg/cataloger/haskell/parse_stack_lock_test.go +++ b/syft/pkg/cataloger/haskell/parse_stack_lock_test.go @@ -11,7 +11,7 @@ import ( func TestParseStackLock(t *testing.T) { url := "https://raw.githubusercontent.com/commercialhaskell/stackage-snapshots/master/lts/19/14.yaml" - fixture := "test-fixtures/stack.yaml.lock" + fixture := "testdata/stack.yaml.lock" locationSet := file.NewLocationSet(file.NewLocation(fixture)) expectedPkgs := []pkg.Package{ @@ -133,7 +133,7 @@ func TestParseStackLock(t *testing.T) { func Test_corruptStackLock(t *testing.T) { pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/corrupt/stack.yaml.lock"). + FromFile(t, "testdata/corrupt/stack.yaml.lock"). WithError(). TestParser(t, parseStackLock) } diff --git a/syft/pkg/cataloger/haskell/parse_stack_yaml_test.go b/syft/pkg/cataloger/haskell/parse_stack_yaml_test.go index ee4586396..853381d07 100644 --- a/syft/pkg/cataloger/haskell/parse_stack_yaml_test.go +++ b/syft/pkg/cataloger/haskell/parse_stack_yaml_test.go @@ -10,7 +10,7 @@ import ( ) func TestParseStackYaml(t *testing.T) { - fixture := "test-fixtures/stack.yaml" + fixture := "testdata/stack.yaml" locationSet := file.NewLocationSet(file.NewLocation(fixture)) expectedPkgs := []pkg.Package{ @@ -113,7 +113,7 @@ func TestParseStackYaml(t *testing.T) { func Test_corruptStackYaml(t *testing.T) { pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/corrupt/stack.yaml"). + FromFile(t, "testdata/corrupt/stack.yaml"). WithError(). TestParser(t, parseStackYaml) } diff --git a/syft/pkg/cataloger/haskell/test-fixtures/cabal.project.freeze b/syft/pkg/cataloger/haskell/testdata/cabal.project.freeze similarity index 100% rename from syft/pkg/cataloger/haskell/test-fixtures/cabal.project.freeze rename to syft/pkg/cataloger/haskell/testdata/cabal.project.freeze diff --git a/syft/pkg/cataloger/haskell/test-fixtures/corrupt/stack.yaml b/syft/pkg/cataloger/haskell/testdata/corrupt/stack.yaml similarity index 100% rename from syft/pkg/cataloger/haskell/test-fixtures/corrupt/stack.yaml rename to syft/pkg/cataloger/haskell/testdata/corrupt/stack.yaml diff --git a/syft/pkg/cataloger/haskell/test-fixtures/corrupt/stack.yaml.lock b/syft/pkg/cataloger/haskell/testdata/corrupt/stack.yaml.lock similarity index 100% rename from syft/pkg/cataloger/haskell/test-fixtures/corrupt/stack.yaml.lock rename to syft/pkg/cataloger/haskell/testdata/corrupt/stack.yaml.lock diff --git a/syft/pkg/cataloger/haskell/test-fixtures/glob-paths/src/cabal.project.freeze b/syft/pkg/cataloger/haskell/testdata/glob-paths/src/cabal.project.freeze similarity index 100% rename from syft/pkg/cataloger/haskell/test-fixtures/glob-paths/src/cabal.project.freeze rename to syft/pkg/cataloger/haskell/testdata/glob-paths/src/cabal.project.freeze diff --git a/syft/pkg/cataloger/haskell/test-fixtures/glob-paths/src/stack.yaml b/syft/pkg/cataloger/haskell/testdata/glob-paths/src/stack.yaml similarity index 100% rename from syft/pkg/cataloger/haskell/test-fixtures/glob-paths/src/stack.yaml rename to syft/pkg/cataloger/haskell/testdata/glob-paths/src/stack.yaml diff --git a/syft/pkg/cataloger/haskell/test-fixtures/glob-paths/src/stack.yaml.lock b/syft/pkg/cataloger/haskell/testdata/glob-paths/src/stack.yaml.lock similarity index 100% rename from syft/pkg/cataloger/haskell/test-fixtures/glob-paths/src/stack.yaml.lock rename to syft/pkg/cataloger/haskell/testdata/glob-paths/src/stack.yaml.lock diff --git a/syft/pkg/cataloger/haskell/test-fixtures/stack.yaml b/syft/pkg/cataloger/haskell/testdata/stack.yaml similarity index 100% rename from syft/pkg/cataloger/haskell/test-fixtures/stack.yaml rename to syft/pkg/cataloger/haskell/testdata/stack.yaml diff --git a/syft/pkg/cataloger/haskell/test-fixtures/stack.yaml.lock b/syft/pkg/cataloger/haskell/testdata/stack.yaml.lock similarity index 100% rename from syft/pkg/cataloger/haskell/test-fixtures/stack.yaml.lock rename to syft/pkg/cataloger/haskell/testdata/stack.yaml.lock diff --git a/syft/pkg/cataloger/homebrew/cataloger_test.go b/syft/pkg/cataloger/homebrew/cataloger_test.go index 77e9e7560..86001419f 100644 --- a/syft/pkg/cataloger/homebrew/cataloger_test.go +++ b/syft/pkg/cataloger/homebrew/cataloger_test.go @@ -10,7 +10,7 @@ import ( ) func Test_HomebrewCataloger_Globs(t *testing.T) { - fixture := "test-fixtures/install-example" + fixture := "testdata/install-example" expected := []string{ "opt/homebrew/Cellar/foo/1.2.3/.brew/foo.rb", @@ -33,7 +33,7 @@ func Test_HomebrewCataloger(t *testing.T) { }{ { name: "go case", - path: "test-fixtures/install-example", + path: "testdata/install-example", expected: []pkg.Package{ { Name: "bar", diff --git a/syft/pkg/cataloger/homebrew/parse_homebrew_formula_test.go b/syft/pkg/cataloger/homebrew/parse_homebrew_formula_test.go index a18a4d0d4..c00c6a11d 100644 --- a/syft/pkg/cataloger/homebrew/parse_homebrew_formula_test.go +++ b/syft/pkg/cataloger/homebrew/parse_homebrew_formula_test.go @@ -17,13 +17,13 @@ func Test_ParseHomebrewPackage(t *testing.T) { }{ { name: "syft example", - fixture: "test-fixtures/formulas/syft/1.23.1/.brew/syft.rb", + fixture: "testdata/formulas/syft/1.23.1/.brew/syft.rb", expected: pkg.Package{ Name: "syft", Version: "1.23.1", Type: pkg.HomebrewPkg, Locations: file.NewLocationSet( - file.NewLocation("test-fixtures/formulas/syft/1.23.1/.brew/syft.rb").WithAnnotation(pkg.EvidenceAnnotationKey, pkg.PrimaryEvidenceAnnotation), + file.NewLocation("testdata/formulas/syft/1.23.1/.brew/syft.rb").WithAnnotation(pkg.EvidenceAnnotationKey, pkg.PrimaryEvidenceAnnotation), ), Licenses: pkg.NewLicenseSet(pkg.NewLicensesFromValues("Apache License 2.0")...), FoundBy: "homebrew-cataloger", @@ -36,13 +36,13 @@ func Test_ParseHomebrewPackage(t *testing.T) { }, { name: "crazy example", - fixture: "test-fixtures/formulas/crazy/1.0.0/.brew/crazy.rb", + fixture: "testdata/formulas/crazy/1.0.0/.brew/crazy.rb", expected: pkg.Package{ Name: "crazy", Version: "1.0.0", Type: pkg.HomebrewPkg, Locations: file.NewLocationSet( - file.NewLocation("test-fixtures/formulas/crazy/1.0.0/.brew/crazy.rb").WithAnnotation(pkg.EvidenceAnnotationKey, pkg.PrimaryEvidenceAnnotation), + file.NewLocation("testdata/formulas/crazy/1.0.0/.brew/crazy.rb").WithAnnotation(pkg.EvidenceAnnotationKey, pkg.PrimaryEvidenceAnnotation), ), FoundBy: "homebrew-cataloger", PURL: "pkg:brew/crazy@1.0.0", diff --git a/syft/pkg/cataloger/homebrew/test-fixtures/formulas/crazy/1.0.0/.brew/crazy.rb b/syft/pkg/cataloger/homebrew/testdata/formulas/crazy/1.0.0/.brew/crazy.rb similarity index 100% rename from syft/pkg/cataloger/homebrew/test-fixtures/formulas/crazy/1.0.0/.brew/crazy.rb rename to syft/pkg/cataloger/homebrew/testdata/formulas/crazy/1.0.0/.brew/crazy.rb diff --git a/syft/pkg/cataloger/homebrew/test-fixtures/formulas/syft/1.23.1/.brew/syft.rb b/syft/pkg/cataloger/homebrew/testdata/formulas/syft/1.23.1/.brew/syft.rb similarity index 100% rename from syft/pkg/cataloger/homebrew/test-fixtures/formulas/syft/1.23.1/.brew/syft.rb rename to syft/pkg/cataloger/homebrew/testdata/formulas/syft/1.23.1/.brew/syft.rb diff --git a/syft/pkg/cataloger/homebrew/test-fixtures/install-example/opt/homebrew/Cellar/foo/1.2.3/.brew/foo.rb b/syft/pkg/cataloger/homebrew/testdata/install-example/opt/homebrew/Cellar/foo/1.2.3/.brew/foo.rb similarity index 100% rename from syft/pkg/cataloger/homebrew/test-fixtures/install-example/opt/homebrew/Cellar/foo/1.2.3/.brew/foo.rb rename to syft/pkg/cataloger/homebrew/testdata/install-example/opt/homebrew/Cellar/foo/1.2.3/.brew/foo.rb diff --git a/syft/pkg/cataloger/homebrew/test-fixtures/install-example/opt/homebrew/Library/Taps/testorg/sometap/Formula/bar.rb b/syft/pkg/cataloger/homebrew/testdata/install-example/opt/homebrew/Library/Taps/testorg/sometap/Formula/bar.rb similarity index 100% rename from syft/pkg/cataloger/homebrew/test-fixtures/install-example/opt/homebrew/Library/Taps/testorg/sometap/Formula/bar.rb rename to syft/pkg/cataloger/homebrew/testdata/install-example/opt/homebrew/Library/Taps/testorg/sometap/Formula/bar.rb diff --git a/syft/pkg/cataloger/internal/binutils/branching_matcher_test.go b/syft/pkg/cataloger/internal/binutils/branching_matcher_test.go index b20e329e1..ceec220ec 100644 --- a/syft/pkg/cataloger/internal/binutils/branching_matcher_test.go +++ b/syft/pkg/cataloger/internal/binutils/branching_matcher_test.go @@ -66,7 +66,7 @@ func Test_BranchingMatcher(t *testing.T) { for _, test := range tests { t.Run(test.name, func(t *testing.T) { - resolver := file.NewMockResolverForPaths("test-fixtures/version.txt", "test-fixtures/version-parts.txt") + resolver := file.NewMockResolverForPaths("testdata/version.txt", "testdata/version-parts.txt") locs, err := resolver.FilesByGlob("**/version.txt") require.NoError(t, err) require.Len(t, locs, 1) diff --git a/syft/pkg/cataloger/internal/binutils/classifier_test.go b/syft/pkg/cataloger/internal/binutils/classifier_test.go index 3d5ddaabe..8983ce477 100644 --- a/syft/pkg/cataloger/internal/binutils/classifier_test.go +++ b/syft/pkg/cataloger/internal/binutils/classifier_test.go @@ -25,7 +25,7 @@ func Test_ClassifierCPEs(t *testing.T) { }{ { name: "no CPEs", - fixture: "test-fixtures/version.txt", + fixture: "testdata/version.txt", classifier: Classifier{ Package: "some-app", FileGlob: "**/version.txt", @@ -36,7 +36,7 @@ func Test_ClassifierCPEs(t *testing.T) { }, { name: "one Attributes", - fixture: "test-fixtures/version.txt", + fixture: "testdata/version.txt", classifier: Classifier{ Package: "some-app", FileGlob: "**/version.txt", @@ -51,7 +51,7 @@ func Test_ClassifierCPEs(t *testing.T) { }, { name: "multiple CPEs", - fixture: "test-fixtures/version.txt", + fixture: "testdata/version.txt", classifier: Classifier{ Package: "some-app", FileGlob: "**/version.txt", @@ -68,7 +68,7 @@ func Test_ClassifierCPEs(t *testing.T) { }, { name: "version in parts", - fixture: "test-fixtures/version-parts.txt", + fixture: "testdata/version-parts.txt", classifier: Classifier{ Package: "some-app", FileGlob: "**/version-parts.txt", @@ -217,7 +217,7 @@ func Test_SupportingEvidenceMatcher(t *testing.T) { for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { - s, err := directorysource.NewFromPath("test-fixtures") + s, err := directorysource.NewFromPath("testdata") require.NoError(t, err) r, err := s.FileResolver(source.AllLayersScope) require.NoError(t, err) diff --git a/syft/pkg/cataloger/internal/binutils/test-fixtures/subdir/some-binary b/syft/pkg/cataloger/internal/binutils/testdata/subdir/some-binary similarity index 100% rename from syft/pkg/cataloger/internal/binutils/test-fixtures/subdir/some-binary rename to syft/pkg/cataloger/internal/binutils/testdata/subdir/some-binary diff --git a/syft/pkg/cataloger/internal/binutils/test-fixtures/version-parts.txt b/syft/pkg/cataloger/internal/binutils/testdata/version-parts.txt similarity index 100% rename from syft/pkg/cataloger/internal/binutils/test-fixtures/version-parts.txt rename to syft/pkg/cataloger/internal/binutils/testdata/version-parts.txt diff --git a/syft/pkg/cataloger/internal/binutils/test-fixtures/version.txt b/syft/pkg/cataloger/internal/binutils/testdata/version.txt similarity index 100% rename from syft/pkg/cataloger/internal/binutils/test-fixtures/version.txt rename to syft/pkg/cataloger/internal/binutils/testdata/version.txt diff --git a/syft/pkg/cataloger/internal/pe/pe_test.go b/syft/pkg/cataloger/internal/pe/pe_test.go index e04c1e00d..0fdb62ace 100644 --- a/syft/pkg/cataloger/internal/pe/pe_test.go +++ b/syft/pkg/cataloger/internal/pe/pe_test.go @@ -16,7 +16,7 @@ import ( ) func Test_Read_DotNetDetection(t *testing.T) { - singleFileDepsJSON, err := os.ReadFile("test-fixtures/net8-app-single-file.deps.json") + singleFileDepsJSON, err := os.ReadFile("testdata/net8-app-single-file.deps.json") require.NoError(t, err) tests := []struct { diff --git a/syft/pkg/cataloger/internal/pe/test-fixtures/image-net8-app b/syft/pkg/cataloger/internal/pe/test-fixtures/image-net8-app deleted file mode 120000 index dacf088f9..000000000 --- a/syft/pkg/cataloger/internal/pe/test-fixtures/image-net8-app +++ /dev/null @@ -1 +0,0 @@ -../../../dotnet/test-fixtures/image-net8-app \ No newline at end of file diff --git a/syft/pkg/cataloger/internal/pe/test-fixtures/image-net8-app-single-file b/syft/pkg/cataloger/internal/pe/test-fixtures/image-net8-app-single-file deleted file mode 120000 index 42144fe9b..000000000 --- a/syft/pkg/cataloger/internal/pe/test-fixtures/image-net8-app-single-file +++ /dev/null @@ -1 +0,0 @@ -../../../dotnet/test-fixtures/image-net8-app-single-file \ No newline at end of file diff --git a/syft/pkg/cataloger/internal/pe/test-fixtures/Makefile b/syft/pkg/cataloger/internal/pe/testdata/Makefile similarity index 100% rename from syft/pkg/cataloger/internal/pe/test-fixtures/Makefile rename to syft/pkg/cataloger/internal/pe/testdata/Makefile diff --git a/syft/pkg/cataloger/internal/pe/test-fixtures/image-dotnet31-single-file/Dockerfile b/syft/pkg/cataloger/internal/pe/testdata/image-dotnet31-single-file/Dockerfile similarity index 100% rename from syft/pkg/cataloger/internal/pe/test-fixtures/image-dotnet31-single-file/Dockerfile rename to syft/pkg/cataloger/internal/pe/testdata/image-dotnet31-single-file/Dockerfile diff --git a/syft/pkg/cataloger/internal/pe/test-fixtures/image-dotnet31-single-file/src/Program.cs b/syft/pkg/cataloger/internal/pe/testdata/image-dotnet31-single-file/src/Program.cs similarity index 100% rename from syft/pkg/cataloger/internal/pe/test-fixtures/image-dotnet31-single-file/src/Program.cs rename to syft/pkg/cataloger/internal/pe/testdata/image-dotnet31-single-file/src/Program.cs diff --git a/syft/pkg/cataloger/internal/pe/test-fixtures/image-dotnet31-single-file/src/hello.csproj b/syft/pkg/cataloger/internal/pe/testdata/image-dotnet31-single-file/src/hello.csproj similarity index 100% rename from syft/pkg/cataloger/internal/pe/test-fixtures/image-dotnet31-single-file/src/hello.csproj rename to syft/pkg/cataloger/internal/pe/testdata/image-dotnet31-single-file/src/hello.csproj diff --git a/syft/pkg/cataloger/internal/pe/test-fixtures/image-dotnet5-single-file/Dockerfile b/syft/pkg/cataloger/internal/pe/testdata/image-dotnet5-single-file/Dockerfile similarity index 100% rename from syft/pkg/cataloger/internal/pe/test-fixtures/image-dotnet5-single-file/Dockerfile rename to syft/pkg/cataloger/internal/pe/testdata/image-dotnet5-single-file/Dockerfile diff --git a/syft/pkg/cataloger/internal/pe/test-fixtures/image-dotnet5-single-file/src/Program.cs b/syft/pkg/cataloger/internal/pe/testdata/image-dotnet5-single-file/src/Program.cs similarity index 100% rename from syft/pkg/cataloger/internal/pe/test-fixtures/image-dotnet5-single-file/src/Program.cs rename to syft/pkg/cataloger/internal/pe/testdata/image-dotnet5-single-file/src/Program.cs diff --git a/syft/pkg/cataloger/internal/pe/test-fixtures/image-dotnet5-single-file/src/hello.csproj b/syft/pkg/cataloger/internal/pe/testdata/image-dotnet5-single-file/src/hello.csproj similarity index 100% rename from syft/pkg/cataloger/internal/pe/test-fixtures/image-dotnet5-single-file/src/hello.csproj rename to syft/pkg/cataloger/internal/pe/testdata/image-dotnet5-single-file/src/hello.csproj diff --git a/syft/pkg/cataloger/internal/pe/test-fixtures/image-dotnet6-single-file/Dockerfile b/syft/pkg/cataloger/internal/pe/testdata/image-dotnet6-single-file/Dockerfile similarity index 100% rename from syft/pkg/cataloger/internal/pe/test-fixtures/image-dotnet6-single-file/Dockerfile rename to syft/pkg/cataloger/internal/pe/testdata/image-dotnet6-single-file/Dockerfile diff --git a/syft/pkg/cataloger/internal/pe/test-fixtures/image-dotnet6-single-file/src/Program.cs b/syft/pkg/cataloger/internal/pe/testdata/image-dotnet6-single-file/src/Program.cs similarity index 100% rename from syft/pkg/cataloger/internal/pe/test-fixtures/image-dotnet6-single-file/src/Program.cs rename to syft/pkg/cataloger/internal/pe/testdata/image-dotnet6-single-file/src/Program.cs diff --git a/syft/pkg/cataloger/internal/pe/test-fixtures/image-dotnet6-single-file/src/hello.csproj b/syft/pkg/cataloger/internal/pe/testdata/image-dotnet6-single-file/src/hello.csproj similarity index 100% rename from syft/pkg/cataloger/internal/pe/test-fixtures/image-dotnet6-single-file/src/hello.csproj rename to syft/pkg/cataloger/internal/pe/testdata/image-dotnet6-single-file/src/hello.csproj diff --git a/syft/pkg/cataloger/internal/pe/testdata/image-net8-app b/syft/pkg/cataloger/internal/pe/testdata/image-net8-app new file mode 120000 index 000000000..497e7d17c --- /dev/null +++ b/syft/pkg/cataloger/internal/pe/testdata/image-net8-app @@ -0,0 +1 @@ +../../../dotnet/testdata/image-net8-app \ No newline at end of file diff --git a/syft/pkg/cataloger/internal/pe/testdata/image-net8-app-single-file b/syft/pkg/cataloger/internal/pe/testdata/image-net8-app-single-file new file mode 120000 index 000000000..884c00cff --- /dev/null +++ b/syft/pkg/cataloger/internal/pe/testdata/image-net8-app-single-file @@ -0,0 +1 @@ +../../../dotnet/testdata/image-net8-app-single-file \ No newline at end of file diff --git a/syft/pkg/cataloger/internal/pe/test-fixtures/net8-app-single-file.deps.json b/syft/pkg/cataloger/internal/pe/testdata/net8-app-single-file.deps.json similarity index 100% rename from syft/pkg/cataloger/internal/pe/test-fixtures/net8-app-single-file.deps.json rename to syft/pkg/cataloger/internal/pe/testdata/net8-app-single-file.deps.json diff --git a/syft/pkg/cataloger/internal/pkgtest/metadata_tracker.go b/syft/pkg/cataloger/internal/pkgtest/metadata_tracker.go index 378a025c8..84921a129 100644 --- a/syft/pkg/cataloger/internal/pkgtest/metadata_tracker.go +++ b/syft/pkg/cataloger/internal/pkgtest/metadata_tracker.go @@ -470,7 +470,7 @@ func contains(slice []string, item string) bool { // ===== Result Writing ===== -// WriteResults writes the collected observation data to test-fixtures/test-observations.json. +// WriteResults writes the collected observation data to testdata/test-observations.json. func (t *MetadataTracker) WriteResults() error { t.mu.Lock() defer t.mu.Unlock() @@ -481,7 +481,7 @@ func (t *MetadataTracker) WriteResults() error { } // create output directory - outDir := "test-fixtures" + outDir := "testdata" if err := os.MkdirAll(outDir, 0755); err != nil { return err } diff --git a/syft/pkg/cataloger/internal/pkgtest/test_generic_parser.go b/syft/pkg/cataloger/internal/pkgtest/test_generic_parser.go index 7ee6b909c..137a315dc 100644 --- a/syft/pkg/cataloger/internal/pkgtest/test_generic_parser.go +++ b/syft/pkg/cataloger/internal/pkgtest/test_generic_parser.go @@ -240,12 +240,14 @@ func (p *CatalogTester) WithPackageStringer(fn func(pkg.Package) string) *Catalo func (p *CatalogTester) ExpectsPackageStrings(expected []string) *CatalogTester { return p.ExpectsAssertion(func(t *testing.T, pkgs []pkg.Package, _ []artifact.Relationship) { + t.Helper() diffPackages(t, expected, pkgs, p.packageStringer) }) } func (p *CatalogTester) ExpectsRelationshipStrings(expected []string) *CatalogTester { return p.ExpectsAssertion(func(t *testing.T, pkgs []pkg.Package, relationships []artifact.Relationship) { + t.Helper() diffRelationships(t, expected, relationships, pkgs, p.packageStringer) }) } diff --git a/syft/pkg/cataloger/java/archive_parser_test.go b/syft/pkg/cataloger/java/archive_parser_test.go index c5f559d65..d30de4625 100644 --- a/syft/pkg/cataloger/java/archive_parser_test.go +++ b/syft/pkg/cataloger/java/archive_parser_test.go @@ -29,7 +29,7 @@ import ( ) func TestSearchMavenForLicenses(t *testing.T) { - url := maventest.MockRepo(t, "internal/maven/test-fixtures/maven-repo") + url := maventest.MockRepo(t, "internal/maven/testdata/maven-repo") ctx := pkgtest.Context() tests := []struct { @@ -101,7 +101,7 @@ func TestParseJar(t *testing.T) { }{ { name: "example-jenkins-plugin", - fixture: "test-fixtures/java-builds/packages/example-jenkins-plugin.hpi", + fixture: "testdata/java-builds/packages/example-jenkins-plugin.hpi", wantErr: require.Error, // there are nested jars, which are not scanned and result in unknown errors ignoreExtras: []string{ "Plugin-Version", // has dynamic date @@ -114,12 +114,12 @@ func TestParseJar(t *testing.T) { Version: "1.0-SNAPSHOT", PURL: "pkg:maven/io.jenkins.plugins/example-jenkins-plugin@1.0-SNAPSHOT", Licenses: pkg.NewLicenseSet( - pkg.NewLicenseFromLocationsWithContext(ctx, "MIT License", file.NewLocation("test-fixtures/java-builds/packages/example-jenkins-plugin.hpi")), + pkg.NewLicenseFromLocationsWithContext(ctx, "MIT License", file.NewLocation("testdata/java-builds/packages/example-jenkins-plugin.hpi")), ), Language: pkg.Java, Type: pkg.JenkinsPluginPkg, Metadata: pkg.JavaArchive{ - VirtualPath: "test-fixtures/java-builds/packages/example-jenkins-plugin.hpi", + VirtualPath: "testdata/java-builds/packages/example-jenkins-plugin.hpi", Manifest: &pkg.JavaManifest{ Main: pkg.KeyValues{ {Key: "Manifest-Version", Value: "1.0"}, @@ -173,7 +173,7 @@ func TestParseJar(t *testing.T) { }, { name: "example-java-app-gradle", - fixture: "test-fixtures/java-builds/packages/example-java-app-gradle-0.1.0.jar", + fixture: "testdata/java-builds/packages/example-java-app-gradle-0.1.0.jar", wantErr: require.NoError, // no nested jars expected: map[string]pkg.Package{ "example-java-app-gradle": { @@ -187,11 +187,11 @@ func TestParseJar(t *testing.T) { Value: "Apache-2.0", SPDXExpression: "Apache-2.0", Type: license.Concluded, - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/java-builds/packages/example-java-app-gradle-0.1.0.jar")), + Locations: file.NewLocationSet(file.NewLocation("testdata/java-builds/packages/example-java-app-gradle-0.1.0.jar")), }, ), Metadata: pkg.JavaArchive{ - VirtualPath: "test-fixtures/java-builds/packages/example-java-app-gradle-0.1.0.jar", + VirtualPath: "testdata/java-builds/packages/example-java-app-gradle-0.1.0.jar", Manifest: &pkg.JavaManifest{ Main: []pkg.KeyValue{ { @@ -222,14 +222,14 @@ func TestParseJar(t *testing.T) { Type: pkg.JavaPkg, Licenses: pkg.NewLicenseSet( pkg.NewLicenseFromFieldsWithContext(ctx, "Apache 2", "http://www.apache.org/licenses/LICENSE-2.0.txt", func() *file.Location { - l := file.NewLocation("test-fixtures/java-builds/packages/example-java-app-gradle-0.1.0.jar") + l := file.NewLocation("testdata/java-builds/packages/example-java-app-gradle-0.1.0.jar") return &l }()), ), Metadata: pkg.JavaArchive{ // ensure that nested packages with different names than that of the parent are appended as // a suffix on the virtual path with a colon separator between group name and artifact name - VirtualPath: "test-fixtures/java-builds/packages/example-java-app-gradle-0.1.0.jar:joda-time:joda-time", + VirtualPath: "testdata/java-builds/packages/example-java-app-gradle-0.1.0.jar:joda-time:joda-time", PomProperties: &pkg.JavaPomProperties{ Path: "META-INF/maven/joda-time/joda-time/pom.properties", GroupID: "joda-time", @@ -251,7 +251,7 @@ func TestParseJar(t *testing.T) { }, { name: "example-java-app-maven", - fixture: "test-fixtures/java-builds/packages/example-java-app-maven-0.1.0.jar", + fixture: "testdata/java-builds/packages/example-java-app-maven-0.1.0.jar", wantErr: require.NoError, // no nested jars ignoreExtras: []string{ "Build-Jdk", // can't guarantee the JDK used at build time @@ -269,11 +269,11 @@ func TestParseJar(t *testing.T) { Value: "Apache-2.0", SPDXExpression: "Apache-2.0", Type: license.Concluded, - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/java-builds/packages/example-java-app-maven-0.1.0.jar")), + Locations: file.NewLocationSet(file.NewLocation("testdata/java-builds/packages/example-java-app-maven-0.1.0.jar")), }, ), Metadata: pkg.JavaArchive{ - VirtualPath: "test-fixtures/java-builds/packages/example-java-app-maven-0.1.0.jar", + VirtualPath: "testdata/java-builds/packages/example-java-app-maven-0.1.0.jar", Manifest: &pkg.JavaManifest{ Main: []pkg.KeyValue{ { @@ -323,7 +323,7 @@ func TestParseJar(t *testing.T) { PURL: "pkg:maven/joda-time/joda-time@2.9.2", Licenses: pkg.NewLicenseSet( pkg.NewLicenseFromFieldsWithContext(ctx, "Apache 2", "http://www.apache.org/licenses/LICENSE-2.0.txt", func() *file.Location { - l := file.NewLocation("test-fixtures/java-builds/packages/example-java-app-maven-0.1.0.jar") + l := file.NewLocation("testdata/java-builds/packages/example-java-app-maven-0.1.0.jar") return &l }()), ), @@ -332,7 +332,7 @@ func TestParseJar(t *testing.T) { Metadata: pkg.JavaArchive{ // ensure that nested packages with different names than that of the parent are appended as // a suffix on the virtual path - VirtualPath: "test-fixtures/java-builds/packages/example-java-app-maven-0.1.0.jar:joda-time:joda-time", + VirtualPath: "testdata/java-builds/packages/example-java-app-maven-0.1.0.jar:joda-time:joda-time", PomProperties: &pkg.JavaPomProperties{ Path: "META-INF/maven/joda-time/joda-time/pom.properties", GroupID: "joda-time", @@ -467,7 +467,7 @@ func TestParseNestedJar(t *testing.T) { ignoreExtras []string }{ { - fixture: "test-fixtures/java-builds/packages/spring-boot-0.0.1-SNAPSHOT.jar", + fixture: "testdata/java-builds/packages/spring-boot-0.0.1-SNAPSHOT.jar", expected: []pkg.Package{ { Name: "spring-boot", @@ -1127,9 +1127,9 @@ func Test_parseJavaArchive_regressions(t *testing.T) { Type: pkg.JavaPkg, Language: pkg.Java, PURL: "pkg:maven/org.apache.directory.api/api-all@2.0.0", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/jar-metadata/cache/api-all-2.0.0-sources.jar")), + Locations: file.NewLocationSet(file.NewLocation("testdata/jar-metadata/cache/api-all-2.0.0-sources.jar")), Metadata: pkg.JavaArchive{ - VirtualPath: "test-fixtures/jar-metadata/cache/api-all-2.0.0-sources.jar", + VirtualPath: "testdata/jar-metadata/cache/api-all-2.0.0-sources.jar", Manifest: &pkg.JavaManifest{ Main: []pkg.KeyValue{ { @@ -1170,11 +1170,11 @@ func Test_parseJavaArchive_regressions(t *testing.T) { Name: "api-asn1-api", Version: "2.0.0", PURL: "pkg:maven/org.apache.directory.api/api-asn1-api@2.0.0", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/jar-metadata/cache/api-all-2.0.0-sources.jar")), + Locations: file.NewLocationSet(file.NewLocation("testdata/jar-metadata/cache/api-all-2.0.0-sources.jar")), Type: pkg.JavaPkg, Language: pkg.Java, Metadata: pkg.JavaArchive{ - VirtualPath: "test-fixtures/jar-metadata/cache/api-all-2.0.0-sources.jar:org.apache.directory.api:api-asn1-api", + VirtualPath: "testdata/jar-metadata/cache/api-all-2.0.0-sources.jar:org.apache.directory.api:api-asn1-api", PomProperties: &pkg.JavaPomProperties{ Path: "META-INF/maven/org.apache.directory.api/api-asn1-api/pom.properties", GroupID: "org.apache.directory.api", @@ -1202,11 +1202,11 @@ func Test_parseJavaArchive_regressions(t *testing.T) { Name: "micronaut-aop", Version: "4.9.11", PURL: "pkg:maven/io.micronaut/micronaut-aop@4.9.11", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/jar-metadata/cache/micronaut-aop-4.9.11.jar")), + Locations: file.NewLocationSet(file.NewLocation("testdata/jar-metadata/cache/micronaut-aop-4.9.11.jar")), Type: pkg.JavaPkg, Language: pkg.Java, Metadata: pkg.JavaArchive{ - VirtualPath: "test-fixtures/jar-metadata/cache/micronaut-aop-4.9.11.jar", + VirtualPath: "testdata/jar-metadata/cache/micronaut-aop-4.9.11.jar", Manifest: &pkg.JavaManifest{ Main: []pkg.KeyValue{ { @@ -1256,16 +1256,16 @@ func Test_parseJavaArchive_regressions(t *testing.T) { Type: pkg.JavaPkg, Language: pkg.Java, PURL: "pkg:maven/com.fasterxml.jackson.core/jackson-core@2.15.2", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/jar-metadata/cache/jackson-core-2.15.2.jar")), + Locations: file.NewLocationSet(file.NewLocation("testdata/jar-metadata/cache/jackson-core-2.15.2.jar")), Licenses: pkg.NewLicenseSet( pkg.NewLicensesFromLocationWithContext( ctx, - file.NewLocation("test-fixtures/jar-metadata/cache/jackson-core-2.15.2.jar"), + file.NewLocation("testdata/jar-metadata/cache/jackson-core-2.15.2.jar"), "https://www.apache.org/licenses/LICENSE-2.0.txt", )..., ), Metadata: pkg.JavaArchive{ - VirtualPath: "test-fixtures/jar-metadata/cache/jackson-core-2.15.2.jar", + VirtualPath: "testdata/jar-metadata/cache/jackson-core-2.15.2.jar", Manifest: &pkg.JavaManifest{ Main: pkg.KeyValues{ {Key: "Manifest-Version", Value: "1.0"}, @@ -1321,16 +1321,16 @@ func Test_parseJavaArchive_regressions(t *testing.T) { Type: pkg.JavaPkg, Language: pkg.Java, PURL: "pkg:maven/com.fasterxml.jackson.core/jackson-core@2.15.2", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/jar-metadata/cache/com.fasterxml.jackson.core.jackson-core-2.15.2.jar")), + Locations: file.NewLocationSet(file.NewLocation("testdata/jar-metadata/cache/com.fasterxml.jackson.core.jackson-core-2.15.2.jar")), Licenses: pkg.NewLicenseSet( pkg.NewLicensesFromLocationWithContext( ctx, - file.NewLocation("test-fixtures/jar-metadata/cache/com.fasterxml.jackson.core.jackson-core-2.15.2.jar"), + file.NewLocation("testdata/jar-metadata/cache/com.fasterxml.jackson.core.jackson-core-2.15.2.jar"), "https://www.apache.org/licenses/LICENSE-2.0.txt", )..., ), Metadata: pkg.JavaArchive{ - VirtualPath: "test-fixtures/jar-metadata/cache/com.fasterxml.jackson.core.jackson-core-2.15.2.jar", + VirtualPath: "testdata/jar-metadata/cache/com.fasterxml.jackson.core.jackson-core-2.15.2.jar", Manifest: &pkg.JavaManifest{ Main: pkg.KeyValues{ {Key: "Manifest-Version", Value: "1.0"}, @@ -1408,9 +1408,9 @@ func Test_parseJavaArchive_regressions(t *testing.T) { Type: pkg.JenkinsPluginPkg, Language: pkg.Java, PURL: "pkg:maven/org.jenkins-ci.plugins/gradle@2.11", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/jar-metadata/cache/gradle.hpi")), + Locations: file.NewLocationSet(file.NewLocation("testdata/jar-metadata/cache/gradle.hpi")), Metadata: pkg.JavaArchive{ - VirtualPath: "test-fixtures/jar-metadata/cache/gradle.hpi", + VirtualPath: "testdata/jar-metadata/cache/gradle.hpi", Manifest: &pkg.JavaManifest{ Main: pkg.KeyValues{ {Key: "Manifest-Version", Value: "1.0"}, @@ -1530,7 +1530,7 @@ func generateJavaBuildFixture(t *testing.T, fixturePath string) { return } - makeTask := strings.TrimPrefix(fixturePath, "test-fixtures/java-builds/") + makeTask := strings.TrimPrefix(fixturePath, "testdata/java-builds/") t.Log(color.Bold.Sprintf("Generating Fixture from 'make %s'", makeTask)) cwd, err := os.Getwd() @@ -1539,7 +1539,7 @@ func generateJavaBuildFixture(t *testing.T, fixturePath string) { } cmd := exec.Command("make", makeTask) - cmd.Dir = filepath.Join(cwd, "test-fixtures/java-builds/") + cmd.Dir = filepath.Join(cwd, "testdata/java-builds/") run(t, cmd) } @@ -1549,7 +1549,7 @@ func generateJavaMetadataJarFixture(t *testing.T, fixtureName string, fileExtens fileExtension = "jar" } - fixturePath := filepath.Join("test-fixtures/jar-metadata/cache/", fixtureName+"."+fileExtension) + fixturePath := filepath.Join("testdata/jar-metadata/cache/", fixtureName+"."+fileExtension) if _, err := os.Stat(fixturePath); !os.IsNotExist(err) { // fixture already exists... return fixturePath @@ -1564,7 +1564,7 @@ func generateJavaMetadataJarFixture(t *testing.T, fixtureName string, fileExtens } cmd := exec.Command("make", makeTask) - cmd.Dir = filepath.Join(cwd, "test-fixtures/jar-metadata") + cmd.Dir = filepath.Join(cwd, "testdata/jar-metadata") run(t, cmd) @@ -1624,7 +1624,7 @@ func ptr[T any](value T) *T { func Test_corruptJarArchive(t *testing.T) { ap := newGenericArchiveParserAdapter(DefaultArchiveCatalogerConfig()) pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/corrupt/example.jar"). + FromFile(t, "testdata/corrupt/example.jar"). WithError(). TestParser(t, ap.parseJavaArchive) } @@ -1642,7 +1642,7 @@ func Test_jarPomPropertyResolutionDoesNotPanic(t *testing.T) { ReadCloser: fixture, }, false, ArchiveCatalogerConfig{ UseMavenLocalRepository: true, - MavenLocalRepositoryDir: "internal/maven/test-fixtures/maven-repo", + MavenLocalRepositoryDir: "internal/maven/testdata/maven-repo", }) defer cleanupFn() require.NoError(t, err) diff --git a/syft/pkg/cataloger/java/cataloger_test.go b/syft/pkg/cataloger/java/cataloger_test.go index f24a2744a..f0a91c118 100644 --- a/syft/pkg/cataloger/java/cataloger_test.go +++ b/syft/pkg/cataloger/java/cataloger_test.go @@ -18,7 +18,7 @@ func Test_ArchiveCataloger_Globs(t *testing.T) { }{ { name: "obtain java archive files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "java-archives/example.jar", "java-archives/example.war", @@ -83,7 +83,7 @@ func Test_POMCataloger_Globs(t *testing.T) { }{ { name: "obtain java pom files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "src/pom.xml", }, @@ -117,7 +117,7 @@ func TestJvmDistributionCataloger(t *testing.T) { }{ { name: "valid 1.8.0", - fixture: "test-fixtures/jvm-installs/oracle-jdk-se-8", + fixture: "testdata/jvm-installs/oracle-jdk-se-8", expected: pkg.Package{ Name: "jdk", Version: "1.8.0_411-b25", @@ -150,7 +150,7 @@ func TestJvmDistributionCataloger(t *testing.T) { }, { name: "valid post-jep223", - fixture: "test-fixtures/jvm-installs/valid-post-jep223", + fixture: "testdata/jvm-installs/valid-post-jep223", expected: pkg.Package{ Name: "openjdk", Version: "21.0.4+7-LTS", @@ -227,7 +227,7 @@ func TestJvmDistributionCatalogerFromFile(t *testing.T) { }{ { name: "valid 1.8.0", - fixture: "test-fixtures/jvm-installs/oracle-jdk-se-8/usr/lib/jvm/jdk-1.8-oracle-x64/release", + fixture: "testdata/jvm-installs/oracle-jdk-se-8/usr/lib/jvm/jdk-1.8-oracle-x64/release", expected: pkg.Package{ Name: "jdk", Version: "1.8.0_411-b25", @@ -259,7 +259,7 @@ func TestJvmDistributionCatalogerFromFile(t *testing.T) { }, { name: "valid post-jep223", - fixture: "test-fixtures/jvm-installs/valid-post-jep223/jvm/openjdk/release", + fixture: "testdata/jvm-installs/valid-post-jep223/jvm/openjdk/release", expected: pkg.Package{ Name: "openjdk", Version: "21.0.4+7-LTS", diff --git a/syft/pkg/cataloger/java/graalvm_native_image_cataloger_test.go b/syft/pkg/cataloger/java/graalvm_native_image_cataloger_test.go index fd2db0aad..504b6f16b 100644 --- a/syft/pkg/cataloger/java/graalvm_native_image_cataloger_test.go +++ b/syft/pkg/cataloger/java/graalvm_native_image_cataloger_test.go @@ -35,7 +35,7 @@ func TestParseNativeImage(t *testing.T) { } for _, test := range tests { t.Run(test.fixture, func(t *testing.T) { - f, err := os.Open("test-fixtures/java-builds/packages/" + test.fixture) + f, err := os.Open("testdata/java-builds/packages/" + test.fixture) require.NoError(t, err) readerCloser := io.NopCloser(f) reader, err := unionreader.GetUnionReader(readerCloser) @@ -140,7 +140,7 @@ func TestParseNativeImageSbom(t *testing.T) { expectedRelations []artifact.Relationship }{ { - fixture: "test-fixtures/graalvm-sbom/micronaut.json", + fixture: "testdata/graalvm-sbom/micronaut.json", expectedPackages: []pkg.Package{nettyPkg, micronautPkg, basicPkg, mainAppPkg}, expectedRelations: []artifact.Relationship{ { diff --git a/syft/pkg/cataloger/java/internal/maven/config_test.go b/syft/pkg/cataloger/java/internal/maven/config_test.go index f51fea3bf..1a6ab4c50 100644 --- a/syft/pkg/cataloger/java/internal/maven/config_test.go +++ b/syft/pkg/cataloger/java/internal/maven/config_test.go @@ -15,7 +15,7 @@ func Test_defaultMavenLocalRepoDir(t *testing.T) { home, err := homedir.Dir() require.NoError(t, err) - fixtures, err := filepath.Abs("test-fixtures") + fixtures, err := filepath.Abs("testdata") require.NoError(t, err) tests := []struct { @@ -31,12 +31,12 @@ func Test_defaultMavenLocalRepoDir(t *testing.T) { { name: "alternate dir", expected: "/some/other/repo", - home: "test-fixtures/local-repository-settings", + home: "testdata/local-repository-settings", }, { name: "explicit home", expected: filepath.Join(fixtures, ".m2", "repository"), - home: "test-fixtures", + home: "testdata", }, } for _, test := range tests { @@ -61,7 +61,7 @@ func Test_getSettingsXmlLocalRepository(t *testing.T) { }{ { expected: "/some/other/repo", - file: "test-fixtures/local-repository-settings/.m2/settings.xml", + file: "testdata/local-repository-settings/.m2/settings.xml", }, { expected: "", diff --git a/syft/pkg/cataloger/java/internal/maven/pom_parser_test.go b/syft/pkg/cataloger/java/internal/maven/pom_parser_test.go index c9f8463a4..9b50cd314 100644 --- a/syft/pkg/cataloger/java/internal/maven/pom_parser_test.go +++ b/syft/pkg/cataloger/java/internal/maven/pom_parser_test.go @@ -68,11 +68,11 @@ func Test_decodePomXML_surviveNonUtf8Encoding(t *testing.T) { }{ { name: "undeclared encoding", - fixture: "test-fixtures/undeclared-iso-8859-encoded-pom.xml.base64", + fixture: "testdata/undeclared-iso-8859-encoded-pom.xml.base64", }, { name: "declared encoding", - fixture: "test-fixtures/declared-iso-8859-encoded-pom.xml.base64", + fixture: "testdata/declared-iso-8859-encoded-pom.xml.base64", }, } diff --git a/syft/pkg/cataloger/java/internal/maven/resolver_test.go b/syft/pkg/cataloger/java/internal/maven/resolver_test.go index 34042593a..259a55c45 100644 --- a/syft/pkg/cataloger/java/internal/maven/resolver_test.go +++ b/syft/pkg/cataloger/java/internal/maven/resolver_test.go @@ -163,7 +163,7 @@ func Test_resolveProperty(t *testing.T) { } func Test_mavenResolverLocal(t *testing.T) { - dir, err := filepath.Abs("test-fixtures/maven-repo") + dir, err := filepath.Abs("testdata/maven-repo") require.NoError(t, err) tests := []struct { @@ -226,7 +226,7 @@ func Test_mavenResolverLocal(t *testing.T) { } func Test_mavenResolverRemote(t *testing.T) { - url := maventest.MockRepo(t, "test-fixtures/maven-repo") + url := maventest.MockRepo(t, "testdata/maven-repo") tests := []struct { groupID string @@ -273,7 +273,7 @@ func Test_mavenResolverRemote(t *testing.T) { } func Test_relativePathParent(t *testing.T) { - resolver, err := fileresolver.NewFromDirectory("test-fixtures/local", "") + resolver, err := fileresolver.NewFromDirectory("testdata/local", "") require.NoError(t, err) ctx := context.Background() diff --git a/syft/pkg/cataloger/java/internal/maven/test-fixtures/declared-iso-8859-encoded-pom.xml.base64 b/syft/pkg/cataloger/java/internal/maven/testdata/declared-iso-8859-encoded-pom.xml.base64 similarity index 100% rename from syft/pkg/cataloger/java/internal/maven/test-fixtures/declared-iso-8859-encoded-pom.xml.base64 rename to syft/pkg/cataloger/java/internal/maven/testdata/declared-iso-8859-encoded-pom.xml.base64 diff --git a/syft/pkg/cataloger/java/internal/maven/test-fixtures/local-repository-settings/.m2/settings.xml b/syft/pkg/cataloger/java/internal/maven/testdata/local-repository-settings/.m2/settings.xml similarity index 100% rename from syft/pkg/cataloger/java/internal/maven/test-fixtures/local-repository-settings/.m2/settings.xml rename to syft/pkg/cataloger/java/internal/maven/testdata/local-repository-settings/.m2/settings.xml diff --git a/syft/pkg/cataloger/java/internal/maven/test-fixtures/local/child-1/pom.xml b/syft/pkg/cataloger/java/internal/maven/testdata/local/child-1/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/internal/maven/test-fixtures/local/child-1/pom.xml rename to syft/pkg/cataloger/java/internal/maven/testdata/local/child-1/pom.xml diff --git a/syft/pkg/cataloger/java/internal/maven/test-fixtures/local/child-2/pom.xml b/syft/pkg/cataloger/java/internal/maven/testdata/local/child-2/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/internal/maven/test-fixtures/local/child-2/pom.xml rename to syft/pkg/cataloger/java/internal/maven/testdata/local/child-2/pom.xml diff --git a/syft/pkg/cataloger/java/internal/maven/test-fixtures/local/child-3/pom.xml b/syft/pkg/cataloger/java/internal/maven/testdata/local/child-3/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/internal/maven/test-fixtures/local/child-3/pom.xml rename to syft/pkg/cataloger/java/internal/maven/testdata/local/child-3/pom.xml diff --git a/syft/pkg/cataloger/java/internal/maven/test-fixtures/local/circular-1/pom.xml b/syft/pkg/cataloger/java/internal/maven/testdata/local/circular-1/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/internal/maven/test-fixtures/local/circular-1/pom.xml rename to syft/pkg/cataloger/java/internal/maven/testdata/local/circular-1/pom.xml diff --git a/syft/pkg/cataloger/java/internal/maven/test-fixtures/local/circular-2/pom.xml b/syft/pkg/cataloger/java/internal/maven/testdata/local/circular-2/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/internal/maven/test-fixtures/local/circular-2/pom.xml rename to syft/pkg/cataloger/java/internal/maven/testdata/local/circular-2/pom.xml diff --git a/syft/pkg/cataloger/java/internal/maven/test-fixtures/local/contains-child-1/pom.xml b/syft/pkg/cataloger/java/internal/maven/testdata/local/contains-child-1/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/internal/maven/test-fixtures/local/contains-child-1/pom.xml rename to syft/pkg/cataloger/java/internal/maven/testdata/local/contains-child-1/pom.xml diff --git a/syft/pkg/cataloger/java/internal/maven/test-fixtures/local/parent-1/pom.xml b/syft/pkg/cataloger/java/internal/maven/testdata/local/parent-1/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/internal/maven/test-fixtures/local/parent-1/pom.xml rename to syft/pkg/cataloger/java/internal/maven/testdata/local/parent-1/pom.xml diff --git a/syft/pkg/cataloger/java/internal/maven/test-fixtures/local/parent-2/pom.xml b/syft/pkg/cataloger/java/internal/maven/testdata/local/parent-2/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/internal/maven/test-fixtures/local/parent-2/pom.xml rename to syft/pkg/cataloger/java/internal/maven/testdata/local/parent-2/pom.xml diff --git a/syft/pkg/cataloger/java/internal/maven/test-fixtures/local/parent-3/pom.xml b/syft/pkg/cataloger/java/internal/maven/testdata/local/parent-3/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/internal/maven/test-fixtures/local/parent-3/pom.xml rename to syft/pkg/cataloger/java/internal/maven/testdata/local/parent-3/pom.xml diff --git a/syft/pkg/cataloger/java/internal/maven/test-fixtures/maven-repo/my/org/child-one/1.3.6/child-one-1.3.6.pom b/syft/pkg/cataloger/java/internal/maven/testdata/maven-repo/my/org/child-one/1.3.6/child-one-1.3.6.pom similarity index 100% rename from syft/pkg/cataloger/java/internal/maven/test-fixtures/maven-repo/my/org/child-one/1.3.6/child-one-1.3.6.pom rename to syft/pkg/cataloger/java/internal/maven/testdata/maven-repo/my/org/child-one/1.3.6/child-one-1.3.6.pom diff --git a/syft/pkg/cataloger/java/internal/maven/test-fixtures/maven-repo/my/org/child-two/2.1.90/child-two-2.1.90.pom b/syft/pkg/cataloger/java/internal/maven/testdata/maven-repo/my/org/child-two/2.1.90/child-two-2.1.90.pom similarity index 100% rename from syft/pkg/cataloger/java/internal/maven/test-fixtures/maven-repo/my/org/child-two/2.1.90/child-two-2.1.90.pom rename to syft/pkg/cataloger/java/internal/maven/testdata/maven-repo/my/org/child-two/2.1.90/child-two-2.1.90.pom diff --git a/syft/pkg/cataloger/java/internal/maven/test-fixtures/maven-repo/my/org/circular/1.2.3/circular-1.2.3.pom b/syft/pkg/cataloger/java/internal/maven/testdata/maven-repo/my/org/circular/1.2.3/circular-1.2.3.pom similarity index 100% rename from syft/pkg/cataloger/java/internal/maven/test-fixtures/maven-repo/my/org/circular/1.2.3/circular-1.2.3.pom rename to syft/pkg/cataloger/java/internal/maven/testdata/maven-repo/my/org/circular/1.2.3/circular-1.2.3.pom diff --git a/syft/pkg/cataloger/java/internal/maven/test-fixtures/maven-repo/my/org/parent-one/3.11.0/parent-one-3.11.0.pom b/syft/pkg/cataloger/java/internal/maven/testdata/maven-repo/my/org/parent-one/3.11.0/parent-one-3.11.0.pom similarity index 100% rename from syft/pkg/cataloger/java/internal/maven/test-fixtures/maven-repo/my/org/parent-one/3.11.0/parent-one-3.11.0.pom rename to syft/pkg/cataloger/java/internal/maven/testdata/maven-repo/my/org/parent-one/3.11.0/parent-one-3.11.0.pom diff --git a/syft/pkg/cataloger/java/internal/maven/test-fixtures/maven-repo/my/org/parent-two/13.7.8/parent-two-13.7.8.pom b/syft/pkg/cataloger/java/internal/maven/testdata/maven-repo/my/org/parent-two/13.7.8/parent-two-13.7.8.pom similarity index 100% rename from syft/pkg/cataloger/java/internal/maven/test-fixtures/maven-repo/my/org/parent-two/13.7.8/parent-two-13.7.8.pom rename to syft/pkg/cataloger/java/internal/maven/testdata/maven-repo/my/org/parent-two/13.7.8/parent-two-13.7.8.pom diff --git a/syft/pkg/cataloger/java/internal/maven/test-fixtures/maven-repo/net/shibboleth/parent/7.11.2/parent-7.11.2.pom b/syft/pkg/cataloger/java/internal/maven/testdata/maven-repo/net/shibboleth/parent/7.11.2/parent-7.11.2.pom similarity index 100% rename from syft/pkg/cataloger/java/internal/maven/test-fixtures/maven-repo/net/shibboleth/parent/7.11.2/parent-7.11.2.pom rename to syft/pkg/cataloger/java/internal/maven/testdata/maven-repo/net/shibboleth/parent/7.11.2/parent-7.11.2.pom diff --git a/syft/pkg/cataloger/java/internal/maven/test-fixtures/maven-repo/org/apache/commons/commons-parent/54/commons-parent-54.pom b/syft/pkg/cataloger/java/internal/maven/testdata/maven-repo/org/apache/commons/commons-parent/54/commons-parent-54.pom similarity index 100% rename from syft/pkg/cataloger/java/internal/maven/test-fixtures/maven-repo/org/apache/commons/commons-parent/54/commons-parent-54.pom rename to syft/pkg/cataloger/java/internal/maven/testdata/maven-repo/org/apache/commons/commons-parent/54/commons-parent-54.pom diff --git a/syft/pkg/cataloger/java/internal/maven/test-fixtures/maven-repo/org/junit/junit-bom/5.9.0/junit-bom-5.9.0.pom b/syft/pkg/cataloger/java/internal/maven/testdata/maven-repo/org/junit/junit-bom/5.9.0/junit-bom-5.9.0.pom similarity index 100% rename from syft/pkg/cataloger/java/internal/maven/test-fixtures/maven-repo/org/junit/junit-bom/5.9.0/junit-bom-5.9.0.pom rename to syft/pkg/cataloger/java/internal/maven/testdata/maven-repo/org/junit/junit-bom/5.9.0/junit-bom-5.9.0.pom diff --git a/syft/pkg/cataloger/java/internal/maven/test-fixtures/maven-repo/org/junit/junit-bom/5.9.1/junit-bom-5.9.1.pom b/syft/pkg/cataloger/java/internal/maven/testdata/maven-repo/org/junit/junit-bom/5.9.1/junit-bom-5.9.1.pom similarity index 100% rename from syft/pkg/cataloger/java/internal/maven/test-fixtures/maven-repo/org/junit/junit-bom/5.9.1/junit-bom-5.9.1.pom rename to syft/pkg/cataloger/java/internal/maven/testdata/maven-repo/org/junit/junit-bom/5.9.1/junit-bom-5.9.1.pom diff --git a/syft/pkg/cataloger/java/internal/maven/test-fixtures/maven-repo/org/opensaml/opensaml-parent/3.4.6/opensaml-parent-3.4.6.pom b/syft/pkg/cataloger/java/internal/maven/testdata/maven-repo/org/opensaml/opensaml-parent/3.4.6/opensaml-parent-3.4.6.pom similarity index 100% rename from syft/pkg/cataloger/java/internal/maven/test-fixtures/maven-repo/org/opensaml/opensaml-parent/3.4.6/opensaml-parent-3.4.6.pom rename to syft/pkg/cataloger/java/internal/maven/testdata/maven-repo/org/opensaml/opensaml-parent/3.4.6/opensaml-parent-3.4.6.pom diff --git a/syft/pkg/cataloger/java/internal/maven/test-fixtures/undeclared-iso-8859-encoded-pom.xml.base64 b/syft/pkg/cataloger/java/internal/maven/testdata/undeclared-iso-8859-encoded-pom.xml.base64 similarity index 100% rename from syft/pkg/cataloger/java/internal/maven/test-fixtures/undeclared-iso-8859-encoded-pom.xml.base64 rename to syft/pkg/cataloger/java/internal/maven/testdata/undeclared-iso-8859-encoded-pom.xml.base64 diff --git a/syft/pkg/cataloger/java/package_url_test.go b/syft/pkg/cataloger/java/package_url_test.go index 4153adb83..1661f3fdb 100644 --- a/syft/pkg/cataloger/java/package_url_test.go +++ b/syft/pkg/cataloger/java/package_url_test.go @@ -22,7 +22,7 @@ func Test_packageURL(t *testing.T) { Language: pkg.Java, Type: pkg.JavaPkg, Metadata: pkg.JavaArchive{ - VirtualPath: "test-fixtures/java-builds/packages/example-java-app-maven-0.1.0.jar", + VirtualPath: "testdata/java-builds/packages/example-java-app-maven-0.1.0.jar", Manifest: &pkg.JavaManifest{ Main: []pkg.KeyValue{ { @@ -50,7 +50,7 @@ func Test_packageURL(t *testing.T) { Language: pkg.Java, Type: pkg.JavaPkg, Metadata: pkg.JavaArchive{ - VirtualPath: "test-fixtures/java-builds/packages/example-java-app-maven-0.1.0.jar", + VirtualPath: "testdata/java-builds/packages/example-java-app-maven-0.1.0.jar", Manifest: &pkg.JavaManifest{ Main: []pkg.KeyValue{ { @@ -78,7 +78,7 @@ func Test_packageURL(t *testing.T) { Language: pkg.Java, Type: pkg.JavaPkg, Metadata: pkg.JavaArchive{ - VirtualPath: "test-fixtures/java-builds/packages/example-java-app-maven-0.1.0.jar", + VirtualPath: "testdata/java-builds/packages/example-java-app-maven-0.1.0.jar", Manifest: &pkg.JavaManifest{ Main: []pkg.KeyValue{ { @@ -108,7 +108,7 @@ func Test_packageURL(t *testing.T) { Language: pkg.Java, Type: pkg.JavaPkg, Metadata: pkg.JavaArchive{ - VirtualPath: "test-fixtures/java-builds/packages/example-java-app-maven-0.1.0.jar", + VirtualPath: "testdata/java-builds/packages/example-java-app-maven-0.1.0.jar", Manifest: &pkg.JavaManifest{ Main: []pkg.KeyValue{ { diff --git a/syft/pkg/cataloger/java/parse_gradle_lockfile_test.go b/syft/pkg/cataloger/java/parse_gradle_lockfile_test.go index 3208d937d..d6fc4c2a8 100644 --- a/syft/pkg/cataloger/java/parse_gradle_lockfile_test.go +++ b/syft/pkg/cataloger/java/parse_gradle_lockfile_test.go @@ -14,7 +14,7 @@ func Test_parserGradleLockfile(t *testing.T) { expected []pkg.Package }{ { - input: "test-fixtures/gradle/gradle.lockfile", + input: "testdata/gradle/gradle.lockfile", expected: []pkg.Package{ { Name: "commons-text", diff --git a/syft/pkg/cataloger/java/parse_java_manifest_test.go b/syft/pkg/cataloger/java/parse_java_manifest_test.go index 0ef913679..7673fab62 100644 --- a/syft/pkg/cataloger/java/parse_java_manifest_test.go +++ b/syft/pkg/cataloger/java/parse_java_manifest_test.go @@ -17,7 +17,7 @@ func TestParseJavaManifest(t *testing.T) { expected pkg.JavaManifest }{ { - fixture: "test-fixtures/manifest/small", + fixture: "testdata/manifest/small", expected: pkg.JavaManifest{ Main: pkg.KeyValues{ {Key: "Manifest-Version", Value: "1.0"}, @@ -25,7 +25,7 @@ func TestParseJavaManifest(t *testing.T) { }, }, { - fixture: "test-fixtures/manifest/standard-info", + fixture: "testdata/manifest/standard-info", expected: pkg.JavaManifest{ Main: pkg.KeyValues{ {Key: "Manifest-Version", Value: "1.0"}, @@ -40,7 +40,7 @@ func TestParseJavaManifest(t *testing.T) { }, }, { - fixture: "test-fixtures/manifest/extra-info", + fixture: "testdata/manifest/extra-info", expected: pkg.JavaManifest{ Main: []pkg.KeyValue{ { @@ -81,7 +81,7 @@ func TestParseJavaManifest(t *testing.T) { }, }, { - fixture: "test-fixtures/manifest/extra-empty-lines", + fixture: "testdata/manifest/extra-empty-lines", expected: pkg.JavaManifest{ Main: pkg.KeyValues{ { @@ -116,7 +116,7 @@ func TestParseJavaManifest(t *testing.T) { }, }, { - fixture: "test-fixtures/manifest/continuation", + fixture: "testdata/manifest/continuation", expected: pkg.JavaManifest{ Main: pkg.KeyValues{ { @@ -132,7 +132,7 @@ func TestParseJavaManifest(t *testing.T) { }, { // regression test, we should always keep the full version - fixture: "test-fixtures/manifest/version-with-date", + fixture: "testdata/manifest/version-with-date", expected: pkg.JavaManifest{ Main: []pkg.KeyValue{ { @@ -149,7 +149,7 @@ func TestParseJavaManifest(t *testing.T) { { // regression test, we should not trim space and choke of empty space // https://github.com/anchore/syft/issues/2179 - fixture: "test-fixtures/manifest/leading-space", + fixture: "testdata/manifest/leading-space", expected: pkg.JavaManifest{ Main: []pkg.KeyValue{ { diff --git a/syft/pkg/cataloger/java/parse_pom_properties_test.go b/syft/pkg/cataloger/java/parse_pom_properties_test.go index 97dce0686..08ad774b9 100644 --- a/syft/pkg/cataloger/java/parse_pom_properties_test.go +++ b/syft/pkg/cataloger/java/parse_pom_properties_test.go @@ -15,7 +15,7 @@ func TestParseJavaPomProperties(t *testing.T) { }{ { expected: pkg.JavaPomProperties{ - Path: "test-fixtures/pom/small.pom.properties", + Path: "testdata/pom/small.pom.properties", GroupID: "org.anchore", ArtifactID: "example-java-app-maven", Version: "0.1.0", @@ -23,7 +23,7 @@ func TestParseJavaPomProperties(t *testing.T) { }, { expected: pkg.JavaPomProperties{ - Path: "test-fixtures/pom/extra.pom.properties", + Path: "testdata/pom/extra.pom.properties", GroupID: "org.anchore", ArtifactID: "example-java-app-maven", Version: "0.1.0", @@ -36,7 +36,7 @@ func TestParseJavaPomProperties(t *testing.T) { }, { expected: pkg.JavaPomProperties{ - Path: "test-fixtures/pom/colon-delimited.pom.properties", + Path: "testdata/pom/colon-delimited.pom.properties", GroupID: "org.anchore", ArtifactID: "example-java-app-maven", Version: "0.1.0", @@ -44,7 +44,7 @@ func TestParseJavaPomProperties(t *testing.T) { }, { expected: pkg.JavaPomProperties{ - Path: "test-fixtures/pom/equals-delimited-with-colons.pom.properties", + Path: "testdata/pom/equals-delimited-with-colons.pom.properties", GroupID: "org.anchore", ArtifactID: "example-java:app-maven", Version: "0.1.0:something", @@ -52,7 +52,7 @@ func TestParseJavaPomProperties(t *testing.T) { }, { expected: pkg.JavaPomProperties{ - Path: "test-fixtures/pom/colon-delimited-with-equals.pom.properties", + Path: "testdata/pom/colon-delimited-with-equals.pom.properties", GroupID: "org.anchore", ArtifactID: "example-java=app-maven", Version: "0.1.0=something", diff --git a/syft/pkg/cataloger/java/parse_pom_xml_test.go b/syft/pkg/cataloger/java/parse_pom_xml_test.go index 26d4a4f40..8d7c81b26 100644 --- a/syft/pkg/cataloger/java/parse_pom_xml_test.go +++ b/syft/pkg/cataloger/java/parse_pom_xml_test.go @@ -82,7 +82,7 @@ func Test_parsePomXML(t *testing.T) { expectedRelationships []artifact.Relationship }{ { - dir: "test-fixtures/pom/example-java-app-maven", + dir: "testdata/pom/example-java-app-maven", expected: []pkg.Package{ exampleJavaAppMaven, jodaTime, @@ -122,8 +122,8 @@ func Test_parsePomXML(t *testing.T) { } func Test_parseCommonsTextPomXMLProject(t *testing.T) { - mavenLocalRepoDir := "internal/maven/test-fixtures/maven-repo" - mavenBaseURL := maventest.MockRepo(t, "internal/maven/test-fixtures/maven-repo") + mavenLocalRepoDir := "internal/maven/testdata/maven-repo" + mavenBaseURL := maventest.MockRepo(t, "internal/maven/testdata/maven-repo") tests := []struct { name string @@ -133,7 +133,7 @@ func Test_parseCommonsTextPomXMLProject(t *testing.T) { }{ { name: "no resolution", - dir: "test-fixtures/pom/commons-text-1.10.0", + dir: "testdata/pom/commons-text-1.10.0", config: ArchiveCatalogerConfig{ UseNetwork: false, UseMavenLocalRepository: false, @@ -142,7 +142,7 @@ func Test_parseCommonsTextPomXMLProject(t *testing.T) { }, { name: "use network", - dir: "test-fixtures/pom/commons-text-1.10.0", + dir: "testdata/pom/commons-text-1.10.0", config: ArchiveCatalogerConfig{ UseNetwork: true, MavenBaseURL: mavenBaseURL, @@ -152,7 +152,7 @@ func Test_parseCommonsTextPomXMLProject(t *testing.T) { }, { name: "use local repository", - dir: "test-fixtures/pom/commons-text-1.10.0", + dir: "testdata/pom/commons-text-1.10.0", config: ArchiveCatalogerConfig{ UseNetwork: false, UseMavenLocalRepository: true, @@ -162,7 +162,7 @@ func Test_parseCommonsTextPomXMLProject(t *testing.T) { }, { name: "transitive dependencies", - dir: "test-fixtures/pom/transitive-top-level", + dir: "testdata/pom/transitive-top-level", config: ArchiveCatalogerConfig{ UseNetwork: false, UseMavenLocalRepository: true, @@ -203,7 +203,7 @@ func Test_parsePomXMLProject(t *testing.T) { { name: "no license info", project: &pkg.JavaPomProject{ - Path: "test-fixtures/pom/commons-codec.pom.xml", + Path: "testdata/pom/commons-codec.pom.xml", Parent: &pkg.JavaPomParent{ GroupID: "org.apache.commons", ArtifactID: "commons-parent", @@ -220,7 +220,7 @@ func Test_parsePomXMLProject(t *testing.T) { { name: "with license data", project: &pkg.JavaPomProject{ - Path: "test-fixtures/pom/neo4j-license-maven-plugin.pom.xml", + Path: "testdata/pom/neo4j-license-maven-plugin.pom.xml", Parent: &pkg.JavaPomParent{ GroupID: "org.sonatype.oss", ArtifactID: "oss-parent", @@ -360,10 +360,10 @@ func Test_cleanDescription(t *testing.T) { } func Test_resolveLicenses(t *testing.T) { - mavenURL := maventest.MockRepo(t, "internal/maven/test-fixtures/maven-repo") - localM2 := "internal/maven/test-fixtures/maven-repo" - localDir := "internal/maven/test-fixtures/local" - containingDir := "internal/maven/test-fixtures/local/contains-child-1" + mavenURL := maventest.MockRepo(t, "internal/maven/testdata/maven-repo") + localM2 := "internal/maven/testdata/maven-repo" + localDir := "internal/maven/testdata/local" + containingDir := "internal/maven/testdata/local/contains-child-1" expectedLicenses := []pkg.License{ { @@ -459,7 +459,7 @@ func Test_resolveLicenses(t *testing.T) { func Test_corruptPomXml(t *testing.T) { c := NewPomCataloger(DefaultArchiveCatalogerConfig()) pkgtest.NewCatalogTester(). - FromDirectory(t, "test-fixtures/corrupt"). + FromDirectory(t, "testdata/corrupt"). WithError(). TestCataloger(t, c) } diff --git a/syft/pkg/cataloger/java/tar_wrapped_archive_parser_test.go b/syft/pkg/cataloger/java/tar_wrapped_archive_parser_test.go index c0f3eef3c..83f0fa3d6 100644 --- a/syft/pkg/cataloger/java/tar_wrapped_archive_parser_test.go +++ b/syft/pkg/cataloger/java/tar_wrapped_archive_parser_test.go @@ -19,21 +19,21 @@ func Test_parseTarWrappedJavaArchive(t *testing.T) { expected []string }{ { - fixture: "test-fixtures/java-builds/packages/example-java-app-maven-0.1.0.tar", + fixture: "testdata/java-builds/packages/example-java-app-maven-0.1.0.tar", expected: []string{ "example-java-app-maven", "joda-time", }, }, { - fixture: "test-fixtures/java-builds/packages/example-java-app-maven-0.1.0.tar.gz", + fixture: "testdata/java-builds/packages/example-java-app-maven-0.1.0.tar.gz", expected: []string{ "example-java-app-maven", "joda-time", }, }, { - fixture: "test-fixtures/java-builds/packages/example-java-app-maven-0.1.0.tgz", + fixture: "testdata/java-builds/packages/example-java-app-maven-0.1.0.tgz", expected: []string{ "example-java-app-maven", "joda-time", @@ -69,7 +69,7 @@ func Test_parseTarWrappedJavaArchive(t *testing.T) { func Test_corruptTarArchive(t *testing.T) { ap := newGenericTarWrappedJavaArchiveParser(DefaultArchiveCatalogerConfig()) pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/corrupt/example.tar"). + FromFile(t, "testdata/corrupt/example.tar"). WithError(). TestParser(t, ap.parseTarWrappedJavaArchive) } diff --git a/syft/pkg/cataloger/java/test-fixtures/Makefile b/syft/pkg/cataloger/java/testdata/Makefile similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/Makefile rename to syft/pkg/cataloger/java/testdata/Makefile diff --git a/syft/pkg/cataloger/java/testdata/corrupt/.gitignore b/syft/pkg/cataloger/java/testdata/corrupt/.gitignore new file mode 100644 index 000000000..5022a8e0b --- /dev/null +++ b/syft/pkg/cataloger/java/testdata/corrupt/.gitignore @@ -0,0 +1,2 @@ +# override root level ignores for test fixtures +!* diff --git a/syft/pkg/cataloger/java/test-fixtures/corrupt/example.jar b/syft/pkg/cataloger/java/testdata/corrupt/example.jar similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/corrupt/example.jar rename to syft/pkg/cataloger/java/testdata/corrupt/example.jar diff --git a/syft/pkg/cataloger/java/test-fixtures/corrupt/example.tar b/syft/pkg/cataloger/java/testdata/corrupt/example.tar similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/corrupt/example.tar rename to syft/pkg/cataloger/java/testdata/corrupt/example.tar diff --git a/syft/pkg/cataloger/java/test-fixtures/corrupt/pom.xml b/syft/pkg/cataloger/java/testdata/corrupt/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/corrupt/pom.xml rename to syft/pkg/cataloger/java/testdata/corrupt/pom.xml diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/.gitignore b/syft/pkg/cataloger/java/testdata/glob-paths/archives/.gitignore similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/.gitignore rename to syft/pkg/cataloger/java/testdata/glob-paths/archives/.gitignore diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tar b/syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tar similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tar rename to syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tar diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tar.br b/syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tar.br similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tar.br rename to syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tar.br diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tar.bz b/syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tar.bz similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tar.bz rename to syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tar.bz diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tar.bz2 b/syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tar.bz2 similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tar.bz2 rename to syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tar.bz2 diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tar.gz b/syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tar.gz similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tar.gz rename to syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tar.gz diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tar.lz4 b/syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tar.lz4 similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tar.lz4 rename to syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tar.lz4 diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tar.sz b/syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tar.sz similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tar.sz rename to syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tar.sz diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tar.xz b/syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tar.xz similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tar.xz rename to syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tar.xz diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tar.zst b/syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tar.zst similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tar.zst rename to syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tar.zst diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tar.zstd b/syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tar.zstd similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tar.zstd rename to syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tar.zstd diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tbr b/syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tbr similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tbr rename to syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tbr diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tbz b/syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tbz similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tbz rename to syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tbz diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tbz2 b/syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tbz2 similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tbz2 rename to syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tbz2 diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tgz b/syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tgz similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tgz rename to syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tgz diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tlz4 b/syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tlz4 similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tlz4 rename to syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tlz4 diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tsz b/syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tsz similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tsz rename to syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tsz diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.txz b/syft/pkg/cataloger/java/testdata/glob-paths/archives/example.txz similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.txz rename to syft/pkg/cataloger/java/testdata/glob-paths/archives/example.txz diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tzst b/syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tzst similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tzst rename to syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tzst diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tzstd b/syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tzstd similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.tzstd rename to syft/pkg/cataloger/java/testdata/glob-paths/archives/example.tzstd diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.zip b/syft/pkg/cataloger/java/testdata/glob-paths/archives/example.zip similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/archives/example.zip rename to syft/pkg/cataloger/java/testdata/glob-paths/archives/example.zip diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/.gitignore b/syft/pkg/cataloger/java/testdata/glob-paths/java-archives/.gitignore similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/.gitignore rename to syft/pkg/cataloger/java/testdata/glob-paths/java-archives/.gitignore diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.ear b/syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.ear similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.ear rename to syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.ear diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.far b/syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.far similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.far rename to syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.far diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.hpi b/syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.hpi similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.hpi rename to syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.hpi diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.jar b/syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.jar similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.jar rename to syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.jar diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.jpi b/syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.jpi similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.jpi rename to syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.jpi diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.kar b/syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.kar similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.kar rename to syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.kar diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.lpkg b/syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.lpkg similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.lpkg rename to syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.lpkg diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.nar b/syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.nar similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.nar rename to syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.nar diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.par b/syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.par similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.par rename to syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.par diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.rar b/syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.rar similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.rar rename to syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.rar diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.sar b/syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.sar similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.sar rename to syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.sar diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.war b/syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.war similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/java-archives/example.war rename to syft/pkg/cataloger/java/testdata/glob-paths/java-archives/example.war diff --git a/syft/pkg/cataloger/java/test-fixtures/glob-paths/src/pom.xml b/syft/pkg/cataloger/java/testdata/glob-paths/src/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/glob-paths/src/pom.xml rename to syft/pkg/cataloger/java/testdata/glob-paths/src/pom.xml diff --git a/syft/pkg/cataloger/java/test-fixtures/graalvm-sbom/micronaut.json b/syft/pkg/cataloger/java/testdata/graalvm-sbom/micronaut.json similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/graalvm-sbom/micronaut.json rename to syft/pkg/cataloger/java/testdata/graalvm-sbom/micronaut.json diff --git a/syft/pkg/cataloger/java/test-fixtures/gradle/.gitignore b/syft/pkg/cataloger/java/testdata/gradle/.gitignore similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/gradle/.gitignore rename to syft/pkg/cataloger/java/testdata/gradle/.gitignore diff --git a/syft/pkg/cataloger/java/test-fixtures/gradle/build.gradle b/syft/pkg/cataloger/java/testdata/gradle/build.gradle similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/gradle/build.gradle rename to syft/pkg/cataloger/java/testdata/gradle/build.gradle diff --git a/syft/pkg/cataloger/java/test-fixtures/gradle/gradle.lockfile b/syft/pkg/cataloger/java/testdata/gradle/gradle.lockfile similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/gradle/gradle.lockfile rename to syft/pkg/cataloger/java/testdata/gradle/gradle.lockfile diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/.gitignore b/syft/pkg/cataloger/java/testdata/jar-metadata/.gitignore similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/.gitignore rename to syft/pkg/cataloger/java/testdata/jar-metadata/.gitignore diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/Makefile b/syft/pkg/cataloger/java/testdata/jar-metadata/Makefile similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/Makefile rename to syft/pkg/cataloger/java/testdata/jar-metadata/Makefile diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/README.md b/syft/pkg/cataloger/java/testdata/jar-metadata/README.md similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/README.md rename to syft/pkg/cataloger/java/testdata/jar-metadata/README.md diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/api-all-2.0.0-sources/META-INF/MANIFEST.MF b/syft/pkg/cataloger/java/testdata/jar-metadata/api-all-2.0.0-sources/META-INF/MANIFEST.MF similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/api-all-2.0.0-sources/META-INF/MANIFEST.MF rename to syft/pkg/cataloger/java/testdata/jar-metadata/api-all-2.0.0-sources/META-INF/MANIFEST.MF diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/api-all-2.0.0-sources/META-INF/maven/org.apache.directory.api/api-all/pom.properties b/syft/pkg/cataloger/java/testdata/jar-metadata/api-all-2.0.0-sources/META-INF/maven/org.apache.directory.api/api-all/pom.properties similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/api-all-2.0.0-sources/META-INF/maven/org.apache.directory.api/api-all/pom.properties rename to syft/pkg/cataloger/java/testdata/jar-metadata/api-all-2.0.0-sources/META-INF/maven/org.apache.directory.api/api-all/pom.properties diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/api-all-2.0.0-sources/META-INF/maven/org.apache.directory.api/api-all/pom.xml b/syft/pkg/cataloger/java/testdata/jar-metadata/api-all-2.0.0-sources/META-INF/maven/org.apache.directory.api/api-all/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/api-all-2.0.0-sources/META-INF/maven/org.apache.directory.api/api-all/pom.xml rename to syft/pkg/cataloger/java/testdata/jar-metadata/api-all-2.0.0-sources/META-INF/maven/org.apache.directory.api/api-all/pom.xml diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/api-all-2.0.0-sources/META-INF/maven/org.apache.directory.api/api-asn1-api/pom.properties b/syft/pkg/cataloger/java/testdata/jar-metadata/api-all-2.0.0-sources/META-INF/maven/org.apache.directory.api/api-asn1-api/pom.properties similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/api-all-2.0.0-sources/META-INF/maven/org.apache.directory.api/api-asn1-api/pom.properties rename to syft/pkg/cataloger/java/testdata/jar-metadata/api-all-2.0.0-sources/META-INF/maven/org.apache.directory.api/api-asn1-api/pom.properties diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/api-all-2.0.0-sources/META-INF/maven/org.apache.directory.api/api-asn1-api/pom.xml b/syft/pkg/cataloger/java/testdata/jar-metadata/api-all-2.0.0-sources/META-INF/maven/org.apache.directory.api/api-asn1-api/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/api-all-2.0.0-sources/META-INF/maven/org.apache.directory.api/api-asn1-api/pom.xml rename to syft/pkg/cataloger/java/testdata/jar-metadata/api-all-2.0.0-sources/META-INF/maven/org.apache.directory.api/api-asn1-api/pom.xml diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/com.fasterxml.jackson.core.jackson-core-2.15.2/META-INF/MANIFEST.MF b/syft/pkg/cataloger/java/testdata/jar-metadata/com.fasterxml.jackson.core.jackson-core-2.15.2/META-INF/MANIFEST.MF similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/com.fasterxml.jackson.core.jackson-core-2.15.2/META-INF/MANIFEST.MF rename to syft/pkg/cataloger/java/testdata/jar-metadata/com.fasterxml.jackson.core.jackson-core-2.15.2/META-INF/MANIFEST.MF diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/com.fasterxml.jackson.core.jackson-core-2.15.2/META-INF/maven/com.fasterxml.jackson.core/jackson-core/pom.xml b/syft/pkg/cataloger/java/testdata/jar-metadata/com.fasterxml.jackson.core.jackson-core-2.15.2/META-INF/maven/com.fasterxml.jackson.core/jackson-core/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/com.fasterxml.jackson.core.jackson-core-2.15.2/META-INF/maven/com.fasterxml.jackson.core/jackson-core/pom.xml rename to syft/pkg/cataloger/java/testdata/jar-metadata/com.fasterxml.jackson.core.jackson-core-2.15.2/META-INF/maven/com.fasterxml.jackson.core/jackson-core/pom.xml diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/commons-lang3-3.12.0/META-INF/MANIFEST.MF b/syft/pkg/cataloger/java/testdata/jar-metadata/commons-lang3-3.12.0/META-INF/MANIFEST.MF similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/commons-lang3-3.12.0/META-INF/MANIFEST.MF rename to syft/pkg/cataloger/java/testdata/jar-metadata/commons-lang3-3.12.0/META-INF/MANIFEST.MF diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/commons-lang3-3.12.0/META-INF/maven/org.apache.commons-lang3/pom.xml b/syft/pkg/cataloger/java/testdata/jar-metadata/commons-lang3-3.12.0/META-INF/maven/org.apache.commons-lang3/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/commons-lang3-3.12.0/META-INF/maven/org.apache.commons-lang3/pom.xml rename to syft/pkg/cataloger/java/testdata/jar-metadata/commons-lang3-3.12.0/META-INF/maven/org.apache.commons-lang3/pom.xml diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/jackson-core-2.15.2/META-INF/MANIFEST.MF b/syft/pkg/cataloger/java/testdata/jar-metadata/jackson-core-2.15.2/META-INF/MANIFEST.MF similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/jackson-core-2.15.2/META-INF/MANIFEST.MF rename to syft/pkg/cataloger/java/testdata/jar-metadata/jackson-core-2.15.2/META-INF/MANIFEST.MF diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/jackson-core-2.15.2/META-INF/maven/com.fasterxml.jackson.core/jackson-core/pom.xml b/syft/pkg/cataloger/java/testdata/jar-metadata/jackson-core-2.15.2/META-INF/maven/com.fasterxml.jackson.core/jackson-core/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/jackson-core-2.15.2/META-INF/maven/com.fasterxml.jackson.core/jackson-core/pom.xml rename to syft/pkg/cataloger/java/testdata/jar-metadata/jackson-core-2.15.2/META-INF/maven/com.fasterxml.jackson.core/jackson-core/pom.xml diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/jenkins-plugins/gradle/2.11/META-INF/MANIFEST.MF b/syft/pkg/cataloger/java/testdata/jar-metadata/jenkins-plugins/gradle/2.11/META-INF/MANIFEST.MF similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/jenkins-plugins/gradle/2.11/META-INF/MANIFEST.MF rename to syft/pkg/cataloger/java/testdata/jar-metadata/jenkins-plugins/gradle/2.11/META-INF/MANIFEST.MF diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/micronaut-aop-4.9.11/META-INF/MANIFEST.MF b/syft/pkg/cataloger/java/testdata/jar-metadata/micronaut-aop-4.9.11/META-INF/MANIFEST.MF similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/micronaut-aop-4.9.11/META-INF/MANIFEST.MF rename to syft/pkg/cataloger/java/testdata/jar-metadata/micronaut-aop-4.9.11/META-INF/MANIFEST.MF diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/micronaut-aop-4.9.11/META-INF/maven/io.micronaut/micronaut-aop/pom.xml b/syft/pkg/cataloger/java/testdata/jar-metadata/micronaut-aop-4.9.11/META-INF/maven/io.micronaut/micronaut-aop/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/micronaut-aop-4.9.11/META-INF/maven/io.micronaut/micronaut-aop/pom.xml rename to syft/pkg/cataloger/java/testdata/jar-metadata/micronaut-aop-4.9.11/META-INF/maven/io.micronaut/micronaut-aop/pom.xml diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/multiple-matching-2.11.5/META-INF/MANIFEST.MF b/syft/pkg/cataloger/java/testdata/jar-metadata/multiple-matching-2.11.5/META-INF/MANIFEST.MF similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/multiple-matching-2.11.5/META-INF/MANIFEST.MF rename to syft/pkg/cataloger/java/testdata/jar-metadata/multiple-matching-2.11.5/META-INF/MANIFEST.MF diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-1/pom.properties b/syft/pkg/cataloger/java/testdata/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-1/pom.properties similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-1/pom.properties rename to syft/pkg/cataloger/java/testdata/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-1/pom.properties diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-1/pom.xml b/syft/pkg/cataloger/java/testdata/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-1/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-1/pom.xml rename to syft/pkg/cataloger/java/testdata/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-1/pom.xml diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-2/pom.properties b/syft/pkg/cataloger/java/testdata/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-2/pom.properties similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-2/pom.properties rename to syft/pkg/cataloger/java/testdata/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-2/pom.properties diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-2/pom.xml b/syft/pkg/cataloger/java/testdata/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-2/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-2/pom.xml rename to syft/pkg/cataloger/java/testdata/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-2/pom.xml diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-3/pom.properties b/syft/pkg/cataloger/java/testdata/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-3/pom.properties similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-3/pom.properties rename to syft/pkg/cataloger/java/testdata/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-3/pom.properties diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-3/pom.xml b/syft/pkg/cataloger/java/testdata/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-3/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-3/pom.xml rename to syft/pkg/cataloger/java/testdata/jar-metadata/multiple-matching-2.11.5/META-INF/maven/org.multiple/multiple-matching-3/pom.xml diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/opensaml-core-3.4.6/META-INF/INDEX.LIST b/syft/pkg/cataloger/java/testdata/jar-metadata/opensaml-core-3.4.6/META-INF/INDEX.LIST similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/opensaml-core-3.4.6/META-INF/INDEX.LIST rename to syft/pkg/cataloger/java/testdata/jar-metadata/opensaml-core-3.4.6/META-INF/INDEX.LIST diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/opensaml-core-3.4.6/META-INF/MANIFEST.MF b/syft/pkg/cataloger/java/testdata/jar-metadata/opensaml-core-3.4.6/META-INF/MANIFEST.MF similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/opensaml-core-3.4.6/META-INF/MANIFEST.MF rename to syft/pkg/cataloger/java/testdata/jar-metadata/opensaml-core-3.4.6/META-INF/MANIFEST.MF diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/opensaml-core-3.4.6/META-INF/maven/org.opensaml/opensaml-core/pom.properties b/syft/pkg/cataloger/java/testdata/jar-metadata/opensaml-core-3.4.6/META-INF/maven/org.opensaml/opensaml-core/pom.properties similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/opensaml-core-3.4.6/META-INF/maven/org.opensaml/opensaml-core/pom.properties rename to syft/pkg/cataloger/java/testdata/jar-metadata/opensaml-core-3.4.6/META-INF/maven/org.opensaml/opensaml-core/pom.properties diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/opensaml-core-3.4.6/META-INF/maven/org.opensaml/opensaml-core/pom.xml b/syft/pkg/cataloger/java/testdata/jar-metadata/opensaml-core-3.4.6/META-INF/maven/org.opensaml/opensaml-core/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/opensaml-core-3.4.6/META-INF/maven/org.opensaml/opensaml-core/pom.xml rename to syft/pkg/cataloger/java/testdata/jar-metadata/opensaml-core-3.4.6/META-INF/maven/org.opensaml/opensaml-core/pom.xml diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/org.multiple-thename/META-INF/MANIFEST.MF b/syft/pkg/cataloger/java/testdata/jar-metadata/org.multiple-thename/META-INF/MANIFEST.MF similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/org.multiple-thename/META-INF/MANIFEST.MF rename to syft/pkg/cataloger/java/testdata/jar-metadata/org.multiple-thename/META-INF/MANIFEST.MF diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/org.multiple-thename/META-INF/maven/com.multiple/thename/pom.properties b/syft/pkg/cataloger/java/testdata/jar-metadata/org.multiple-thename/META-INF/maven/com.multiple/thename/pom.properties similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/org.multiple-thename/META-INF/maven/com.multiple/thename/pom.properties rename to syft/pkg/cataloger/java/testdata/jar-metadata/org.multiple-thename/META-INF/maven/com.multiple/thename/pom.properties diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/org.multiple-thename/META-INF/maven/com.multiple/thename/pom.xml b/syft/pkg/cataloger/java/testdata/jar-metadata/org.multiple-thename/META-INF/maven/com.multiple/thename/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/org.multiple-thename/META-INF/maven/com.multiple/thename/pom.xml rename to syft/pkg/cataloger/java/testdata/jar-metadata/org.multiple-thename/META-INF/maven/com.multiple/thename/pom.xml diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/org.multiple-thename/META-INF/maven/org.multiple/thename/pom.properties b/syft/pkg/cataloger/java/testdata/jar-metadata/org.multiple-thename/META-INF/maven/org.multiple/thename/pom.properties similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/org.multiple-thename/META-INF/maven/org.multiple/thename/pom.properties rename to syft/pkg/cataloger/java/testdata/jar-metadata/org.multiple-thename/META-INF/maven/org.multiple/thename/pom.properties diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/org.multiple-thename/META-INF/maven/org.multiple/thename/pom.xml b/syft/pkg/cataloger/java/testdata/jar-metadata/org.multiple-thename/META-INF/maven/org.multiple/thename/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/org.multiple-thename/META-INF/maven/org.multiple/thename/pom.xml rename to syft/pkg/cataloger/java/testdata/jar-metadata/org.multiple-thename/META-INF/maven/org.multiple/thename/pom.xml diff --git a/syft/pkg/cataloger/java/test-fixtures/jar-metadata/spring-instrumentation-4.3.0-1.0/META-INF/MANIFEST.MF b/syft/pkg/cataloger/java/testdata/jar-metadata/spring-instrumentation-4.3.0-1.0/META-INF/MANIFEST.MF similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jar-metadata/spring-instrumentation-4.3.0-1.0/META-INF/MANIFEST.MF rename to syft/pkg/cataloger/java/testdata/jar-metadata/spring-instrumentation-4.3.0-1.0/META-INF/MANIFEST.MF diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/.gitignore b/syft/pkg/cataloger/java/testdata/java-builds/.gitignore similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/.gitignore rename to syft/pkg/cataloger/java/testdata/java-builds/.gitignore diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/Makefile b/syft/pkg/cataloger/java/testdata/java-builds/Makefile similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/Makefile rename to syft/pkg/cataloger/java/testdata/java-builds/Makefile diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/build-example-java-app-gradle.sh b/syft/pkg/cataloger/java/testdata/java-builds/build-example-java-app-gradle.sh similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/build-example-java-app-gradle.sh rename to syft/pkg/cataloger/java/testdata/java-builds/build-example-java-app-gradle.sh diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/build-example-java-app-maven.sh b/syft/pkg/cataloger/java/testdata/java-builds/build-example-java-app-maven.sh similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/build-example-java-app-maven.sh rename to syft/pkg/cataloger/java/testdata/java-builds/build-example-java-app-maven.sh diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/build-example-java-app-native-image.sh b/syft/pkg/cataloger/java/testdata/java-builds/build-example-java-app-native-image.sh similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/build-example-java-app-native-image.sh rename to syft/pkg/cataloger/java/testdata/java-builds/build-example-java-app-native-image.sh diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/build-example-jenkins-plugin.sh b/syft/pkg/cataloger/java/testdata/java-builds/build-example-jenkins-plugin.sh similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/build-example-jenkins-plugin.sh rename to syft/pkg/cataloger/java/testdata/java-builds/build-example-jenkins-plugin.sh diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/build-example-macho-binary.sh b/syft/pkg/cataloger/java/testdata/java-builds/build-example-macho-binary.sh similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/build-example-macho-binary.sh rename to syft/pkg/cataloger/java/testdata/java-builds/build-example-macho-binary.sh diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/build-example-sb-app-nestedjar.sh b/syft/pkg/cataloger/java/testdata/java-builds/build-example-sb-app-nestedjar.sh similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/build-example-sb-app-nestedjar.sh rename to syft/pkg/cataloger/java/testdata/java-builds/build-example-sb-app-nestedjar.sh diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-java-app/.gitignore b/syft/pkg/cataloger/java/testdata/java-builds/example-java-app/.gitignore similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-java-app/.gitignore rename to syft/pkg/cataloger/java/testdata/java-builds/example-java-app/.gitignore diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-java-app/build.gradle b/syft/pkg/cataloger/java/testdata/java-builds/example-java-app/build.gradle similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-java-app/build.gradle rename to syft/pkg/cataloger/java/testdata/java-builds/example-java-app/build.gradle diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-java-app/gradle.lockfile b/syft/pkg/cataloger/java/testdata/java-builds/example-java-app/gradle.lockfile similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-java-app/gradle.lockfile rename to syft/pkg/cataloger/java/testdata/java-builds/example-java-app/gradle.lockfile diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-java-app/pom.xml b/syft/pkg/cataloger/java/testdata/java-builds/example-java-app/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-java-app/pom.xml rename to syft/pkg/cataloger/java/testdata/java-builds/example-java-app/pom.xml diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-java-app/src/main/java/hello/Greeter.java b/syft/pkg/cataloger/java/testdata/java-builds/example-java-app/src/main/java/hello/Greeter.java similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-java-app/src/main/java/hello/Greeter.java rename to syft/pkg/cataloger/java/testdata/java-builds/example-java-app/src/main/java/hello/Greeter.java diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-java-app/src/main/java/hello/HelloWorld.java b/syft/pkg/cataloger/java/testdata/java-builds/example-java-app/src/main/java/hello/HelloWorld.java similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-java-app/src/main/java/hello/HelloWorld.java rename to syft/pkg/cataloger/java/testdata/java-builds/example-java-app/src/main/java/hello/HelloWorld.java diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/pom.xml b/syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/pom.xml rename to syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/pom.xml diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/src/main/java/io/jenkins/plugins/sample/HelloWorldBuilder.java b/syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/src/main/java/io/jenkins/plugins/sample/HelloWorldBuilder.java similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/src/main/java/io/jenkins/plugins/sample/HelloWorldBuilder.java rename to syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/src/main/java/io/jenkins/plugins/sample/HelloWorldBuilder.java diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/src/main/resources/index.jelly b/syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/src/main/resources/index.jelly similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/src/main/resources/index.jelly rename to syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/src/main/resources/index.jelly diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/config.jelly b/syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/config.jelly similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/config.jelly rename to syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/config.jelly diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/config.properties b/syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/config.properties similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/config.properties rename to syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/config.properties diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/config_fr.properties b/syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/config_fr.properties similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/config_fr.properties rename to syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/config_fr.properties diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/help-name.html b/syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/help-name.html similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/help-name.html rename to syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/help-name.html diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/help-name_fr.html b/syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/help-name_fr.html similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/help-name_fr.html rename to syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/help-name_fr.html diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/help-useFrench.html b/syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/help-useFrench.html similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/help-useFrench.html rename to syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/help-useFrench.html diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/help-useFrench_fr.html b/syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/help-useFrench_fr.html similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/help-useFrench_fr.html rename to syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/HelloWorldBuilder/help-useFrench_fr.html diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/Messages.properties b/syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/Messages.properties similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/Messages.properties rename to syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/Messages.properties diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/Messages_fr.properties b/syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/Messages_fr.properties similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/Messages_fr.properties rename to syft/pkg/cataloger/java/testdata/java-builds/example-jenkins-plugin/src/main/resources/io/jenkins/plugins/sample/Messages_fr.properties diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-sb-app/.gitignore b/syft/pkg/cataloger/java/testdata/java-builds/example-sb-app/.gitignore similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-sb-app/.gitignore rename to syft/pkg/cataloger/java/testdata/java-builds/example-sb-app/.gitignore diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-sb-app/pom.xml b/syft/pkg/cataloger/java/testdata/java-builds/example-sb-app/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-sb-app/pom.xml rename to syft/pkg/cataloger/java/testdata/java-builds/example-sb-app/pom.xml diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-sb-app/src/main/java/com/example/springboot/Application.java b/syft/pkg/cataloger/java/testdata/java-builds/example-sb-app/src/main/java/com/example/springboot/Application.java similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-sb-app/src/main/java/com/example/springboot/Application.java rename to syft/pkg/cataloger/java/testdata/java-builds/example-sb-app/src/main/java/com/example/springboot/Application.java diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-sb-app/src/main/java/com/example/springboot/HelloController.java b/syft/pkg/cataloger/java/testdata/java-builds/example-sb-app/src/main/java/com/example/springboot/HelloController.java similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-sb-app/src/main/java/com/example/springboot/HelloController.java rename to syft/pkg/cataloger/java/testdata/java-builds/example-sb-app/src/main/java/com/example/springboot/HelloController.java diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-sb-app/src/test/java/com/example/springboot/HelloControllerIT.java b/syft/pkg/cataloger/java/testdata/java-builds/example-sb-app/src/test/java/com/example/springboot/HelloControllerIT.java similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-sb-app/src/test/java/com/example/springboot/HelloControllerIT.java rename to syft/pkg/cataloger/java/testdata/java-builds/example-sb-app/src/test/java/com/example/springboot/HelloControllerIT.java diff --git a/syft/pkg/cataloger/java/test-fixtures/java-builds/example-sb-app/src/test/java/com/example/springboot/HelloControllerTest.java b/syft/pkg/cataloger/java/testdata/java-builds/example-sb-app/src/test/java/com/example/springboot/HelloControllerTest.java similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/java-builds/example-sb-app/src/test/java/com/example/springboot/HelloControllerTest.java rename to syft/pkg/cataloger/java/testdata/java-builds/example-sb-app/src/test/java/com/example/springboot/HelloControllerTest.java diff --git a/syft/pkg/cataloger/java/test-fixtures/jvm-installs/oracle-jdk-se-8/usr/lib/jvm/.gitignore b/syft/pkg/cataloger/java/testdata/jvm-installs/oracle-jdk-se-8/usr/lib/jvm/.gitignore similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jvm-installs/oracle-jdk-se-8/usr/lib/jvm/.gitignore rename to syft/pkg/cataloger/java/testdata/jvm-installs/oracle-jdk-se-8/usr/lib/jvm/.gitignore diff --git a/syft/pkg/cataloger/java/test-fixtures/jvm-installs/oracle-jdk-se-8/usr/lib/jvm/jdk-1.8-oracle-x64/bin/javac b/syft/pkg/cataloger/java/testdata/jvm-installs/oracle-jdk-se-8/usr/lib/jvm/jdk-1.8-oracle-x64/bin/javac similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jvm-installs/oracle-jdk-se-8/usr/lib/jvm/jdk-1.8-oracle-x64/bin/javac rename to syft/pkg/cataloger/java/testdata/jvm-installs/oracle-jdk-se-8/usr/lib/jvm/jdk-1.8-oracle-x64/bin/javac diff --git a/syft/pkg/cataloger/java/test-fixtures/jvm-installs/oracle-jdk-se-8/usr/lib/jvm/jdk-1.8-oracle-x64/release b/syft/pkg/cataloger/java/testdata/jvm-installs/oracle-jdk-se-8/usr/lib/jvm/jdk-1.8-oracle-x64/release similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jvm-installs/oracle-jdk-se-8/usr/lib/jvm/jdk-1.8-oracle-x64/release rename to syft/pkg/cataloger/java/testdata/jvm-installs/oracle-jdk-se-8/usr/lib/jvm/jdk-1.8-oracle-x64/release diff --git a/syft/pkg/cataloger/java/test-fixtures/jvm-installs/valid-post-jep223/jvm/openjdk/release b/syft/pkg/cataloger/java/testdata/jvm-installs/valid-post-jep223/jvm/openjdk/release similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jvm-installs/valid-post-jep223/jvm/openjdk/release rename to syft/pkg/cataloger/java/testdata/jvm-installs/valid-post-jep223/jvm/openjdk/release diff --git a/syft/pkg/cataloger/java/test-fixtures/jvm-installs/valid-post-jep223/jvm/openjdk/sibling/child/file1.txt b/syft/pkg/cataloger/java/testdata/jvm-installs/valid-post-jep223/jvm/openjdk/sibling/child/file1.txt similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/jvm-installs/valid-post-jep223/jvm/openjdk/sibling/child/file1.txt rename to syft/pkg/cataloger/java/testdata/jvm-installs/valid-post-jep223/jvm/openjdk/sibling/child/file1.txt diff --git a/syft/pkg/cataloger/java/test-fixtures/manifest/continuation b/syft/pkg/cataloger/java/testdata/manifest/continuation similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/manifest/continuation rename to syft/pkg/cataloger/java/testdata/manifest/continuation diff --git a/syft/pkg/cataloger/java/test-fixtures/manifest/extra-empty-lines b/syft/pkg/cataloger/java/testdata/manifest/extra-empty-lines similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/manifest/extra-empty-lines rename to syft/pkg/cataloger/java/testdata/manifest/extra-empty-lines diff --git a/syft/pkg/cataloger/java/test-fixtures/manifest/extra-info b/syft/pkg/cataloger/java/testdata/manifest/extra-info similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/manifest/extra-info rename to syft/pkg/cataloger/java/testdata/manifest/extra-info diff --git a/syft/pkg/cataloger/java/test-fixtures/manifest/leading-space b/syft/pkg/cataloger/java/testdata/manifest/leading-space similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/manifest/leading-space rename to syft/pkg/cataloger/java/testdata/manifest/leading-space diff --git a/syft/pkg/cataloger/java/test-fixtures/manifest/small b/syft/pkg/cataloger/java/testdata/manifest/small similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/manifest/small rename to syft/pkg/cataloger/java/testdata/manifest/small diff --git a/syft/pkg/cataloger/java/test-fixtures/manifest/standard-info b/syft/pkg/cataloger/java/testdata/manifest/standard-info similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/manifest/standard-info rename to syft/pkg/cataloger/java/testdata/manifest/standard-info diff --git a/syft/pkg/cataloger/java/test-fixtures/manifest/version-with-date b/syft/pkg/cataloger/java/testdata/manifest/version-with-date similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/manifest/version-with-date rename to syft/pkg/cataloger/java/testdata/manifest/version-with-date diff --git a/syft/pkg/cataloger/java/test-fixtures/pom/colon-delimited-with-equals.pom.properties b/syft/pkg/cataloger/java/testdata/pom/colon-delimited-with-equals.pom.properties similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/pom/colon-delimited-with-equals.pom.properties rename to syft/pkg/cataloger/java/testdata/pom/colon-delimited-with-equals.pom.properties diff --git a/syft/pkg/cataloger/java/test-fixtures/pom/colon-delimited.pom.properties b/syft/pkg/cataloger/java/testdata/pom/colon-delimited.pom.properties similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/pom/colon-delimited.pom.properties rename to syft/pkg/cataloger/java/testdata/pom/colon-delimited.pom.properties diff --git a/syft/pkg/cataloger/java/test-fixtures/pom/commons-codec.pom.xml b/syft/pkg/cataloger/java/testdata/pom/commons-codec.pom.xml similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/pom/commons-codec.pom.xml rename to syft/pkg/cataloger/java/testdata/pom/commons-codec.pom.xml diff --git a/syft/pkg/cataloger/java/test-fixtures/pom/commons-text-1.10.0/pom.xml b/syft/pkg/cataloger/java/testdata/pom/commons-text-1.10.0/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/pom/commons-text-1.10.0/pom.xml rename to syft/pkg/cataloger/java/testdata/pom/commons-text-1.10.0/pom.xml diff --git a/syft/pkg/cataloger/java/test-fixtures/pom/equals-delimited-with-colons.pom.properties b/syft/pkg/cataloger/java/testdata/pom/equals-delimited-with-colons.pom.properties similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/pom/equals-delimited-with-colons.pom.properties rename to syft/pkg/cataloger/java/testdata/pom/equals-delimited-with-colons.pom.properties diff --git a/syft/pkg/cataloger/java/test-fixtures/pom/example-java-app-maven/pom.xml b/syft/pkg/cataloger/java/testdata/pom/example-java-app-maven/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/pom/example-java-app-maven/pom.xml rename to syft/pkg/cataloger/java/testdata/pom/example-java-app-maven/pom.xml diff --git a/syft/pkg/cataloger/java/test-fixtures/pom/extra.pom.properties b/syft/pkg/cataloger/java/testdata/pom/extra.pom.properties similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/pom/extra.pom.properties rename to syft/pkg/cataloger/java/testdata/pom/extra.pom.properties diff --git a/syft/pkg/cataloger/java/test-fixtures/pom/neo4j-license-maven-plugin.pom.xml b/syft/pkg/cataloger/java/testdata/pom/neo4j-license-maven-plugin.pom.xml similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/pom/neo4j-license-maven-plugin.pom.xml rename to syft/pkg/cataloger/java/testdata/pom/neo4j-license-maven-plugin.pom.xml diff --git a/syft/pkg/cataloger/java/test-fixtures/pom/small.pom.properties b/syft/pkg/cataloger/java/testdata/pom/small.pom.properties similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/pom/small.pom.properties rename to syft/pkg/cataloger/java/testdata/pom/small.pom.properties diff --git a/syft/pkg/cataloger/java/test-fixtures/pom/transitive-top-level/pom.xml b/syft/pkg/cataloger/java/testdata/pom/transitive-top-level/pom.xml similarity index 100% rename from syft/pkg/cataloger/java/test-fixtures/pom/transitive-top-level/pom.xml rename to syft/pkg/cataloger/java/testdata/pom/transitive-top-level/pom.xml diff --git a/syft/pkg/cataloger/java/zip_wrapped_archive_parser_test.go b/syft/pkg/cataloger/java/zip_wrapped_archive_parser_test.go index d7987852d..4e6ae5ba3 100644 --- a/syft/pkg/cataloger/java/zip_wrapped_archive_parser_test.go +++ b/syft/pkg/cataloger/java/zip_wrapped_archive_parser_test.go @@ -18,7 +18,7 @@ func Test_parseZipWrappedJavaArchive(t *testing.T) { expected []string }{ { - fixture: "test-fixtures/java-builds/packages/example-java-app-maven-0.1.0.zip", + fixture: "testdata/java-builds/packages/example-java-app-maven-0.1.0.zip", expected: []string{ "example-java-app-maven", "joda-time", diff --git a/syft/pkg/cataloger/javascript/cataloger_test.go b/syft/pkg/cataloger/javascript/cataloger_test.go index abe4feb31..b137e66ff 100644 --- a/syft/pkg/cataloger/javascript/cataloger_test.go +++ b/syft/pkg/cataloger/javascript/cataloger_test.go @@ -132,7 +132,7 @@ func Test_JavascriptCataloger(t *testing.T) { } pkgtest.NewCatalogTester(). - FromDirectory(t, "test-fixtures/pkg-lock"). + FromDirectory(t, "testdata/pkg-lock"). Expects(expectedPkgs, nil). TestCataloger(t, NewLockCataloger(CatalogerConfig{})) @@ -146,7 +146,7 @@ func Test_PackageCataloger_Globs(t *testing.T) { }{ { name: "obtain package files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "src/package.json", }, @@ -171,7 +171,7 @@ func Test_LockCataloger_Globs(t *testing.T) { }{ { name: "obtain package files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "src/package-lock.json", "src/pnpm-lock.yaml", diff --git a/syft/pkg/cataloger/javascript/parse_package_json_test.go b/syft/pkg/cataloger/javascript/parse_package_json_test.go index 01da032a9..dd05c0b99 100644 --- a/syft/pkg/cataloger/javascript/parse_package_json_test.go +++ b/syft/pkg/cataloger/javascript/parse_package_json_test.go @@ -18,7 +18,7 @@ func TestParsePackageJSON(t *testing.T) { ExpectedPkg pkg.Package }{ { - Fixture: "test-fixtures/pkg-json/package.json", + Fixture: "testdata/pkg-json/package.json", ExpectedPkg: pkg.Package{ Name: "npm", Version: "6.14.6", @@ -26,7 +26,7 @@ func TestParsePackageJSON(t *testing.T) { Type: pkg.NpmPkg, Language: pkg.JavaScript, Licenses: pkg.NewLicenseSet( - pkg.NewLicenseFromLocationsWithContext(ctx, "Artistic-2.0", file.NewLocation("test-fixtures/pkg-json/package.json")), + pkg.NewLicenseFromLocationsWithContext(ctx, "Artistic-2.0", file.NewLocation("testdata/pkg-json/package.json")), ), Metadata: pkg.NpmPackage{ Name: "npm", @@ -39,7 +39,7 @@ func TestParsePackageJSON(t *testing.T) { }, }, { - Fixture: "test-fixtures/pkg-json/package-license-object.json", + Fixture: "testdata/pkg-json/package-license-object.json", ExpectedPkg: pkg.Package{ Name: "npm", Version: "6.14.6", @@ -47,7 +47,7 @@ func TestParsePackageJSON(t *testing.T) { Type: pkg.NpmPkg, Language: pkg.JavaScript, Licenses: pkg.NewLicenseSet( - pkg.NewLicenseFromLocationsWithContext(ctx, "ISC", file.NewLocation("test-fixtures/pkg-json/package-license-object.json")), + pkg.NewLicenseFromLocationsWithContext(ctx, "ISC", file.NewLocation("testdata/pkg-json/package-license-object.json")), ), Metadata: pkg.NpmPackage{ Name: "npm", @@ -60,15 +60,15 @@ func TestParsePackageJSON(t *testing.T) { }, }, { - Fixture: "test-fixtures/pkg-json/package-license-objects.json", + Fixture: "testdata/pkg-json/package-license-objects.json", ExpectedPkg: pkg.Package{ Name: "npm", Version: "6.14.6", PURL: "pkg:npm/npm@6.14.6", Type: pkg.NpmPkg, Licenses: pkg.NewLicenseSet( - pkg.NewLicenseFromLocationsWithContext(ctx, "MIT", file.NewLocation("test-fixtures/pkg-json/package-license-objects.json")), - pkg.NewLicenseFromLocationsWithContext(ctx, "Apache-2.0", file.NewLocation("test-fixtures/pkg-json/package-license-objects.json")), + pkg.NewLicenseFromLocationsWithContext(ctx, "MIT", file.NewLocation("testdata/pkg-json/package-license-objects.json")), + pkg.NewLicenseFromLocationsWithContext(ctx, "Apache-2.0", file.NewLocation("testdata/pkg-json/package-license-objects.json")), ), Language: pkg.JavaScript, Metadata: pkg.NpmPackage{ @@ -82,7 +82,7 @@ func TestParsePackageJSON(t *testing.T) { }, }, { - Fixture: "test-fixtures/pkg-json/package-malformed-license.json", + Fixture: "testdata/pkg-json/package-malformed-license.json", ExpectedPkg: pkg.Package{ Name: "npm", Version: "6.14.6", @@ -100,7 +100,7 @@ func TestParsePackageJSON(t *testing.T) { }, }, { - Fixture: "test-fixtures/pkg-json/package-no-license.json", + Fixture: "testdata/pkg-json/package-no-license.json", ExpectedPkg: pkg.Package{ Name: "npm", Version: "6.14.6", @@ -118,14 +118,14 @@ func TestParsePackageJSON(t *testing.T) { }, }, { - Fixture: "test-fixtures/pkg-json/package-nested-author.json", + Fixture: "testdata/pkg-json/package-nested-author.json", ExpectedPkg: pkg.Package{ Name: "npm", Version: "6.14.6", PURL: "pkg:npm/npm@6.14.6", Type: pkg.NpmPkg, Licenses: pkg.NewLicenseSet( - pkg.NewLicenseFromLocationsWithContext(ctx, "Artistic-2.0", file.NewLocation("test-fixtures/pkg-json/package-nested-author.json")), + pkg.NewLicenseFromLocationsWithContext(ctx, "Artistic-2.0", file.NewLocation("testdata/pkg-json/package-nested-author.json")), ), Language: pkg.JavaScript, Metadata: pkg.NpmPackage{ @@ -139,14 +139,14 @@ func TestParsePackageJSON(t *testing.T) { }, }, { - Fixture: "test-fixtures/pkg-json/package-repo-string.json", + Fixture: "testdata/pkg-json/package-repo-string.json", ExpectedPkg: pkg.Package{ Name: "function-bind", Version: "1.1.1", PURL: "pkg:npm/function-bind@1.1.1", Type: pkg.NpmPkg, Licenses: pkg.NewLicenseSet( - pkg.NewLicenseFromLocationsWithContext(ctx, "MIT", file.NewLocation("test-fixtures/pkg-json/package-repo-string.json")), + pkg.NewLicenseFromLocationsWithContext(ctx, "MIT", file.NewLocation("testdata/pkg-json/package-repo-string.json")), ), Language: pkg.JavaScript, Metadata: pkg.NpmPackage{ @@ -160,14 +160,14 @@ func TestParsePackageJSON(t *testing.T) { }, }, { - Fixture: "test-fixtures/pkg-json/package-private.json", + Fixture: "testdata/pkg-json/package-private.json", ExpectedPkg: pkg.Package{ Name: "npm", Version: "6.14.6", PURL: "pkg:npm/npm@6.14.6", Type: pkg.NpmPkg, Licenses: pkg.NewLicenseSet( - pkg.NewLicenseFromLocationsWithContext(ctx, "Artistic-2.0", file.NewLocation("test-fixtures/pkg-json/package-private.json")), + pkg.NewLicenseFromLocationsWithContext(ctx, "Artistic-2.0", file.NewLocation("testdata/pkg-json/package-private.json")), ), Language: pkg.JavaScript, Metadata: pkg.NpmPackage{ @@ -182,14 +182,14 @@ func TestParsePackageJSON(t *testing.T) { }, }, { - Fixture: "test-fixtures/pkg-json/package-author-non-standard.json", + Fixture: "testdata/pkg-json/package-author-non-standard.json", ExpectedPkg: pkg.Package{ Name: "npm", Version: "6.14.6", PURL: "pkg:npm/npm@6.14.6", Type: pkg.NpmPkg, Licenses: pkg.NewLicenseSet( - pkg.NewLicenseFromLocationsWithContext(ctx, "Artistic-2.0", file.NewLocation("test-fixtures/pkg-json/package-author-non-standard.json")), + pkg.NewLicenseFromLocationsWithContext(ctx, "Artistic-2.0", file.NewLocation("testdata/pkg-json/package-author-non-standard.json")), ), Language: pkg.JavaScript, Metadata: pkg.NpmPackage{ @@ -203,14 +203,14 @@ func TestParsePackageJSON(t *testing.T) { }, }, { - Fixture: "test-fixtures/pkg-json/package-authors-array.json", + Fixture: "testdata/pkg-json/package-authors-array.json", ExpectedPkg: pkg.Package{ Name: "npm", Version: "6.14.6", PURL: "pkg:npm/npm@6.14.6", Type: pkg.NpmPkg, Licenses: pkg.NewLicenseSet( - pkg.NewLicenseFromLocationsWithContext(ctx, "Artistic-2.0", file.NewLocation("test-fixtures/pkg-json/package-authors-array.json")), + pkg.NewLicenseFromLocationsWithContext(ctx, "Artistic-2.0", file.NewLocation("testdata/pkg-json/package-authors-array.json")), ), Language: pkg.JavaScript, Metadata: pkg.NpmPackage{ @@ -224,14 +224,14 @@ func TestParsePackageJSON(t *testing.T) { }, }, { - Fixture: "test-fixtures/pkg-json/package-authors-objects.json", + Fixture: "testdata/pkg-json/package-authors-objects.json", ExpectedPkg: pkg.Package{ Name: "npm", Version: "6.14.6", PURL: "pkg:npm/npm@6.14.6", Type: pkg.NpmPkg, Licenses: pkg.NewLicenseSet( - pkg.NewLicenseFromLocationsWithContext(ctx, "Artistic-2.0", file.NewLocation("test-fixtures/pkg-json/package-authors-objects.json")), + pkg.NewLicenseFromLocationsWithContext(ctx, "Artistic-2.0", file.NewLocation("testdata/pkg-json/package-authors-objects.json")), ), Language: pkg.JavaScript, Metadata: pkg.NpmPackage{ @@ -245,14 +245,14 @@ func TestParsePackageJSON(t *testing.T) { }, }, { - Fixture: "test-fixtures/pkg-json/package-both-author-and-authors.json", + Fixture: "testdata/pkg-json/package-both-author-and-authors.json", ExpectedPkg: pkg.Package{ Name: "npm", Version: "6.14.6", PURL: "pkg:npm/npm@6.14.6", Type: pkg.NpmPkg, Licenses: pkg.NewLicenseSet( - pkg.NewLicenseFromLocationsWithContext(ctx, "Artistic-2.0", file.NewLocation("test-fixtures/pkg-json/package-both-author-and-authors.json")), + pkg.NewLicenseFromLocationsWithContext(ctx, "Artistic-2.0", file.NewLocation("testdata/pkg-json/package-both-author-and-authors.json")), ), Language: pkg.JavaScript, Metadata: pkg.NpmPackage{ @@ -266,14 +266,14 @@ func TestParsePackageJSON(t *testing.T) { }, }, { - Fixture: "test-fixtures/pkg-json/package-contributors.json", + Fixture: "testdata/pkg-json/package-contributors.json", ExpectedPkg: pkg.Package{ Name: "npm", Version: "6.14.6", PURL: "pkg:npm/npm@6.14.6", Type: pkg.NpmPkg, Licenses: pkg.NewLicenseSet( - pkg.NewLicenseFromLocationsWithContext(ctx, "Artistic-2.0", file.NewLocation("test-fixtures/pkg-json/package-contributors.json")), + pkg.NewLicenseFromLocationsWithContext(ctx, "Artistic-2.0", file.NewLocation("testdata/pkg-json/package-contributors.json")), ), Language: pkg.JavaScript, Metadata: pkg.NpmPackage{ @@ -287,14 +287,14 @@ func TestParsePackageJSON(t *testing.T) { }, }, { - Fixture: "test-fixtures/pkg-json/package-maintainers.json", + Fixture: "testdata/pkg-json/package-maintainers.json", ExpectedPkg: pkg.Package{ Name: "npm", Version: "6.14.6", PURL: "pkg:npm/npm@6.14.6", Type: pkg.NpmPkg, Licenses: pkg.NewLicenseSet( - pkg.NewLicenseFromLocationsWithContext(ctx, "Artistic-2.0", file.NewLocation("test-fixtures/pkg-json/package-maintainers.json")), + pkg.NewLicenseFromLocationsWithContext(ctx, "Artistic-2.0", file.NewLocation("testdata/pkg-json/package-maintainers.json")), ), Language: pkg.JavaScript, Metadata: pkg.NpmPackage{ @@ -308,14 +308,14 @@ func TestParsePackageJSON(t *testing.T) { }, }, { - Fixture: "test-fixtures/pkg-json/package-all-author-fields.json", + Fixture: "testdata/pkg-json/package-all-author-fields.json", ExpectedPkg: pkg.Package{ Name: "npm", Version: "6.14.6", PURL: "pkg:npm/npm@6.14.6", Type: pkg.NpmPkg, Licenses: pkg.NewLicenseSet( - pkg.NewLicenseFromLocationsWithContext(ctx, "Artistic-2.0", file.NewLocation("test-fixtures/pkg-json/package-all-author-fields.json")), + pkg.NewLicenseFromLocationsWithContext(ctx, "Artistic-2.0", file.NewLocation("testdata/pkg-json/package-all-author-fields.json")), ), Language: pkg.JavaScript, Metadata: pkg.NpmPackage{ @@ -340,13 +340,13 @@ func TestParsePackageJSON(t *testing.T) { func Test_corruptPackageJSON(t *testing.T) { pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/corrupt/package.json"). + FromFile(t, "testdata/corrupt/package.json"). WithError(). TestParser(t, parsePackageJSON) } func TestParsePackageJSON_Partial(t *testing.T) { // see https://github.com/anchore/syft/issues/311 - const fixtureFile = "test-fixtures/pkg-json/package-partial.json" + const fixtureFile = "testdata/pkg-json/package-partial.json" // raise package.json files as packages with any information we find, these will be filtered out // according to compliance rules later diff --git a/syft/pkg/cataloger/javascript/parse_package_lock_test.go b/syft/pkg/cataloger/javascript/parse_package_lock_test.go index ef7a9b541..35a51b394 100644 --- a/syft/pkg/cataloger/javascript/parse_package_lock_test.go +++ b/syft/pkg/cataloger/javascript/parse_package_lock_test.go @@ -102,7 +102,7 @@ func TestParsePackageLock(t *testing.T) { Metadata: pkg.NpmPackageLockEntry{Resolved: "https://registry.npmjs.org/wordwrap/-/wordwrap-0.0.3.tgz", Integrity: "sha1-o9XabNXAvAAI03I0u68b7WMFkQc="}, }, } - fixture := "test-fixtures/pkg-lock/package-lock.json" + fixture := "testdata/pkg-lock/package-lock.json" for i := range expectedPkgs { expectedPkgs[i].Locations.Add(file.NewLocation(fixture)) } @@ -113,7 +113,7 @@ func TestParsePackageLock(t *testing.T) { func TestParsePackageLockV2(t *testing.T) { ctx := context.TODO() - fixture := "test-fixtures/pkg-lock/package-lock-2.json" + fixture := "testdata/pkg-lock/package-lock-2.json" var expectedRelationships []artifact.Relationship expectedPkgs := []pkg.Package{ { @@ -199,7 +199,7 @@ func TestParsePackageLockV2(t *testing.T) { } func TestParsePackageLockV3(t *testing.T) { - fixture := "test-fixtures/pkg-lock/package-lock-3.json" + fixture := "testdata/pkg-lock/package-lock-3.json" var expectedRelationships []artifact.Relationship expectedPkgs := []pkg.Package{ { @@ -302,8 +302,8 @@ func TestParsePackageLockAlias(t *testing.T) { }, } - packageLockV1 := "test-fixtures/pkg-lock/alias-package-lock-1.json" - packageLockV2 := "test-fixtures/pkg-lock/alias-package-lock-2.json" + packageLockV1 := "testdata/pkg-lock/alias-package-lock-1.json" + packageLockV2 := "testdata/pkg-lock/alias-package-lock-2.json" packageLocks := []string{packageLockV1, packageLockV2} v2Pkg := pkg.Package{ @@ -356,7 +356,7 @@ func TestParsePackageLockAlias(t *testing.T) { func TestParsePackageLockLicenseWithArray(t *testing.T) { ctx := context.TODO() - fixture := "test-fixtures/pkg-lock/array-license-package-lock.json" + fixture := "testdata/pkg-lock/array-license-package-lock.json" var expectedRelationships []artifact.Relationship expectedPkgs := []pkg.Package{ { @@ -418,7 +418,7 @@ func TestParsePackageLockLicenseWithArray(t *testing.T) { func Test_corruptPackageLock(t *testing.T) { gap := newGenericPackageLockAdapter(DefaultCatalogerConfig()) pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/corrupt/package-lock.json"). + FromFile(t, "testdata/corrupt/package-lock.json"). WithError(). TestParser(t, gap.parsePackageLock) } diff --git a/syft/pkg/cataloger/javascript/parse_pnpm_lock_test.go b/syft/pkg/cataloger/javascript/parse_pnpm_lock_test.go index e5fe882be..307375ade 100644 --- a/syft/pkg/cataloger/javascript/parse_pnpm_lock_test.go +++ b/syft/pkg/cataloger/javascript/parse_pnpm_lock_test.go @@ -16,7 +16,7 @@ import ( func TestParsePnpmLock(t *testing.T) { var expectedRelationships []artifact.Relationship - fixture := "test-fixtures/pnpm/pnpm-lock.yaml" + fixture := "testdata/pnpm/pnpm-lock.yaml" locationSet := file.NewLocationSet(file.NewLocation(fixture)) @@ -68,7 +68,7 @@ func TestParsePnpmLock(t *testing.T) { func TestParsePnpmLock_ExcludeDevDependencies(t *testing.T) { var expectedRelationships []artifact.Relationship - fixture := "test-fixtures/pnpm/pnpm-lock.yaml" + fixture := "testdata/pnpm/pnpm-lock.yaml" locationSet := file.NewLocationSet(file.NewLocation(fixture)) @@ -108,7 +108,7 @@ func TestParsePnpmLock_ExcludeDevDependencies(t *testing.T) { func TestParsePnpmV6Lock(t *testing.T) { var expectedRelationships []artifact.Relationship - fixture := "test-fixtures/pnpm-v6/pnpm-lock.yaml" + fixture := "testdata/pnpm-v6/pnpm-lock.yaml" locationSet := file.NewLocationSet(file.NewLocation(fixture)) @@ -306,7 +306,7 @@ func TestParsePnpmV6Lock(t *testing.T) { func TestParsePnpmLockV9(t *testing.T) { var expectedRelationships []artifact.Relationship - fixture := "test-fixtures/pnpm-v9/pnpm-lock.yaml" + fixture := "testdata/pnpm-v9/pnpm-lock.yaml" locationSet := file.NewLocationSet(file.NewLocation(fixture)) expected := []pkg.Package{ @@ -354,7 +354,7 @@ func TestParsePnpmLockV9(t *testing.T) { func TestParsePnpmLockV9WithDependencies(t *testing.T) { adapter := newGenericPnpmLockAdapter(CatalogerConfig{}) - fixture := "test-fixtures/pnpm-v9-snapshots/pnpm-lock.yaml" + fixture := "testdata/pnpm-v9-snapshots/pnpm-lock.yaml" locationSet := file.NewLocationSet(file.NewLocation(fixture)) expectedPkgs := []pkg.Package{ { @@ -465,7 +465,7 @@ func TestParsePnpmLockV9WithDependencies(t *testing.T) { func TestSearchPnpmForLicenses(t *testing.T) { ctx := context.TODO() - fixture := "test-fixtures/pnpm-remote/pnpm-lock.yaml" + fixture := "testdata/pnpm-remote/pnpm-lock.yaml" locations := file.NewLocationSet(file.NewLocation(fixture)) mux, url, teardown := setupNpmRegistry() defer teardown() @@ -483,7 +483,7 @@ func TestSearchPnpmForLicenses(t *testing.T) { { // https://registry.npmjs.org/nanoid/3.3.4 path: "/nanoid/3.3.4", - handler: generateMockNpmRegistryHandler("test-fixtures/pnpm-remote/registry_response.json"), + handler: generateMockNpmRegistryHandler("testdata/pnpm-remote/registry_response.json"), }, }, expectedPackages: []pkg.Package{ @@ -519,7 +519,7 @@ func TestSearchPnpmForLicenses(t *testing.T) { func Test_corruptPnpmLock(t *testing.T) { adapter := newGenericPnpmLockAdapter(CatalogerConfig{}) pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/corrupt/pnpm-lock.yaml"). + FromFile(t, "testdata/corrupt/pnpm-lock.yaml"). WithError(). TestParser(t, adapter.parsePnpmLock) } diff --git a/syft/pkg/cataloger/javascript/parse_yarn_lock_test.go b/syft/pkg/cataloger/javascript/parse_yarn_lock_test.go index 38b84ee37..cf308b194 100644 --- a/syft/pkg/cataloger/javascript/parse_yarn_lock_test.go +++ b/syft/pkg/cataloger/javascript/parse_yarn_lock_test.go @@ -17,7 +17,7 @@ import ( ) func TestParseYarnBerry(t *testing.T) { - fixture := "test-fixtures/yarn-berry/yarn.lock" + fixture := "testdata/yarn-berry/yarn.lock" locations := file.NewLocationSet(file.NewLocation(fixture)) expectedPkgs := []pkg.Package{ @@ -206,7 +206,7 @@ func TestParseYarnBerry(t *testing.T) { func TestParseYarnLock(t *testing.T) { var expectedRelationships []artifact.Relationship - fixture := "test-fixtures/yarn/yarn.lock" + fixture := "testdata/yarn/yarn.lock" locations := file.NewLocationSet(file.NewLocation(fixture)) expectedPkgs := []pkg.Package{ @@ -361,7 +361,7 @@ func TestParseYarnLock(t *testing.T) { } func TestParseYarnLockWithRelationships(t *testing.T) { - fixture := "test-fixtures/yarn-v1-deps/yarn.lock" + fixture := "testdata/yarn-v1-deps/yarn.lock" locations := file.NewLocationSet(file.NewLocation(fixture)) expectedPkgs := []pkg.Package{ @@ -530,7 +530,7 @@ func TestParseYarnLockWithRelationships(t *testing.T) { } func TestParseYarnLockWithDuplicates(t *testing.T) { var expectedRelationships []artifact.Relationship - fixture := "test-fixtures/yarn-dups/yarn.lock" + fixture := "testdata/yarn-dups/yarn.lock" locations := file.NewLocationSet(file.NewLocation(fixture)) expectedPkgs := []pkg.Package{ @@ -612,7 +612,7 @@ type handlerPath struct { func TestSearchYarnForLicenses(t *testing.T) { ctx := context.TODO() - fixture := "test-fixtures/yarn-remote/yarn.lock" + fixture := "testdata/yarn-remote/yarn.lock" locations := file.NewLocationSet(file.NewLocation(fixture)) mux, url, teardown := setupYarnRegistry() defer teardown() @@ -630,7 +630,7 @@ func TestSearchYarnForLicenses(t *testing.T) { { // https://registry.yarnpkg.com/@babel/code-frame/7.10.4 path: "/@babel/code-frame/7.10.4", - handler: generateMockYarnRegistryHandler("test-fixtures/yarn-remote/registry_response.json"), + handler: generateMockYarnRegistryHandler("testdata/yarn-remote/registry_response.json"), }, }, expectedPackages: []pkg.Package{ @@ -748,7 +748,7 @@ func TestParseYarnLock_DevDependencies(t *testing.T) { }{ { name: "v1 include dev dependencies", - fixtureDir: "test-fixtures/yarn-dev-deps", + fixtureDir: "testdata/yarn-dev-deps", includeDev: true, expected: func(locations file.LocationSet) ([]pkg.Package, []artifact.Relationship) { pkgs := []pkg.Package{ @@ -826,7 +826,7 @@ func TestParseYarnLock_DevDependencies(t *testing.T) { }, { name: "v1 exclude dev dependencies", - fixtureDir: "test-fixtures/yarn-dev-deps", + fixtureDir: "testdata/yarn-dev-deps", includeDev: false, expected: func(locations file.LocationSet) ([]pkg.Package, []artifact.Relationship) { pkgs := []pkg.Package{ @@ -871,7 +871,7 @@ func TestParseYarnLock_DevDependencies(t *testing.T) { }, { name: "v2 (berry) include dev dependencies", - fixtureDir: "test-fixtures/yarn-berry-dev-deps", + fixtureDir: "testdata/yarn-berry-dev-deps", includeDev: true, expected: func(locations file.LocationSet) ([]pkg.Package, []artifact.Relationship) { pkgs := []pkg.Package{ @@ -947,7 +947,7 @@ func TestParseYarnLock_DevDependencies(t *testing.T) { }, { name: "v2 (berry) exclude dev dependencies", - fixtureDir: "test-fixtures/yarn-berry-dev-deps", + fixtureDir: "testdata/yarn-berry-dev-deps", includeDev: false, expected: func(locations file.LocationSet) ([]pkg.Package, []artifact.Relationship) { pkgs := []pkg.Package{ diff --git a/syft/pkg/cataloger/javascript/test-fixtures/corrupt/package-lock.json b/syft/pkg/cataloger/javascript/testdata/corrupt/package-lock.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/corrupt/package-lock.json rename to syft/pkg/cataloger/javascript/testdata/corrupt/package-lock.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/corrupt/package.json b/syft/pkg/cataloger/javascript/testdata/corrupt/package.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/corrupt/package.json rename to syft/pkg/cataloger/javascript/testdata/corrupt/package.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/corrupt/pnpm-lock.yaml b/syft/pkg/cataloger/javascript/testdata/corrupt/pnpm-lock.yaml similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/corrupt/pnpm-lock.yaml rename to syft/pkg/cataloger/javascript/testdata/corrupt/pnpm-lock.yaml diff --git a/syft/pkg/cataloger/javascript/test-fixtures/glob-paths/src/package-lock.json b/syft/pkg/cataloger/javascript/testdata/glob-paths/src/package-lock.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/glob-paths/src/package-lock.json rename to syft/pkg/cataloger/javascript/testdata/glob-paths/src/package-lock.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/glob-paths/src/package.json b/syft/pkg/cataloger/javascript/testdata/glob-paths/src/package.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/glob-paths/src/package.json rename to syft/pkg/cataloger/javascript/testdata/glob-paths/src/package.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/glob-paths/src/pnpm-lock.yaml b/syft/pkg/cataloger/javascript/testdata/glob-paths/src/pnpm-lock.yaml similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/glob-paths/src/pnpm-lock.yaml rename to syft/pkg/cataloger/javascript/testdata/glob-paths/src/pnpm-lock.yaml diff --git a/syft/pkg/cataloger/javascript/test-fixtures/glob-paths/src/yarn.lock b/syft/pkg/cataloger/javascript/testdata/glob-paths/src/yarn.lock similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/glob-paths/src/yarn.lock rename to syft/pkg/cataloger/javascript/testdata/glob-paths/src/yarn.lock diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-all-author-fields.json b/syft/pkg/cataloger/javascript/testdata/pkg-json/package-all-author-fields.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-all-author-fields.json rename to syft/pkg/cataloger/javascript/testdata/pkg-json/package-all-author-fields.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-author-non-standard.json b/syft/pkg/cataloger/javascript/testdata/pkg-json/package-author-non-standard.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-author-non-standard.json rename to syft/pkg/cataloger/javascript/testdata/pkg-json/package-author-non-standard.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-authors-array.json b/syft/pkg/cataloger/javascript/testdata/pkg-json/package-authors-array.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-authors-array.json rename to syft/pkg/cataloger/javascript/testdata/pkg-json/package-authors-array.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-authors-objects.json b/syft/pkg/cataloger/javascript/testdata/pkg-json/package-authors-objects.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-authors-objects.json rename to syft/pkg/cataloger/javascript/testdata/pkg-json/package-authors-objects.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-both-author-and-authors.json b/syft/pkg/cataloger/javascript/testdata/pkg-json/package-both-author-and-authors.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-both-author-and-authors.json rename to syft/pkg/cataloger/javascript/testdata/pkg-json/package-both-author-and-authors.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-contributors.json b/syft/pkg/cataloger/javascript/testdata/pkg-json/package-contributors.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-contributors.json rename to syft/pkg/cataloger/javascript/testdata/pkg-json/package-contributors.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-license-object.json b/syft/pkg/cataloger/javascript/testdata/pkg-json/package-license-object.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-license-object.json rename to syft/pkg/cataloger/javascript/testdata/pkg-json/package-license-object.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-license-objects.json b/syft/pkg/cataloger/javascript/testdata/pkg-json/package-license-objects.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-license-objects.json rename to syft/pkg/cataloger/javascript/testdata/pkg-json/package-license-objects.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-maintainers.json b/syft/pkg/cataloger/javascript/testdata/pkg-json/package-maintainers.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-maintainers.json rename to syft/pkg/cataloger/javascript/testdata/pkg-json/package-maintainers.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-malformed-license.json b/syft/pkg/cataloger/javascript/testdata/pkg-json/package-malformed-license.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-malformed-license.json rename to syft/pkg/cataloger/javascript/testdata/pkg-json/package-malformed-license.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-nested-author.json b/syft/pkg/cataloger/javascript/testdata/pkg-json/package-nested-author.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-nested-author.json rename to syft/pkg/cataloger/javascript/testdata/pkg-json/package-nested-author.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-no-license.json b/syft/pkg/cataloger/javascript/testdata/pkg-json/package-no-license.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-no-license.json rename to syft/pkg/cataloger/javascript/testdata/pkg-json/package-no-license.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-partial.json b/syft/pkg/cataloger/javascript/testdata/pkg-json/package-partial.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-partial.json rename to syft/pkg/cataloger/javascript/testdata/pkg-json/package-partial.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-private.json b/syft/pkg/cataloger/javascript/testdata/pkg-json/package-private.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-private.json rename to syft/pkg/cataloger/javascript/testdata/pkg-json/package-private.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-repo-string.json b/syft/pkg/cataloger/javascript/testdata/pkg-json/package-repo-string.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package-repo-string.json rename to syft/pkg/cataloger/javascript/testdata/pkg-json/package-repo-string.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package.json b/syft/pkg/cataloger/javascript/testdata/pkg-json/package.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-json/package.json rename to syft/pkg/cataloger/javascript/testdata/pkg-json/package.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-lock/alias-package-lock-1.json b/syft/pkg/cataloger/javascript/testdata/pkg-lock/alias-package-lock-1.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-lock/alias-package-lock-1.json rename to syft/pkg/cataloger/javascript/testdata/pkg-lock/alias-package-lock-1.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-lock/alias-package-lock-2.json b/syft/pkg/cataloger/javascript/testdata/pkg-lock/alias-package-lock-2.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-lock/alias-package-lock-2.json rename to syft/pkg/cataloger/javascript/testdata/pkg-lock/alias-package-lock-2.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-lock/array-license-package-lock.json b/syft/pkg/cataloger/javascript/testdata/pkg-lock/array-license-package-lock.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-lock/array-license-package-lock.json rename to syft/pkg/cataloger/javascript/testdata/pkg-lock/array-license-package-lock.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-lock/node_modules/@actions/core/package.json b/syft/pkg/cataloger/javascript/testdata/pkg-lock/node_modules/@actions/core/package.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-lock/node_modules/@actions/core/package.json rename to syft/pkg/cataloger/javascript/testdata/pkg-lock/node_modules/@actions/core/package.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-lock/node_modules/cowsay/package.json b/syft/pkg/cataloger/javascript/testdata/pkg-lock/node_modules/cowsay/package.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-lock/node_modules/cowsay/package.json rename to syft/pkg/cataloger/javascript/testdata/pkg-lock/node_modules/cowsay/package.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-lock/package-lock-2.json b/syft/pkg/cataloger/javascript/testdata/pkg-lock/package-lock-2.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-lock/package-lock-2.json rename to syft/pkg/cataloger/javascript/testdata/pkg-lock/package-lock-2.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-lock/package-lock-3.json b/syft/pkg/cataloger/javascript/testdata/pkg-lock/package-lock-3.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-lock/package-lock-3.json rename to syft/pkg/cataloger/javascript/testdata/pkg-lock/package-lock-3.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pkg-lock/package-lock.json b/syft/pkg/cataloger/javascript/testdata/pkg-lock/package-lock.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pkg-lock/package-lock.json rename to syft/pkg/cataloger/javascript/testdata/pkg-lock/package-lock.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pnpm-remote/pnpm-lock.yaml b/syft/pkg/cataloger/javascript/testdata/pnpm-remote/pnpm-lock.yaml similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pnpm-remote/pnpm-lock.yaml rename to syft/pkg/cataloger/javascript/testdata/pnpm-remote/pnpm-lock.yaml diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pnpm-remote/registry_response.json b/syft/pkg/cataloger/javascript/testdata/pnpm-remote/registry_response.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pnpm-remote/registry_response.json rename to syft/pkg/cataloger/javascript/testdata/pnpm-remote/registry_response.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pnpm-v6/pnpm-lock.yaml b/syft/pkg/cataloger/javascript/testdata/pnpm-v6/pnpm-lock.yaml similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pnpm-v6/pnpm-lock.yaml rename to syft/pkg/cataloger/javascript/testdata/pnpm-v6/pnpm-lock.yaml diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pnpm-v9-snapshots/pnpm-lock.yaml b/syft/pkg/cataloger/javascript/testdata/pnpm-v9-snapshots/pnpm-lock.yaml similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pnpm-v9-snapshots/pnpm-lock.yaml rename to syft/pkg/cataloger/javascript/testdata/pnpm-v9-snapshots/pnpm-lock.yaml diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pnpm-v9/pnpm-lock.yaml b/syft/pkg/cataloger/javascript/testdata/pnpm-v9/pnpm-lock.yaml similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pnpm-v9/pnpm-lock.yaml rename to syft/pkg/cataloger/javascript/testdata/pnpm-v9/pnpm-lock.yaml diff --git a/syft/pkg/cataloger/javascript/test-fixtures/pnpm/pnpm-lock.yaml b/syft/pkg/cataloger/javascript/testdata/pnpm/pnpm-lock.yaml similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/pnpm/pnpm-lock.yaml rename to syft/pkg/cataloger/javascript/testdata/pnpm/pnpm-lock.yaml diff --git a/syft/pkg/cataloger/javascript/test-fixtures/yarn-berry-dev-deps/package.json b/syft/pkg/cataloger/javascript/testdata/yarn-berry-dev-deps/package.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/yarn-berry-dev-deps/package.json rename to syft/pkg/cataloger/javascript/testdata/yarn-berry-dev-deps/package.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/yarn-berry-dev-deps/yarn.lock b/syft/pkg/cataloger/javascript/testdata/yarn-berry-dev-deps/yarn.lock similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/yarn-berry-dev-deps/yarn.lock rename to syft/pkg/cataloger/javascript/testdata/yarn-berry-dev-deps/yarn.lock diff --git a/syft/pkg/cataloger/javascript/test-fixtures/yarn-berry/yarn.lock b/syft/pkg/cataloger/javascript/testdata/yarn-berry/yarn.lock similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/yarn-berry/yarn.lock rename to syft/pkg/cataloger/javascript/testdata/yarn-berry/yarn.lock diff --git a/syft/pkg/cataloger/javascript/test-fixtures/yarn-dev-deps/package.json b/syft/pkg/cataloger/javascript/testdata/yarn-dev-deps/package.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/yarn-dev-deps/package.json rename to syft/pkg/cataloger/javascript/testdata/yarn-dev-deps/package.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/yarn-dev-deps/yarn.lock b/syft/pkg/cataloger/javascript/testdata/yarn-dev-deps/yarn.lock similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/yarn-dev-deps/yarn.lock rename to syft/pkg/cataloger/javascript/testdata/yarn-dev-deps/yarn.lock diff --git a/syft/pkg/cataloger/javascript/test-fixtures/yarn-dups/yarn.lock b/syft/pkg/cataloger/javascript/testdata/yarn-dups/yarn.lock similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/yarn-dups/yarn.lock rename to syft/pkg/cataloger/javascript/testdata/yarn-dups/yarn.lock diff --git a/syft/pkg/cataloger/javascript/test-fixtures/yarn-remote/registry_response.json b/syft/pkg/cataloger/javascript/testdata/yarn-remote/registry_response.json similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/yarn-remote/registry_response.json rename to syft/pkg/cataloger/javascript/testdata/yarn-remote/registry_response.json diff --git a/syft/pkg/cataloger/javascript/test-fixtures/yarn-remote/yarn.lock b/syft/pkg/cataloger/javascript/testdata/yarn-remote/yarn.lock similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/yarn-remote/yarn.lock rename to syft/pkg/cataloger/javascript/testdata/yarn-remote/yarn.lock diff --git a/syft/pkg/cataloger/javascript/test-fixtures/yarn-v1-deps/yarn.lock b/syft/pkg/cataloger/javascript/testdata/yarn-v1-deps/yarn.lock similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/yarn-v1-deps/yarn.lock rename to syft/pkg/cataloger/javascript/testdata/yarn-v1-deps/yarn.lock diff --git a/syft/pkg/cataloger/javascript/test-fixtures/yarn/yarn.lock b/syft/pkg/cataloger/javascript/testdata/yarn/yarn.lock similarity index 100% rename from syft/pkg/cataloger/javascript/test-fixtures/yarn/yarn.lock rename to syft/pkg/cataloger/javascript/testdata/yarn/yarn.lock diff --git a/syft/pkg/cataloger/kernel/test-fixtures/Makefile b/syft/pkg/cataloger/kernel/testdata/Makefile similarity index 100% rename from syft/pkg/cataloger/kernel/test-fixtures/Makefile rename to syft/pkg/cataloger/kernel/testdata/Makefile diff --git a/syft/pkg/cataloger/kernel/test-fixtures/image-kernel-and-modules/Dockerfile b/syft/pkg/cataloger/kernel/testdata/image-kernel-and-modules/Dockerfile similarity index 100% rename from syft/pkg/cataloger/kernel/test-fixtures/image-kernel-and-modules/Dockerfile rename to syft/pkg/cataloger/kernel/testdata/image-kernel-and-modules/Dockerfile diff --git a/syft/pkg/cataloger/lua/cataloger_test.go b/syft/pkg/cataloger/lua/cataloger_test.go index 750ec9eab..a55bb68f1 100644 --- a/syft/pkg/cataloger/lua/cataloger_test.go +++ b/syft/pkg/cataloger/lua/cataloger_test.go @@ -14,7 +14,7 @@ func Test_PackageCataloger_Globs(t *testing.T) { }{ { name: "obtain package files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "lua/package.rockspec", }, diff --git a/syft/pkg/cataloger/lua/parse_rockspec_test.go b/syft/pkg/cataloger/lua/parse_rockspec_test.go index 85a90be14..f97ecc866 100644 --- a/syft/pkg/cataloger/lua/parse_rockspec_test.go +++ b/syft/pkg/cataloger/lua/parse_rockspec_test.go @@ -18,7 +18,7 @@ func TestParseRockspec(t *testing.T) { ExpectedPkg pkg.Package }{ { - Fixture: "test-fixtures/rockspec/kong-3.7.0-0.rockspec", + Fixture: "testdata/rockspec/kong-3.7.0-0.rockspec", ExpectedPkg: pkg.Package{ Name: "kong", Version: "3.7.0-0", @@ -26,7 +26,7 @@ func TestParseRockspec(t *testing.T) { Type: pkg.LuaRocksPkg, Language: pkg.Lua, Licenses: pkg.NewLicenseSet( - pkg.NewLicenseFromLocationsWithContext(ctx, "Apache-2.0", file.NewLocation("test-fixtures/rockspec/kong-3.7.0-0.rockspec")), + pkg.NewLicenseFromLocationsWithContext(ctx, "Apache-2.0", file.NewLocation("testdata/rockspec/kong-3.7.0-0.rockspec")), ), Metadata: pkg.LuaRocksPackage{ Name: "kong", @@ -71,7 +71,7 @@ func TestParseRockspec(t *testing.T) { }, }, { - Fixture: "test-fixtures/rockspec/lpeg-1.0.2-1.rockspec", + Fixture: "testdata/rockspec/lpeg-1.0.2-1.rockspec", ExpectedPkg: pkg.Package{ Name: "LPeg", Version: "1.0.2-1", @@ -79,7 +79,7 @@ func TestParseRockspec(t *testing.T) { Type: pkg.LuaRocksPkg, Language: pkg.Lua, Licenses: pkg.NewLicenseSet( - pkg.NewLicenseFromLocationsWithContext(ctx, "MIT/X11", file.NewLocation("test-fixtures/rockspec/lpeg-1.0.2-1.rockspec")), + pkg.NewLicenseFromLocationsWithContext(ctx, "MIT/X11", file.NewLocation("testdata/rockspec/lpeg-1.0.2-1.rockspec")), ), Metadata: pkg.LuaRocksPackage{ Name: "LPeg", @@ -95,7 +95,7 @@ func TestParseRockspec(t *testing.T) { }, }, { - Fixture: "test-fixtures/rockspec/kong-pgmoon-1.16.2-1.rockspec", + Fixture: "testdata/rockspec/kong-pgmoon-1.16.2-1.rockspec", ExpectedPkg: pkg.Package{ Name: "kong-pgmoon", Version: "1.16.2-1", @@ -103,7 +103,7 @@ func TestParseRockspec(t *testing.T) { Type: pkg.LuaRocksPkg, Language: pkg.Lua, Licenses: pkg.NewLicenseSet( - pkg.NewLicenseFromLocationsWithContext(ctx, "MIT", file.NewLocation("test-fixtures/rockspec/kong-pgmoon-1.16.2-1.rockspec")), + pkg.NewLicenseFromLocationsWithContext(ctx, "MIT", file.NewLocation("testdata/rockspec/kong-pgmoon-1.16.2-1.rockspec")), ), Metadata: pkg.LuaRocksPackage{ Name: "kong-pgmoon", @@ -120,7 +120,7 @@ func TestParseRockspec(t *testing.T) { }, }, { - Fixture: "test-fixtures/rockspec/luasyslog-2.0.1-1.rockspec", + Fixture: "testdata/rockspec/luasyslog-2.0.1-1.rockspec", ExpectedPkg: pkg.Package{ Name: "luasyslog", Version: "2.0.1-1", @@ -128,7 +128,7 @@ func TestParseRockspec(t *testing.T) { Type: pkg.LuaRocksPkg, Language: pkg.Lua, Licenses: pkg.NewLicenseSet( - pkg.NewLicenseFromLocationsWithContext(ctx, "MIT/X11", file.NewLocation("test-fixtures/rockspec/luasyslog-2.0.1-1.rockspec")), + pkg.NewLicenseFromLocationsWithContext(ctx, "MIT/X11", file.NewLocation("testdata/rockspec/luasyslog-2.0.1-1.rockspec")), ), Metadata: pkg.LuaRocksPackage{ Name: "luasyslog", @@ -156,7 +156,7 @@ func TestParseRockspec(t *testing.T) { func Test_corruptRockspec(t *testing.T) { pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/corrupt/bad-1.23.0-0.rockspec"). + FromFile(t, "testdata/corrupt/bad-1.23.0-0.rockspec"). WithError(). TestParser(t, parseRockspec) } diff --git a/syft/pkg/cataloger/lua/test-fixtures/corrupt/bad-1.23.0-0.rockspec b/syft/pkg/cataloger/lua/testdata/corrupt/bad-1.23.0-0.rockspec similarity index 100% rename from syft/pkg/cataloger/lua/test-fixtures/corrupt/bad-1.23.0-0.rockspec rename to syft/pkg/cataloger/lua/testdata/corrupt/bad-1.23.0-0.rockspec diff --git a/syft/pkg/cataloger/lua/test-fixtures/glob-paths/lua/package.rockspec b/syft/pkg/cataloger/lua/testdata/glob-paths/lua/package.rockspec similarity index 100% rename from syft/pkg/cataloger/lua/test-fixtures/glob-paths/lua/package.rockspec rename to syft/pkg/cataloger/lua/testdata/glob-paths/lua/package.rockspec diff --git a/syft/pkg/cataloger/lua/test-fixtures/rockspec/kong-3.7.0-0.rockspec b/syft/pkg/cataloger/lua/testdata/rockspec/kong-3.7.0-0.rockspec similarity index 100% rename from syft/pkg/cataloger/lua/test-fixtures/rockspec/kong-3.7.0-0.rockspec rename to syft/pkg/cataloger/lua/testdata/rockspec/kong-3.7.0-0.rockspec diff --git a/syft/pkg/cataloger/lua/test-fixtures/rockspec/kong-pgmoon-1.16.2-1.rockspec b/syft/pkg/cataloger/lua/testdata/rockspec/kong-pgmoon-1.16.2-1.rockspec similarity index 100% rename from syft/pkg/cataloger/lua/test-fixtures/rockspec/kong-pgmoon-1.16.2-1.rockspec rename to syft/pkg/cataloger/lua/testdata/rockspec/kong-pgmoon-1.16.2-1.rockspec diff --git a/syft/pkg/cataloger/lua/test-fixtures/rockspec/lpeg-1.0.2-1.rockspec b/syft/pkg/cataloger/lua/testdata/rockspec/lpeg-1.0.2-1.rockspec similarity index 100% rename from syft/pkg/cataloger/lua/test-fixtures/rockspec/lpeg-1.0.2-1.rockspec rename to syft/pkg/cataloger/lua/testdata/rockspec/lpeg-1.0.2-1.rockspec diff --git a/syft/pkg/cataloger/lua/test-fixtures/rockspec/luasyslog-2.0.1-1.rockspec b/syft/pkg/cataloger/lua/testdata/rockspec/luasyslog-2.0.1-1.rockspec similarity index 100% rename from syft/pkg/cataloger/lua/test-fixtures/rockspec/luasyslog-2.0.1-1.rockspec rename to syft/pkg/cataloger/lua/testdata/rockspec/luasyslog-2.0.1-1.rockspec diff --git a/syft/pkg/cataloger/nix/cataloger_test.go b/syft/pkg/cataloger/nix/cataloger_test.go index 59f028094..c73912377 100644 --- a/syft/pkg/cataloger/nix/cataloger_test.go +++ b/syft/pkg/cataloger/nix/cataloger_test.go @@ -149,7 +149,7 @@ func TestCataloger_Directory(t *testing.T) { wantRel []artifact.Relationship }{ { - fixture: "test-fixtures/fixture-1", + fixture: "testdata/fixture-1", wantPkgs: []pkg.Package{ { Name: "glibc", diff --git a/syft/pkg/cataloger/nix/store_cataloger_test.go b/syft/pkg/cataloger/nix/store_cataloger_test.go index e5ef95315..9e9d5a11a 100644 --- a/syft/pkg/cataloger/nix/store_cataloger_test.go +++ b/syft/pkg/cataloger/nix/store_cataloger_test.go @@ -70,7 +70,7 @@ func TestStoreCataloger_Directory(t *testing.T) { wantRel []artifact.Relationship }{ { - fixture: "test-fixtures/fixture-1", + fixture: "testdata/fixture-1", wantPkgs: []pkg.Package{ { Name: "glibc", diff --git a/syft/pkg/cataloger/nix/test-fixtures/fixture-1/.gitignore b/syft/pkg/cataloger/nix/testdata/fixture-1/.gitignore similarity index 100% rename from syft/pkg/cataloger/nix/test-fixtures/fixture-1/.gitignore rename to syft/pkg/cataloger/nix/testdata/fixture-1/.gitignore diff --git a/syft/pkg/cataloger/nix/test-fixtures/fixture-1/nix/store/5av396z8xa13jg89g9jws145c0k26k2x-glibc-2.34-210.drv b/syft/pkg/cataloger/nix/testdata/fixture-1/nix/store/5av396z8xa13jg89g9jws145c0k26k2x-glibc-2.34-210.drv similarity index 100% rename from syft/pkg/cataloger/nix/test-fixtures/fixture-1/nix/store/5av396z8xa13jg89g9jws145c0k26k2x-glibc-2.34-210.drv rename to syft/pkg/cataloger/nix/testdata/fixture-1/nix/store/5av396z8xa13jg89g9jws145c0k26k2x-glibc-2.34-210.drv diff --git a/syft/pkg/cataloger/nix/test-fixtures/fixture-1/nix/store/h0cnbmfcn93xm5dg2x27ixhag1cwndga-glibc-2.34-210-bin/lib/glibc.so b/syft/pkg/cataloger/nix/testdata/fixture-1/nix/store/h0cnbmfcn93xm5dg2x27ixhag1cwndga-glibc-2.34-210-bin/lib/glibc.so similarity index 100% rename from syft/pkg/cataloger/nix/test-fixtures/fixture-1/nix/store/h0cnbmfcn93xm5dg2x27ixhag1cwndga-glibc-2.34-210-bin/lib/glibc.so rename to syft/pkg/cataloger/nix/testdata/fixture-1/nix/store/h0cnbmfcn93xm5dg2x27ixhag1cwndga-glibc-2.34-210-bin/lib/glibc.so diff --git a/syft/pkg/cataloger/nix/test-fixtures/fixture-1/nix/store/h0cnbmfcn93xm5dg2x27ixhag1cwndga-glibc-2.34-210-bin/share/man/glibc.1 b/syft/pkg/cataloger/nix/testdata/fixture-1/nix/store/h0cnbmfcn93xm5dg2x27ixhag1cwndga-glibc-2.34-210-bin/share/man/glibc.1 similarity index 100% rename from syft/pkg/cataloger/nix/test-fixtures/fixture-1/nix/store/h0cnbmfcn93xm5dg2x27ixhag1cwndga-glibc-2.34-210-bin/share/man/glibc.1 rename to syft/pkg/cataloger/nix/testdata/fixture-1/nix/store/h0cnbmfcn93xm5dg2x27ixhag1cwndga-glibc-2.34-210-bin/share/man/glibc.1 diff --git a/syft/pkg/cataloger/nix/test-fixtures/image-nixos-jq-pkg-db/Dockerfile b/syft/pkg/cataloger/nix/testdata/image-nixos-jq-pkg-db/Dockerfile similarity index 100% rename from syft/pkg/cataloger/nix/test-fixtures/image-nixos-jq-pkg-db/Dockerfile rename to syft/pkg/cataloger/nix/testdata/image-nixos-jq-pkg-db/Dockerfile diff --git a/syft/pkg/cataloger/nix/test-fixtures/image-nixos-jq-pkg-db/clean_db.sql b/syft/pkg/cataloger/nix/testdata/image-nixos-jq-pkg-db/clean_db.sql similarity index 100% rename from syft/pkg/cataloger/nix/test-fixtures/image-nixos-jq-pkg-db/clean_db.sql rename to syft/pkg/cataloger/nix/testdata/image-nixos-jq-pkg-db/clean_db.sql diff --git a/syft/pkg/cataloger/nix/test-fixtures/image-nixos-jq-pkg-store/Dockerfile b/syft/pkg/cataloger/nix/testdata/image-nixos-jq-pkg-store/Dockerfile similarity index 100% rename from syft/pkg/cataloger/nix/test-fixtures/image-nixos-jq-pkg-store/Dockerfile rename to syft/pkg/cataloger/nix/testdata/image-nixos-jq-pkg-store/Dockerfile diff --git a/syft/pkg/cataloger/ocaml/cataloger_test.go b/syft/pkg/cataloger/ocaml/cataloger_test.go index b17f13c78..3069fa698 100644 --- a/syft/pkg/cataloger/ocaml/cataloger_test.go +++ b/syft/pkg/cataloger/ocaml/cataloger_test.go @@ -14,7 +14,7 @@ func Test_PackageCataloger_Globs(t *testing.T) { }{ { name: "obtain package files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "opam/alcotest.opam", "opam/ocaml-base-compiler.4.14.0/opam", diff --git a/syft/pkg/cataloger/ocaml/parse_opam_test.go b/syft/pkg/cataloger/ocaml/parse_opam_test.go index 4557aa25e..982da3b15 100644 --- a/syft/pkg/cataloger/ocaml/parse_opam_test.go +++ b/syft/pkg/cataloger/ocaml/parse_opam_test.go @@ -13,10 +13,10 @@ import ( ) func TestParseOpamPackage(t *testing.T) { - fixture1 := "test-fixtures/ocaml-base-compiler.4.14.0/opam" + fixture1 := "testdata/ocaml-base-compiler.4.14.0/opam" location1 := file.NewLocation(fixture1) - fixture2 := "test-fixtures/alcotest.opam" + fixture2 := "testdata/alcotest.opam" location2 := file.NewLocation(fixture2) ctx := context.TODO() tests := []struct { diff --git a/syft/pkg/cataloger/ocaml/test-fixtures/alcotest.opam b/syft/pkg/cataloger/ocaml/testdata/alcotest.opam similarity index 100% rename from syft/pkg/cataloger/ocaml/test-fixtures/alcotest.opam rename to syft/pkg/cataloger/ocaml/testdata/alcotest.opam diff --git a/syft/pkg/cataloger/ocaml/test-fixtures/glob-paths/opam/alcotest.opam b/syft/pkg/cataloger/ocaml/testdata/glob-paths/opam/alcotest.opam similarity index 100% rename from syft/pkg/cataloger/ocaml/test-fixtures/glob-paths/opam/alcotest.opam rename to syft/pkg/cataloger/ocaml/testdata/glob-paths/opam/alcotest.opam diff --git a/syft/pkg/cataloger/ocaml/test-fixtures/glob-paths/opam/ocaml-base-compiler.4.14.0/opam b/syft/pkg/cataloger/ocaml/testdata/glob-paths/opam/ocaml-base-compiler.4.14.0/opam similarity index 100% rename from syft/pkg/cataloger/ocaml/test-fixtures/glob-paths/opam/ocaml-base-compiler.4.14.0/opam rename to syft/pkg/cataloger/ocaml/testdata/glob-paths/opam/ocaml-base-compiler.4.14.0/opam diff --git a/syft/pkg/cataloger/ocaml/test-fixtures/ocaml-base-compiler.4.14.0/opam b/syft/pkg/cataloger/ocaml/testdata/ocaml-base-compiler.4.14.0/opam similarity index 100% rename from syft/pkg/cataloger/ocaml/test-fixtures/ocaml-base-compiler.4.14.0/opam rename to syft/pkg/cataloger/ocaml/testdata/ocaml-base-compiler.4.14.0/opam diff --git a/syft/pkg/cataloger/php/cataloger_test.go b/syft/pkg/cataloger/php/cataloger_test.go index 0d944aa08..78f3b1323 100644 --- a/syft/pkg/cataloger/php/cataloger_test.go +++ b/syft/pkg/cataloger/php/cataloger_test.go @@ -14,7 +14,7 @@ func Test_ComposerInstalledCataloger_Globs(t *testing.T) { }{ { name: "obtain composer files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "src/installed.json", }, @@ -39,7 +39,7 @@ func Test_ComposerLockCataloger_Globs(t *testing.T) { }{ { name: "obtain composer lock files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "src/composer.lock", }, @@ -64,7 +64,7 @@ func Test_PearCataloger_Globs(t *testing.T) { }{ { name: "obtain pear files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "php/.registry/.channel.pecl.php.net/memcached.reg", }, @@ -89,7 +89,7 @@ func Test_PeclCataloger_Globs(t *testing.T) { }{ { name: "obtain pear files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "php/.registry/.channel.pecl.php.net/memcached.reg", }, diff --git a/syft/pkg/cataloger/php/interpreter_cataloger_test.go b/syft/pkg/cataloger/php/interpreter_cataloger_test.go index ffcfda508..9e84c661e 100644 --- a/syft/pkg/cataloger/php/interpreter_cataloger_test.go +++ b/syft/pkg/cataloger/php/interpreter_cataloger_test.go @@ -73,63 +73,63 @@ func Test_InterpreterCataloger(t *testing.T) { fixture: "image-apache", expectedPkgs: []string{ // interpreters - "libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", + "libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", // extensions - "calendar @ 8.2.29 (/usr/lib/php/20220829/calendar.so)", - "ctype @ 8.2.29 (/usr/lib/php/20220829/ctype.so)", - "exif @ 8.2.29 (/usr/lib/php/20220829/exif.so)", - "ffi @ 8.2.29 (/usr/lib/php/20220829/ffi.so)", - "fileinfo @ 8.2.29 (/usr/lib/php/20220829/fileinfo.so)", - "ftp @ 8.2.29 (/usr/lib/php/20220829/ftp.so)", - "gettext @ 8.2.29 (/usr/lib/php/20220829/gettext.so)", - "iconv @ 8.2.29 (/usr/lib/php/20220829/iconv.so)", - "mysqli @ 8.2.29 (/usr/lib/php/20220829/mysqli.so)", - "opcache @ 8.2.29 (/usr/lib/php/20220829/opcache.so)", - "pdo @ 8.2.29 (/usr/lib/php/20220829/pdo.so)", - "pdo_mysql @ 8.2.29 (/usr/lib/php/20220829/pdo_mysql.so)", - "phar @ 8.2.29 (/usr/lib/php/20220829/phar.so)", - "posix @ 8.2.29 (/usr/lib/php/20220829/posix.so)", - "readline @ 8.2.29 (/usr/lib/php/20220829/readline.so)", - "shmop @ 8.2.29 (/usr/lib/php/20220829/shmop.so)", - "simplexml @ 8.2.29 (/usr/lib/php/20220829/simplexml.so)", - "sockets @ 8.2.29 (/usr/lib/php/20220829/sockets.so)", - "sysvmsg @ 8.2.29 (/usr/lib/php/20220829/sysvmsg.so)", - "sysvsem @ 8.2.29 (/usr/lib/php/20220829/sysvsem.so)", - "sysvshm @ 8.2.29 (/usr/lib/php/20220829/sysvshm.so)", - "tokenizer @ 8.2.29 (/usr/lib/php/20220829/tokenizer.so)", - "xml @ 8.2.29 (/usr/lib/php/20220829/xml.so)", - "xmlreader @ 8.2.29 (/usr/lib/php/20220829/xmlreader.so)", - "xmlwriter @ 8.2.29 (/usr/lib/php/20220829/xmlwriter.so)", - "xsl @ 8.2.29 (/usr/lib/php/20220829/xsl.so)", + "calendar @ 8.2.30 (/usr/lib/php/20220829/calendar.so)", + "ctype @ 8.2.30 (/usr/lib/php/20220829/ctype.so)", + "exif @ 8.2.30 (/usr/lib/php/20220829/exif.so)", + "ffi @ 8.2.30 (/usr/lib/php/20220829/ffi.so)", + "fileinfo @ 8.2.30 (/usr/lib/php/20220829/fileinfo.so)", + "ftp @ 8.2.30 (/usr/lib/php/20220829/ftp.so)", + "gettext @ 8.2.30 (/usr/lib/php/20220829/gettext.so)", + "iconv @ 8.2.30 (/usr/lib/php/20220829/iconv.so)", + "mysqli @ 8.2.30 (/usr/lib/php/20220829/mysqli.so)", + "opcache @ 8.2.30 (/usr/lib/php/20220829/opcache.so)", + "pdo @ 8.2.30 (/usr/lib/php/20220829/pdo.so)", + "pdo_mysql @ 8.2.30 (/usr/lib/php/20220829/pdo_mysql.so)", + "phar @ 8.2.30 (/usr/lib/php/20220829/phar.so)", + "posix @ 8.2.30 (/usr/lib/php/20220829/posix.so)", + "readline @ 8.2.30 (/usr/lib/php/20220829/readline.so)", + "shmop @ 8.2.30 (/usr/lib/php/20220829/shmop.so)", + "simplexml @ 8.2.30 (/usr/lib/php/20220829/simplexml.so)", + "sockets @ 8.2.30 (/usr/lib/php/20220829/sockets.so)", + "sysvmsg @ 8.2.30 (/usr/lib/php/20220829/sysvmsg.so)", + "sysvsem @ 8.2.30 (/usr/lib/php/20220829/sysvsem.so)", + "sysvshm @ 8.2.30 (/usr/lib/php/20220829/sysvshm.so)", + "tokenizer @ 8.2.30 (/usr/lib/php/20220829/tokenizer.so)", + "xml @ 8.2.30 (/usr/lib/php/20220829/xml.so)", + "xmlreader @ 8.2.30 (/usr/lib/php/20220829/xmlreader.so)", + "xmlwriter @ 8.2.30 (/usr/lib/php/20220829/xmlwriter.so)", + "xsl @ 8.2.30 (/usr/lib/php/20220829/xsl.so)", }, expectedRels: []string{ - "calendar @ 8.2.29 (/usr/lib/php/20220829/calendar.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "ctype @ 8.2.29 (/usr/lib/php/20220829/ctype.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "exif @ 8.2.29 (/usr/lib/php/20220829/exif.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "ffi @ 8.2.29 (/usr/lib/php/20220829/ffi.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "fileinfo @ 8.2.29 (/usr/lib/php/20220829/fileinfo.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "ftp @ 8.2.29 (/usr/lib/php/20220829/ftp.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "gettext @ 8.2.29 (/usr/lib/php/20220829/gettext.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "iconv @ 8.2.29 (/usr/lib/php/20220829/iconv.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "mysqli @ 8.2.29 (/usr/lib/php/20220829/mysqli.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "opcache @ 8.2.29 (/usr/lib/php/20220829/opcache.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "pdo @ 8.2.29 (/usr/lib/php/20220829/pdo.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "pdo_mysql @ 8.2.29 (/usr/lib/php/20220829/pdo_mysql.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "phar @ 8.2.29 (/usr/lib/php/20220829/phar.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "posix @ 8.2.29 (/usr/lib/php/20220829/posix.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "readline @ 8.2.29 (/usr/lib/php/20220829/readline.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "shmop @ 8.2.29 (/usr/lib/php/20220829/shmop.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "simplexml @ 8.2.29 (/usr/lib/php/20220829/simplexml.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "sockets @ 8.2.29 (/usr/lib/php/20220829/sockets.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "sysvmsg @ 8.2.29 (/usr/lib/php/20220829/sysvmsg.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "sysvsem @ 8.2.29 (/usr/lib/php/20220829/sysvsem.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "sysvshm @ 8.2.29 (/usr/lib/php/20220829/sysvshm.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "tokenizer @ 8.2.29 (/usr/lib/php/20220829/tokenizer.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "xml @ 8.2.29 (/usr/lib/php/20220829/xml.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "xmlreader @ 8.2.29 (/usr/lib/php/20220829/xmlreader.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "xmlwriter @ 8.2.29 (/usr/lib/php/20220829/xmlwriter.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", - "xsl @ 8.2.29 (/usr/lib/php/20220829/xsl.so) [dependency-of] libphp @ 8.2.29 (/usr/lib/apache2/modules/libphp8.2.so)", + "calendar @ 8.2.30 (/usr/lib/php/20220829/calendar.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "ctype @ 8.2.30 (/usr/lib/php/20220829/ctype.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "exif @ 8.2.30 (/usr/lib/php/20220829/exif.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "ffi @ 8.2.30 (/usr/lib/php/20220829/ffi.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "fileinfo @ 8.2.30 (/usr/lib/php/20220829/fileinfo.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "ftp @ 8.2.30 (/usr/lib/php/20220829/ftp.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "gettext @ 8.2.30 (/usr/lib/php/20220829/gettext.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "iconv @ 8.2.30 (/usr/lib/php/20220829/iconv.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "mysqli @ 8.2.30 (/usr/lib/php/20220829/mysqli.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "opcache @ 8.2.30 (/usr/lib/php/20220829/opcache.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "pdo @ 8.2.30 (/usr/lib/php/20220829/pdo.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "pdo_mysql @ 8.2.30 (/usr/lib/php/20220829/pdo_mysql.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "phar @ 8.2.30 (/usr/lib/php/20220829/phar.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "posix @ 8.2.30 (/usr/lib/php/20220829/posix.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "readline @ 8.2.30 (/usr/lib/php/20220829/readline.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "shmop @ 8.2.30 (/usr/lib/php/20220829/shmop.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "simplexml @ 8.2.30 (/usr/lib/php/20220829/simplexml.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "sockets @ 8.2.30 (/usr/lib/php/20220829/sockets.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "sysvmsg @ 8.2.30 (/usr/lib/php/20220829/sysvmsg.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "sysvsem @ 8.2.30 (/usr/lib/php/20220829/sysvsem.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "sysvshm @ 8.2.30 (/usr/lib/php/20220829/sysvshm.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "tokenizer @ 8.2.30 (/usr/lib/php/20220829/tokenizer.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "xml @ 8.2.30 (/usr/lib/php/20220829/xml.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "xmlreader @ 8.2.30 (/usr/lib/php/20220829/xmlreader.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "xmlwriter @ 8.2.30 (/usr/lib/php/20220829/xmlwriter.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", + "xsl @ 8.2.30 (/usr/lib/php/20220829/xsl.so) [dependency-of] libphp @ 8.2.30 (/usr/lib/apache2/modules/libphp8.2.so)", }, }, } diff --git a/syft/pkg/cataloger/php/parse_composer_lock_test.go b/syft/pkg/cataloger/php/parse_composer_lock_test.go index 4f5759d78..e95da7621 100644 --- a/syft/pkg/cataloger/php/parse_composer_lock_test.go +++ b/syft/pkg/cataloger/php/parse_composer_lock_test.go @@ -13,7 +13,7 @@ import ( func TestParseComposerFileLock(t *testing.T) { ctx := context.Background() var expectedRelationships []artifact.Relationship - fixture := "test-fixtures/composer.lock" + fixture := "testdata/composer.lock" locations := file.NewLocationSet(file.NewLocation(fixture)) expectedPkgs := []pkg.Package{ { @@ -118,7 +118,7 @@ func TestParseComposerFileLock(t *testing.T) { func Test_corruptComposerLock(t *testing.T) { pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/glob-paths/src/composer.lock"). + FromFile(t, "testdata/glob-paths/src/composer.lock"). WithError(). TestParser(t, parseComposerLock) } diff --git a/syft/pkg/cataloger/php/parse_installed_json_test.go b/syft/pkg/cataloger/php/parse_installed_json_test.go index f5753b186..a7e8bcf7a 100644 --- a/syft/pkg/cataloger/php/parse_installed_json_test.go +++ b/syft/pkg/cataloger/php/parse_installed_json_test.go @@ -13,8 +13,8 @@ import ( func TestParseInstalledJsonComposerV1(t *testing.T) { ctx := context.TODO() fixtures := []string{ - "test-fixtures/vendor/composer_1/installed.json", - "test-fixtures/vendor/composer_2/installed.json", + "testdata/vendor/composer_1/installed.json", + "testdata/vendor/composer_2/installed.json", } var expectedRelationships []artifact.Relationship @@ -147,7 +147,7 @@ func TestParseInstalledJsonComposerV1(t *testing.T) { func Test_corruptInstalledJSON(t *testing.T) { pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/glob-paths/src/installed.json"). + FromFile(t, "testdata/glob-paths/src/installed.json"). WithError(). TestParser(t, parseInstalledJSON) } diff --git a/syft/pkg/cataloger/php/parse_pecl_pear_test.go b/syft/pkg/cataloger/php/parse_pecl_pear_test.go index bce01dc8d..f371ee943 100644 --- a/syft/pkg/cataloger/php/parse_pecl_pear_test.go +++ b/syft/pkg/cataloger/php/parse_pecl_pear_test.go @@ -20,15 +20,15 @@ func TestParsePear(t *testing.T) { }{ { name: "v6 format", - fixture: "test-fixtures/memcached-v6-format.reg", + fixture: "testdata/memcached-v6-format.reg", expectedPkgs: []pkg.Package{ { Name: "memcached", Version: "3.2.0", PURL: "pkg:pear/pecl.php.net/memcached@3.2.0", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/memcached-v6-format.reg")), + Locations: file.NewLocationSet(file.NewLocation("testdata/memcached-v6-format.reg")), Licenses: pkg.NewLicenseSet( - pkg.NewLicenseFromLocationsWithContext(ctx, "PHP License", file.NewLocation("test-fixtures/memcached-v6-format.reg")), + pkg.NewLicenseFromLocationsWithContext(ctx, "PHP License", file.NewLocation("testdata/memcached-v6-format.reg")), ), Language: pkg.PHP, Type: pkg.PhpPearPkg, @@ -43,15 +43,15 @@ func TestParsePear(t *testing.T) { }, { name: "v5 format", - fixture: "test-fixtures/memcached-v5-format.reg", + fixture: "testdata/memcached-v5-format.reg", expectedPkgs: []pkg.Package{ { Name: "memcached", Version: "3.2.0", PURL: "pkg:pear/pecl.php.net/memcached@3.2.0", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/memcached-v5-format.reg")), + Locations: file.NewLocationSet(file.NewLocation("testdata/memcached-v5-format.reg")), Licenses: pkg.NewLicenseSet( - pkg.NewLicenseFromLocationsWithContext(ctx, "PHP License", file.NewLocation("test-fixtures/memcached-v5-format.reg")), + pkg.NewLicenseFromLocationsWithContext(ctx, "PHP License", file.NewLocation("testdata/memcached-v5-format.reg")), ), Language: pkg.PHP, Type: pkg.PhpPearPkg, @@ -82,15 +82,15 @@ func TestParsePecl(t *testing.T) { }{ { name: "v6 format", - fixture: "test-fixtures/memcached-v6-format.reg", + fixture: "testdata/memcached-v6-format.reg", expectedPkgs: []pkg.Package{ { Name: "memcached", Version: "3.2.0", PURL: "pkg:pear/pecl.php.net/memcached@3.2.0", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/memcached-v6-format.reg")), + Locations: file.NewLocationSet(file.NewLocation("testdata/memcached-v6-format.reg")), Licenses: pkg.NewLicenseSet( - pkg.NewLicenseFromLocationsWithContext(ctx, "PHP License", file.NewLocation("test-fixtures/memcached-v6-format.reg")), + pkg.NewLicenseFromLocationsWithContext(ctx, "PHP License", file.NewLocation("testdata/memcached-v6-format.reg")), ), Language: pkg.PHP, Type: pkg.PhpPeclPkg, // important! @@ -105,15 +105,15 @@ func TestParsePecl(t *testing.T) { }, { name: "v5 format", - fixture: "test-fixtures/memcached-v5-format.reg", + fixture: "testdata/memcached-v5-format.reg", expectedPkgs: []pkg.Package{ { Name: "memcached", Version: "3.2.0", PURL: "pkg:pear/pecl.php.net/memcached@3.2.0", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/memcached-v5-format.reg")), + Locations: file.NewLocationSet(file.NewLocation("testdata/memcached-v5-format.reg")), Licenses: pkg.NewLicenseSet( - pkg.NewLicenseFromLocationsWithContext(ctx, "PHP License", file.NewLocation("test-fixtures/memcached-v5-format.reg")), + pkg.NewLicenseFromLocationsWithContext(ctx, "PHP License", file.NewLocation("testdata/memcached-v5-format.reg")), ), Language: pkg.PHP, Type: pkg.PhpPeclPkg, // important! @@ -136,7 +136,7 @@ func TestParsePecl(t *testing.T) { func Test_corruptPecl(t *testing.T) { pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/glob-paths/php/.registry/.channel.pecl.php.net/memcached.reg"). + FromFile(t, "testdata/glob-paths/php/.registry/.channel.pecl.php.net/memcached.reg"). WithError(). TestParser(t, parseComposerLock) } diff --git a/syft/pkg/cataloger/php/test-fixtures/composer.lock b/syft/pkg/cataloger/php/testdata/composer.lock similarity index 100% rename from syft/pkg/cataloger/php/test-fixtures/composer.lock rename to syft/pkg/cataloger/php/testdata/composer.lock diff --git a/syft/pkg/cataloger/php/test-fixtures/glob-paths/php/.registry/.channel.pecl.php.net/memcached.reg b/syft/pkg/cataloger/php/testdata/glob-paths/php/.registry/.channel.pecl.php.net/memcached.reg similarity index 100% rename from syft/pkg/cataloger/php/test-fixtures/glob-paths/php/.registry/.channel.pecl.php.net/memcached.reg rename to syft/pkg/cataloger/php/testdata/glob-paths/php/.registry/.channel.pecl.php.net/memcached.reg diff --git a/syft/pkg/cataloger/php/test-fixtures/glob-paths/src/composer.lock b/syft/pkg/cataloger/php/testdata/glob-paths/src/composer.lock similarity index 100% rename from syft/pkg/cataloger/php/test-fixtures/glob-paths/src/composer.lock rename to syft/pkg/cataloger/php/testdata/glob-paths/src/composer.lock diff --git a/syft/pkg/cataloger/php/test-fixtures/glob-paths/src/installed.json b/syft/pkg/cataloger/php/testdata/glob-paths/src/installed.json similarity index 100% rename from syft/pkg/cataloger/php/test-fixtures/glob-paths/src/installed.json rename to syft/pkg/cataloger/php/testdata/glob-paths/src/installed.json diff --git a/syft/pkg/cataloger/php/test-fixtures/image-apache/Dockerfile b/syft/pkg/cataloger/php/testdata/image-apache/Dockerfile similarity index 100% rename from syft/pkg/cataloger/php/test-fixtures/image-apache/Dockerfile rename to syft/pkg/cataloger/php/testdata/image-apache/Dockerfile diff --git a/syft/pkg/cataloger/php/test-fixtures/image-extensions/Dockerfile b/syft/pkg/cataloger/php/testdata/image-extensions/Dockerfile similarity index 100% rename from syft/pkg/cataloger/php/test-fixtures/image-extensions/Dockerfile rename to syft/pkg/cataloger/php/testdata/image-extensions/Dockerfile diff --git a/syft/pkg/cataloger/php/test-fixtures/memcached-v5-format.reg b/syft/pkg/cataloger/php/testdata/memcached-v5-format.reg similarity index 100% rename from syft/pkg/cataloger/php/test-fixtures/memcached-v5-format.reg rename to syft/pkg/cataloger/php/testdata/memcached-v5-format.reg diff --git a/syft/pkg/cataloger/php/test-fixtures/memcached-v6-format.reg b/syft/pkg/cataloger/php/testdata/memcached-v6-format.reg similarity index 100% rename from syft/pkg/cataloger/php/test-fixtures/memcached-v6-format.reg rename to syft/pkg/cataloger/php/testdata/memcached-v6-format.reg diff --git a/syft/pkg/cataloger/php/test-fixtures/vendor/composer_1/installed.json b/syft/pkg/cataloger/php/testdata/vendor/composer_1/installed.json similarity index 100% rename from syft/pkg/cataloger/php/test-fixtures/vendor/composer_1/installed.json rename to syft/pkg/cataloger/php/testdata/vendor/composer_1/installed.json diff --git a/syft/pkg/cataloger/php/test-fixtures/vendor/composer_2/installed.json b/syft/pkg/cataloger/php/testdata/vendor/composer_2/installed.json similarity index 100% rename from syft/pkg/cataloger/php/test-fixtures/vendor/composer_2/installed.json rename to syft/pkg/cataloger/php/testdata/vendor/composer_2/installed.json diff --git a/syft/pkg/cataloger/python/cataloger_test.go b/syft/pkg/cataloger/python/cataloger_test.go index 1da9f59e4..9ad435a7e 100644 --- a/syft/pkg/cataloger/python/cataloger_test.go +++ b/syft/pkg/cataloger/python/cataloger_test.go @@ -23,7 +23,7 @@ func Test_InstalledPackageCataloger(t *testing.T) { }{ { name: "egg-file-no-version", - fixture: "test-fixtures/site-packages/no-version", + fixture: "testdata/site-packages/no-version", expectedPackages: []pkg.Package{ { Name: "no-version", @@ -41,7 +41,7 @@ func Test_InstalledPackageCataloger(t *testing.T) { }, { name: "dist-info+egg-info site-packages directory", - fixture: "test-fixtures/site-packages/nested", + fixture: "testdata/site-packages/nested", expectedPackages: []pkg.Package{ { Name: "pygments", @@ -124,7 +124,7 @@ func Test_InstalledPackageCataloger(t *testing.T) { }, { name: "DIST-INFO+EGG-INFO site-packages directory (case insensitive)", - fixture: "test-fixtures/site-packages/uppercase", + fixture: "testdata/site-packages/uppercase", expectedPackages: []pkg.Package{ { Name: "pygments", @@ -204,7 +204,7 @@ func Test_InstalledPackageCataloger(t *testing.T) { }, { name: "detect licenses", - fixture: "test-fixtures/site-packages/license", + fixture: "testdata/site-packages/license", expectedPackages: []pkg.Package{ { Name: "pygments", @@ -223,7 +223,7 @@ func Test_InstalledPackageCataloger(t *testing.T) { Value: "BSD-3-Clause", SPDXExpression: "BSD-3-Clause", Type: "concluded", - Contents: mustContentsFromLocation(t, "test-fixtures/site-packages/license/with-license-file-declared.dist-info/LICENSE.txt", 0, 1475), + Contents: mustContentsFromLocation(t, "testdata/site-packages/license/with-license-file-declared.dist-info/LICENSE.txt", 0, 1475), // we read the path from the LicenseFile field in the METADATA file, then read the license file directly Locations: file.NewLocationSet(file.NewLocation("with-license-file-declared.dist-info/LICENSE.txt")), }, @@ -270,7 +270,7 @@ func Test_InstalledPackageCataloger(t *testing.T) { Value: "BSD-3-Clause", SPDXExpression: "BSD-3-Clause", Type: "concluded", - Contents: mustContentsFromLocation(t, "test-fixtures/site-packages/license/with-license-file-declared.dist-info/LICENSE.txt", 0, 1475), + Contents: mustContentsFromLocation(t, "testdata/site-packages/license/with-license-file-declared.dist-info/LICENSE.txt", 0, 1475), Locations: file.NewLocationSet(file.NewLocation("without-license-file-declared.dist-info/LICENSE.txt")), }, ), @@ -303,7 +303,7 @@ func Test_InstalledPackageCataloger(t *testing.T) { }, { name: "malformed-record", - fixture: "test-fixtures/site-packages/malformed-record", + fixture: "testdata/site-packages/malformed-record", expectedPackages: []pkg.Package{ { Name: "pygments", @@ -341,7 +341,7 @@ func Test_InstalledPackageCataloger(t *testing.T) { // in cases where the metadata file is available and the record is not we should still record there is a package // additionally empty top_level.txt files should not result in an error name: "partial dist-info directory", - fixture: "test-fixtures/site-packages/partial.dist-info", + fixture: "testdata/site-packages/partial.dist-info", expectedPackages: []pkg.Package{ { Name: "pygments", @@ -370,7 +370,7 @@ func Test_InstalledPackageCataloger(t *testing.T) { }, { name: "egg-info regular file", - fixture: "test-fixtures/site-packages/test", + fixture: "testdata/site-packages/test", expectedPackages: []pkg.Package{ { Name: "requests", @@ -420,7 +420,7 @@ func Test_PackageCataloger(t *testing.T) { }{ { name: "pdm", - fixture: "test-fixtures/pdm-lock", + fixture: "testdata/pdm-lock", expectedPackages: []string{ "certifi @ 2025.1.31 (pdm.lock)", "chardet @ 3.0.4 (pdm.lock)", @@ -462,10 +462,10 @@ func Test_PackageCataloger_IgnorePackage(t *testing.T) { MetadataFixture string }{ { - MetadataFixture: "test-fixtures/Python-2.7.egg-info", + MetadataFixture: "testdata/Python-2.7.egg-info", }, { - MetadataFixture: "test-fixtures/empty-1.0.0-py3.8.egg-info", + MetadataFixture: "testdata/empty-1.0.0-py3.8.egg-info", }, } @@ -491,7 +491,7 @@ func Test_IndexCataloger_Globs(t *testing.T) { }{ { name: "obtain index files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "src/requirements.txt", "src/extra-requirements.txt", @@ -524,7 +524,7 @@ func Test_PackageCataloger_Globs(t *testing.T) { }{ { name: "obtain index files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "site-packages/v.DIST-INFO/METADATA", "site-packages/w.EGG-INFO/PKG-INFO", @@ -554,12 +554,12 @@ func Test_PackageCataloger_Relationships(t *testing.T) { }{ { name: "poetry - no dependencies", - fixture: "test-fixtures/poetry/dev-deps", + fixture: "testdata/poetry/dev-deps", expectedRelationships: nil, }, { name: "poetry - simple dependencies", - fixture: "test-fixtures/poetry/simple-deps", + fixture: "testdata/poetry/simple-deps", expectedRelationships: []string{ "certifi @ 2024.2.2 (.) [dependency-of] requests @ 2.32.2 (.)", "charset-normalizer @ 3.3.2 (.) [dependency-of] requests @ 2.32.2 (.)", @@ -569,7 +569,7 @@ func Test_PackageCataloger_Relationships(t *testing.T) { }, { name: "poetry - multiple extras", - fixture: "test-fixtures/poetry/multiple-extras", + fixture: "testdata/poetry/multiple-extras", expectedRelationships: []string{ "anyio @ 4.3.0 (.) [dependency-of] anyio @ 4.3.0 (.)", "anyio @ 4.3.0 (.) [dependency-of] httpcore @ 1.0.5 (.)", @@ -596,7 +596,7 @@ func Test_PackageCataloger_Relationships(t *testing.T) { }, { name: "poetry - nested extras", - fixture: "test-fixtures/poetry/nested-extras", + fixture: "testdata/poetry/nested-extras", expectedRelationships: []string{ "annotated-types @ 0.7.0 (.) [dependency-of] pydantic @ 2.7.1 (.)", "anyio @ 4.3.0 (.) [dependency-of] anyio @ 4.3.0 (.)", @@ -678,7 +678,7 @@ func Test_PackageCataloger_Relationships(t *testing.T) { }, { name: "poetry - conflicting extras", - fixture: "test-fixtures/poetry/conflicting-with-extras", + fixture: "testdata/poetry/conflicting-with-extras", expectedRelationships: []string{ "anyio @ 4.3.0 (.) [dependency-of] anyio @ 4.3.0 (.)", "anyio @ 4.3.0 (.) [dependency-of] httpcore @ 1.0.5 (.)", @@ -732,7 +732,7 @@ func Test_PackageCataloger_Relationships(t *testing.T) { }, { name: "uv - simple dependencies", - fixture: "test-fixtures/uv/simple-deps", + fixture: "testdata/uv/simple-deps", expectedRelationships: []string{ "certifi @ 2025.1.31 (.) [dependency-of] requests @ 2.32.3 (.)", "charset-normalizer @ 3.4.1 (.) [dependency-of] requests @ 2.32.3 (.)", @@ -743,7 +743,7 @@ func Test_PackageCataloger_Relationships(t *testing.T) { }, { name: "uv - multiple extras", - fixture: "test-fixtures/uv/multiple-extras", + fixture: "testdata/uv/multiple-extras", expectedRelationships: []string{ "anyio @ 4.9.0 (.) [dependency-of] httpx @ 0.28.1 (.)", "brotli @ 1.1.0 (.) [dependency-of] httpx @ 0.28.1 (.)", @@ -767,7 +767,7 @@ func Test_PackageCataloger_Relationships(t *testing.T) { }, { name: "uv - nested extras", - fixture: "test-fixtures/uv/nested-extras", + fixture: "testdata/uv/nested-extras", expectedRelationships: []string{ "annotated-types @ 0.7.0 (.) [dependency-of] pydantic @ 2.11.0 (.)", "anyio @ 4.9.0 (.) [dependency-of] httpx @ 0.28.1 (.)", @@ -836,7 +836,7 @@ func Test_PackageCataloger_Relationships(t *testing.T) { }, { name: "uv - conflicting extras", - fixture: "test-fixtures/uv/conflicting-with-extras", + fixture: "testdata/uv/conflicting-with-extras", expectedRelationships: []string{ "anyio @ 4.6.2.post1 (.) [dependency-of] httpx @ 0.28.1 (.)", "brotli @ 1.1.0 (.) [dependency-of] httpx @ 0.28.1 (.)", diff --git a/syft/pkg/cataloger/python/dependency_test.go b/syft/pkg/cataloger/python/dependency_test.go index 094c56cbd..94c0f3b7c 100644 --- a/syft/pkg/cataloger/python/dependency_test.go +++ b/syft/pkg/cataloger/python/dependency_test.go @@ -221,7 +221,7 @@ func Test_poetryLockDependencySpecifier_againstPoetryLock(t *testing.T) { }{ { name: "case-insensitive dependency resolution", - fixture: "test-fixtures/poetry/case-sensitivity/poetry.lock", + fixture: "testdata/poetry/case-sensitivity/poetry.lock", want: []dependency.Specification{ // packages are in the order they appear in the lock file { @@ -253,7 +253,7 @@ func Test_poetryLockDependencySpecifier_againstPoetryLock(t *testing.T) { }, { name: "simple dependencies with extras", - fixture: "test-fixtures/poetry/simple-deps/poetry.lock", + fixture: "testdata/poetry/simple-deps/poetry.lock", want: []dependency.Specification{ { ProvidesRequires: dependency.ProvidesRequires{ diff --git a/syft/pkg/cataloger/python/license_test.go b/syft/pkg/cataloger/python/license_test.go index afc7e7f27..13b81a1c9 100644 --- a/syft/pkg/cataloger/python/license_test.go +++ b/syft/pkg/cataloger/python/license_test.go @@ -78,7 +78,7 @@ func TestGetLicenseFromPypiRegistry(t *testing.T) { requestHandlers: []handlerPath{ { path: "/certifi/2025.10.5/json", - handler: generateMockPypiRegistryHandler("test-fixtures/pypi-remote/registry_response.json"), + handler: generateMockPypiRegistryHandler("testdata/pypi-remote/registry_response.json"), }, }, expected: "MPL-2.0", @@ -101,7 +101,7 @@ func TestGetLicenseFromPypiRegistry(t *testing.T) { requestHandlers: []handlerPath{ { path: "/package/2.0/json", - handler: generateMockPypiRegistryHandler("test-fixtures/pypi-remote/registry_response_bad.json"), + handler: generateMockPypiRegistryHandler("testdata/pypi-remote/registry_response_bad.json"), }, }, expected: "", diff --git a/syft/pkg/cataloger/python/parse_pdm_lock_test.go b/syft/pkg/cataloger/python/parse_pdm_lock_test.go index 57c346a69..3e7006d53 100644 --- a/syft/pkg/cataloger/python/parse_pdm_lock_test.go +++ b/syft/pkg/cataloger/python/parse_pdm_lock_test.go @@ -16,7 +16,7 @@ import ( func TestParsePdmLock(t *testing.T) { - fixture := "test-fixtures/pdm-lock/pdm.lock" + fixture := "testdata/pdm-lock/pdm.lock" locations := file.NewLocationSet(file.NewLocation(fixture)) expectedPkgs := []pkg.Package{ { @@ -374,7 +374,7 @@ func TestParsePdmLock(t *testing.T) { func TestParsePdmLockWithLicenseEnrichment(t *testing.T) { ctx := context.TODO() - fixture := "test-fixtures/pypi-remote/pdm.lock" + fixture := "testdata/pypi-remote/pdm.lock" locations := file.NewLocationSet(file.NewLocation(fixture)) mux, url, teardown := setupPypiRegistry() defer teardown() @@ -391,7 +391,7 @@ func TestParsePdmLockWithLicenseEnrichment(t *testing.T) { requestHandlers: []handlerPath{ { path: "/certifi/2025.10.5/json", - handler: generateMockPypiRegistryHandler("test-fixtures/pypi-remote/registry_response.json"), + handler: generateMockPypiRegistryHandler("testdata/pypi-remote/registry_response.json"), }, }, expectedPackages: []pkg.Package{ @@ -451,7 +451,7 @@ func TestParsePdmLockWithExtras(t *testing.T) { // // We should get exactly ONE coverage package in the output, with extras properly tracked. - fixture := "test-fixtures/pdm-lock-extras/pdm.lock" + fixture := "testdata/pdm-lock-extras/pdm.lock" pdmLockParser := newPdmLockParser(DefaultCatalogerConfig()) fh, err := os.Open(fixture) @@ -584,7 +584,7 @@ func TestParsePdmLockWithSeparateFilesFixture(t *testing.T) { // We should get exactly ONE rfc3986 package in the output, with the extras variant properly tracked // in the Extras field. - fixture := "test-fixtures/pdm-lock-separate-files/pdm.lock" + fixture := "testdata/pdm-lock-separate-files/pdm.lock" pdmLockParser := newPdmLockParser(DefaultCatalogerConfig()) fh, err := os.Open(fixture) @@ -697,7 +697,7 @@ func TestMergePdmLockPackagesNoBasePackage(t *testing.T) { func Test_corruptPdmLock(t *testing.T) { psr := newPdmLockParser(DefaultCatalogerConfig()) pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/glob-paths/src/pdm.lock"). + FromFile(t, "testdata/glob-paths/src/pdm.lock"). WithError(). TestParser(t, psr.parsePdmLock) } diff --git a/syft/pkg/cataloger/python/parse_pipfile_lock_test.go b/syft/pkg/cataloger/python/parse_pipfile_lock_test.go index 7ad5a4e7f..1563a9616 100644 --- a/syft/pkg/cataloger/python/parse_pipfile_lock_test.go +++ b/syft/pkg/cataloger/python/parse_pipfile_lock_test.go @@ -12,7 +12,7 @@ import ( func TestParsePipFileLock(t *testing.T) { - fixture := "test-fixtures/pipfile-lock/Pipfile.lock" + fixture := "testdata/pipfile-lock/Pipfile.lock" locations := file.NewLocationSet(file.NewLocation(fixture)) expectedPkgs := []pkg.Package{ { @@ -85,7 +85,7 @@ func TestParsePipFileLock(t *testing.T) { func TestParsePipfileLockWithLicenseEnrichment(t *testing.T) { ctx := context.TODO() - fixture := "test-fixtures/pypi-remote/Pipfile.lock" + fixture := "testdata/pypi-remote/Pipfile.lock" locations := file.NewLocationSet(file.NewLocation(fixture)) mux, url, teardown := setupPypiRegistry() defer teardown() @@ -102,7 +102,7 @@ func TestParsePipfileLockWithLicenseEnrichment(t *testing.T) { requestHandlers: []handlerPath{ { path: "/certifi/2025.10.5/json", - handler: generateMockPypiRegistryHandler("test-fixtures/pypi-remote/registry_response.json"), + handler: generateMockPypiRegistryHandler("testdata/pypi-remote/registry_response.json"), }, }, expectedPackages: []pkg.Package{ @@ -141,7 +141,7 @@ func TestParsePipfileLockWithLicenseEnrichment(t *testing.T) { func Test_corruptPipfileLock(t *testing.T) { pipfileLockParser := newPipfileLockParser(DefaultCatalogerConfig()) pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/glob-paths/src/Pipfile.lock"). + FromFile(t, "testdata/glob-paths/src/Pipfile.lock"). WithError(). TestParser(t, pipfileLockParser.parsePipfileLock) } diff --git a/syft/pkg/cataloger/python/parse_poetry_lock_test.go b/syft/pkg/cataloger/python/parse_poetry_lock_test.go index b350a34a1..82085eae2 100644 --- a/syft/pkg/cataloger/python/parse_poetry_lock_test.go +++ b/syft/pkg/cataloger/python/parse_poetry_lock_test.go @@ -11,7 +11,7 @@ import ( ) func TestParsePoetryLock(t *testing.T) { - fixture := "test-fixtures/poetry/dev-deps/poetry.lock" + fixture := "testdata/poetry/dev-deps/poetry.lock" locations := file.NewLocationSet(file.NewLocation(fixture)) expectedPkgs := []pkg.Package{ { @@ -86,7 +86,7 @@ func TestParsePoetryLock(t *testing.T) { func TestParsePoetryLockWithLicenseEnrichment(t *testing.T) { ctx := context.TODO() - fixture := "test-fixtures/pypi-remote/poetry.lock" + fixture := "testdata/pypi-remote/poetry.lock" locations := file.NewLocationSet(file.NewLocation(fixture)) mux, url, teardown := setupPypiRegistry() defer teardown() @@ -103,7 +103,7 @@ func TestParsePoetryLockWithLicenseEnrichment(t *testing.T) { requestHandlers: []handlerPath{ { path: "/certifi/2025.10.5/json", - handler: generateMockPypiRegistryHandler("test-fixtures/pypi-remote/registry_response.json"), + handler: generateMockPypiRegistryHandler("testdata/pypi-remote/registry_response.json"), }, }, expectedPackages: []pkg.Package{ @@ -137,7 +137,7 @@ func TestParsePoetryLockWithLicenseEnrichment(t *testing.T) { func Test_corruptPoetryLock(t *testing.T) { poetryLockParser := newPoetryLockParser(DefaultCatalogerConfig()) pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/glob-paths/src/poetry.lock"). + FromFile(t, "testdata/glob-paths/src/poetry.lock"). WithError(). TestParser(t, poetryLockParser.parsePoetryLock) } diff --git a/syft/pkg/cataloger/python/parse_requirements_test.go b/syft/pkg/cataloger/python/parse_requirements_test.go index e1cbfd864..6f40974b8 100644 --- a/syft/pkg/cataloger/python/parse_requirements_test.go +++ b/syft/pkg/cataloger/python/parse_requirements_test.go @@ -13,7 +13,7 @@ import ( ) func TestParseRequirementsTxt(t *testing.T) { - fixture := "test-fixtures/requires/requirements.txt" + fixture := "testdata/requires/requirements.txt" locations := file.NewLocationSet(file.NewLocation(fixture)) pinnedPkgs := []pkg.Package{ @@ -229,7 +229,7 @@ func TestParseRequirementsTxt(t *testing.T) { func TestParseRequirementsTxtWithLicenseEnrichment(t *testing.T) { ctx := context.TODO() - fixture := "test-fixtures/pypi-remote/requirements.txt" + fixture := "testdata/pypi-remote/requirements.txt" locations := file.NewLocationSet(file.NewLocation(fixture)) mux, url, teardown := setupPypiRegistry() defer teardown() @@ -246,7 +246,7 @@ func TestParseRequirementsTxtWithLicenseEnrichment(t *testing.T) { requestHandlers: []handlerPath{ { path: "/certifi/2025.10.5/json", - handler: generateMockPypiRegistryHandler("test-fixtures/pypi-remote/registry_response.json"), + handler: generateMockPypiRegistryHandler("testdata/pypi-remote/registry_response.json"), }, }, expectedPackages: []pkg.Package{ @@ -410,7 +410,7 @@ func Test_parseVersion(t *testing.T) { func Test_corruptRequirementsTxt(t *testing.T) { rp := newRequirementsParser(DefaultCatalogerConfig()) pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/glob-paths/src/requirements.txt"). + FromFile(t, "testdata/glob-paths/src/requirements.txt"). WithError(). TestParser(t, rp.parseRequirementsTxt) } diff --git a/syft/pkg/cataloger/python/parse_setup_test.go b/syft/pkg/cataloger/python/parse_setup_test.go index a2c57bb16..505f53564 100644 --- a/syft/pkg/cataloger/python/parse_setup_test.go +++ b/syft/pkg/cataloger/python/parse_setup_test.go @@ -18,7 +18,7 @@ func TestParseSetup(t *testing.T) { expected []pkg.Package }{ { - fixture: "test-fixtures/setup/setup.py", + fixture: "testdata/setup/setup.py", expected: []pkg.Package{ { Name: "pathlib3", @@ -59,11 +59,11 @@ func TestParseSetup(t *testing.T) { }, { // regression... ensure we clean packages names and don't find "%s" as the name - fixture: "test-fixtures/setup/dynamic-setup.py", + fixture: "testdata/setup/dynamic-setup.py", expected: nil, }, { - fixture: "test-fixtures/setup/multiline-split-setup.py", + fixture: "testdata/setup/multiline-split-setup.py", expected: []pkg.Package{ { Name: "black", @@ -125,7 +125,7 @@ func TestParseSetup(t *testing.T) { }, { // Test mixed quoted and unquoted dependencies - ensure no duplicates - fixture: "test-fixtures/setup/mixed-format-setup.py", + fixture: "testdata/setup/mixed-format-setup.py", expected: []pkg.Package{ { Name: "requests", @@ -169,7 +169,7 @@ func TestParseSetup(t *testing.T) { func TestParseSetupFileWithLicenseEnrichment(t *testing.T) { ctx := context.TODO() - fixture := "test-fixtures/pypi-remote/setup.py" + fixture := "testdata/pypi-remote/setup.py" locations := file.NewLocationSet(file.NewLocation(fixture)) mux, url, teardown := setupPypiRegistry() defer teardown() @@ -186,7 +186,7 @@ func TestParseSetupFileWithLicenseEnrichment(t *testing.T) { requestHandlers: []handlerPath{ { path: "/certifi/2025.10.5/json", - handler: generateMockPypiRegistryHandler("test-fixtures/pypi-remote/registry_response.json"), + handler: generateMockPypiRegistryHandler("testdata/pypi-remote/registry_response.json"), }, }, expectedPackages: []pkg.Package{ diff --git a/syft/pkg/cataloger/python/parse_uv_lock_test.go b/syft/pkg/cataloger/python/parse_uv_lock_test.go index 7dd19366e..582ac9eb6 100644 --- a/syft/pkg/cataloger/python/parse_uv_lock_test.go +++ b/syft/pkg/cataloger/python/parse_uv_lock_test.go @@ -11,7 +11,7 @@ import ( ) func TestParseUvLock(t *testing.T) { - fixture := "test-fixtures/uv/simple-deps/uv.lock" + fixture := "testdata/uv/simple-deps/uv.lock" locations := file.NewLocationSet(file.NewLocation(fixture)) @@ -131,7 +131,7 @@ func TestParseUvLock(t *testing.T) { func TestParseUvLockWithLicenseEnrichment(t *testing.T) { ctx := context.TODO() - fixture := "test-fixtures/pypi-remote/uv.lock" + fixture := "testdata/pypi-remote/uv.lock" locations := file.NewLocationSet(file.NewLocation(fixture)) mux, url, teardown := setupPypiRegistry() defer teardown() @@ -148,7 +148,7 @@ func TestParseUvLockWithLicenseEnrichment(t *testing.T) { requestHandlers: []handlerPath{ { path: "/certifi/2025.10.5/json", - handler: generateMockPypiRegistryHandler("test-fixtures/pypi-remote/registry_response.json"), + handler: generateMockPypiRegistryHandler("testdata/pypi-remote/registry_response.json"), }, }, expectedPackages: []pkg.Package{ diff --git a/syft/pkg/cataloger/python/parse_wheel_egg_metadata_test.go b/syft/pkg/cataloger/python/parse_wheel_egg_metadata_test.go index 9c1e901b1..6bbeb9e2f 100644 --- a/syft/pkg/cataloger/python/parse_wheel_egg_metadata_test.go +++ b/syft/pkg/cataloger/python/parse_wheel_egg_metadata_test.go @@ -22,40 +22,40 @@ func TestParseWheelEggMetadata(t *testing.T) { ExpectedMetadata parsedData }{ { - Fixture: "test-fixtures/site-packages/nested/egg-name/egg-info/PKG-INFO", + Fixture: "testdata/site-packages/nested/egg-name/egg-info/PKG-INFO", ExpectedMetadata: parsedData{ - DistInfoLocation: file.NewLocation("test-fixtures/site-packages/nested/egg-name/egg-info/PKG-INFO"), + DistInfoLocation: file.NewLocation("testdata/site-packages/nested/egg-name/egg-info/PKG-INFO"), Licenses: "Apache 2.0", LicenseFile: "", LicenseExpression: "", - LicenseFilePath: "test-fixtures/site-packages/nested/egg-name/egg-info/PKG-INFO", + LicenseFilePath: "testdata/site-packages/nested/egg-name/egg-info/PKG-INFO", PythonPackage: pkg.PythonPackage{ Name: "requests", Version: "2.22.0", Platform: "UNKNOWN", Author: "Kenneth Reitz", AuthorEmail: "me@kennethreitz.org", - SitePackagesRootPath: "test-fixtures/site-packages/nested/egg-name", + SitePackagesRootPath: "testdata/site-packages/nested/egg-name", RequiresPython: ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*", ProvidesExtra: []string{"security", "socks"}, }, }, }, { - Fixture: "test-fixtures/site-packages/nested/dist-name/dist-info/METADATA", + Fixture: "testdata/site-packages/nested/dist-name/dist-info/METADATA", ExpectedMetadata: parsedData{ - DistInfoLocation: file.NewLocation("test-fixtures/site-packages/nested/dist-name/dist-info/METADATA"), + DistInfoLocation: file.NewLocation("testdata/site-packages/nested/dist-name/dist-info/METADATA"), Licenses: "BSD License", LicenseFile: "", LicenseExpression: "", - LicenseFilePath: "test-fixtures/site-packages/nested/dist-name/dist-info/METADATA", + LicenseFilePath: "testdata/site-packages/nested/dist-name/dist-info/METADATA", PythonPackage: pkg.PythonPackage{ Name: "Pygments", Version: "2.6.1", Platform: "any", Author: "Georg Brandl", AuthorEmail: "georg@python.org", - SitePackagesRootPath: "test-fixtures/site-packages/nested/dist-name", + SitePackagesRootPath: "testdata/site-packages/nested/dist-name", RequiresPython: ">=3.5", RequiresDist: []string{"soupsieve (>1.2)", "html5lib ; extra == 'html5lib'", "lxml ; extra == 'lxml'"}, ProvidesExtra: []string{"html5lib", "lxml"}, @@ -151,9 +151,9 @@ func TestParseWheelEggMetadataInvalid(t *testing.T) { ExpectedMetadata parsedData }{ { - Fixture: "test-fixtures/site-packages/nested/egg-name/egg-info/PKG-INFO-INVALID", + Fixture: "testdata/site-packages/nested/egg-name/egg-info/PKG-INFO-INVALID", ExpectedMetadata: parsedData{ - DistInfoLocation: file.NewLocation("test-fixtures/site-packages/nested/egg-name/egg-info/PKG-INFO-INVALID"), + DistInfoLocation: file.NewLocation("testdata/site-packages/nested/egg-name/egg-info/PKG-INFO-INVALID"), Licenses: "", LicenseExpression: "", LicenseFile: "", @@ -161,7 +161,7 @@ func TestParseWheelEggMetadataInvalid(t *testing.T) { PythonPackage: pkg.PythonPackage{ Name: "mxnet", Version: "1.8.0", - SitePackagesRootPath: "test-fixtures/site-packages/nested/egg-name", + SitePackagesRootPath: "testdata/site-packages/nested/egg-name", }, }, }, diff --git a/syft/pkg/cataloger/python/parse_wheel_egg_record_test.go b/syft/pkg/cataloger/python/parse_wheel_egg_record_test.go index a705378b1..7b1e01f72 100644 --- a/syft/pkg/cataloger/python/parse_wheel_egg_record_test.go +++ b/syft/pkg/cataloger/python/parse_wheel_egg_record_test.go @@ -17,7 +17,7 @@ func TestParseWheelEggRecord(t *testing.T) { ExpectedMetadata []pkg.PythonFileRecord }{ { - Fixture: "test-fixtures/site-packages/nested/egg-name/egg-info/RECORD", + Fixture: "testdata/site-packages/nested/egg-name/egg-info/RECORD", ExpectedMetadata: []pkg.PythonFileRecord{ {Path: "requests-2.22.0.dist-info/INSTALLER", Digest: &pkg.PythonFileDigest{"sha256", "zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg"}, Size: "4"}, {Path: "requests/__init__.py", Digest: &pkg.PythonFileDigest{"sha256", "PnKCgjcTq44LaAMzB-7--B2FdewRrE8F_vjZeaG9NhA"}, Size: "3921"}, @@ -28,7 +28,7 @@ func TestParseWheelEggRecord(t *testing.T) { }, }, { - Fixture: "test-fixtures/site-packages/nested/dist-name/dist-info/RECORD", + Fixture: "testdata/site-packages/nested/dist-name/dist-info/RECORD", ExpectedMetadata: []pkg.PythonFileRecord{ {Path: "../../../bin/pygmentize", Digest: &pkg.PythonFileDigest{"sha256", "dDhv_U2jiCpmFQwIRHpFRLAHUO4R1jIJPEvT_QYTFp8"}, Size: "220"}, {Path: "Pygments-2.6.1.dist-info/AUTHORS", Digest: &pkg.PythonFileDigest{"sha256", "PVpa2_Oku6BGuiUvutvuPnWGpzxqFy2I8-NIrqCvqUY"}, Size: "8449"}, @@ -64,7 +64,7 @@ func TestParseInstalledFiles(t *testing.T) { ExpectedMetadata []pkg.PythonFileRecord }{ { - Fixture: "test-fixtures/installed-files/installed-files.txt", + Fixture: "testdata/installed-files/installed-files.txt", ExpectedMetadata: []pkg.PythonFileRecord{ {Path: "../__pycache__/dicttoxml.cpython-36.pyc"}, {Path: "../dicttoxml.py"}, diff --git a/syft/pkg/cataloger/python/test-fixtures/Python-2.7.egg-info b/syft/pkg/cataloger/python/testdata/Python-2.7.egg-info similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/Python-2.7.egg-info rename to syft/pkg/cataloger/python/testdata/Python-2.7.egg-info diff --git a/syft/pkg/cataloger/python/test-fixtures/empty-1.0.0-py3.8.egg-info b/syft/pkg/cataloger/python/testdata/empty-1.0.0-py3.8.egg-info similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/empty-1.0.0-py3.8.egg-info rename to syft/pkg/cataloger/python/testdata/empty-1.0.0-py3.8.egg-info diff --git a/syft/pkg/cataloger/python/test-fixtures/glob-paths/site-packages/v.DIST-INFO/METADATA b/syft/pkg/cataloger/python/testdata/glob-paths/site-packages/v.DIST-INFO/METADATA similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/glob-paths/site-packages/v.DIST-INFO/METADATA rename to syft/pkg/cataloger/python/testdata/glob-paths/site-packages/v.DIST-INFO/METADATA diff --git a/syft/pkg/cataloger/python/test-fixtures/glob-paths/site-packages/w.EGG-INFO/PKG-INFO b/syft/pkg/cataloger/python/testdata/glob-paths/site-packages/w.EGG-INFO/PKG-INFO similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/glob-paths/site-packages/w.EGG-INFO/PKG-INFO rename to syft/pkg/cataloger/python/testdata/glob-paths/site-packages/w.EGG-INFO/PKG-INFO diff --git a/syft/pkg/cataloger/python/test-fixtures/glob-paths/site-packages/x.dist-info/METADATA b/syft/pkg/cataloger/python/testdata/glob-paths/site-packages/x.dist-info/METADATA similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/glob-paths/site-packages/x.dist-info/METADATA rename to syft/pkg/cataloger/python/testdata/glob-paths/site-packages/x.dist-info/METADATA diff --git a/syft/pkg/cataloger/python/test-fixtures/glob-paths/site-packages/y.egg-info/PKG-INFO b/syft/pkg/cataloger/python/testdata/glob-paths/site-packages/y.egg-info/PKG-INFO similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/glob-paths/site-packages/y.egg-info/PKG-INFO rename to syft/pkg/cataloger/python/testdata/glob-paths/site-packages/y.egg-info/PKG-INFO diff --git a/syft/pkg/cataloger/python/test-fixtures/glob-paths/site-packages/z.egg-info b/syft/pkg/cataloger/python/testdata/glob-paths/site-packages/z.egg-info similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/glob-paths/site-packages/z.egg-info rename to syft/pkg/cataloger/python/testdata/glob-paths/site-packages/z.egg-info diff --git a/syft/pkg/cataloger/python/test-fixtures/glob-paths/src/1-requirements-dev.txt b/syft/pkg/cataloger/python/testdata/glob-paths/src/1-requirements-dev.txt similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/glob-paths/src/1-requirements-dev.txt rename to syft/pkg/cataloger/python/testdata/glob-paths/src/1-requirements-dev.txt diff --git a/syft/pkg/cataloger/python/test-fixtures/glob-paths/src/Pipfile.lock b/syft/pkg/cataloger/python/testdata/glob-paths/src/Pipfile.lock similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/glob-paths/src/Pipfile.lock rename to syft/pkg/cataloger/python/testdata/glob-paths/src/Pipfile.lock diff --git a/syft/pkg/cataloger/python/test-fixtures/glob-paths/src/extra-requirements.txt b/syft/pkg/cataloger/python/testdata/glob-paths/src/extra-requirements.txt similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/glob-paths/src/extra-requirements.txt rename to syft/pkg/cataloger/python/testdata/glob-paths/src/extra-requirements.txt diff --git a/syft/pkg/cataloger/python/test-fixtures/glob-paths/src/pdm.lock b/syft/pkg/cataloger/python/testdata/glob-paths/src/pdm.lock similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/glob-paths/src/pdm.lock rename to syft/pkg/cataloger/python/testdata/glob-paths/src/pdm.lock diff --git a/syft/pkg/cataloger/python/test-fixtures/glob-paths/src/poetry.lock b/syft/pkg/cataloger/python/testdata/glob-paths/src/poetry.lock similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/glob-paths/src/poetry.lock rename to syft/pkg/cataloger/python/testdata/glob-paths/src/poetry.lock diff --git a/syft/pkg/cataloger/python/test-fixtures/glob-paths/src/requirements-dev.txt b/syft/pkg/cataloger/python/testdata/glob-paths/src/requirements-dev.txt similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/glob-paths/src/requirements-dev.txt rename to syft/pkg/cataloger/python/testdata/glob-paths/src/requirements-dev.txt diff --git a/syft/pkg/cataloger/python/test-fixtures/glob-paths/src/requirements.txt b/syft/pkg/cataloger/python/testdata/glob-paths/src/requirements.txt similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/glob-paths/src/requirements.txt rename to syft/pkg/cataloger/python/testdata/glob-paths/src/requirements.txt diff --git a/syft/pkg/cataloger/python/test-fixtures/glob-paths/src/setup.py b/syft/pkg/cataloger/python/testdata/glob-paths/src/setup.py similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/glob-paths/src/setup.py rename to syft/pkg/cataloger/python/testdata/glob-paths/src/setup.py diff --git a/syft/pkg/cataloger/python/test-fixtures/glob-paths/src/uv.lock b/syft/pkg/cataloger/python/testdata/glob-paths/src/uv.lock similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/glob-paths/src/uv.lock rename to syft/pkg/cataloger/python/testdata/glob-paths/src/uv.lock diff --git a/syft/pkg/cataloger/python/test-fixtures/image-multi-site-package/Dockerfile b/syft/pkg/cataloger/python/testdata/image-multi-site-package/Dockerfile similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/image-multi-site-package/Dockerfile rename to syft/pkg/cataloger/python/testdata/image-multi-site-package/Dockerfile diff --git a/syft/pkg/cataloger/python/test-fixtures/installed-files/installed-files.txt b/syft/pkg/cataloger/python/testdata/installed-files/installed-files.txt similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/installed-files/installed-files.txt rename to syft/pkg/cataloger/python/testdata/installed-files/installed-files.txt diff --git a/syft/pkg/cataloger/python/test-fixtures/pdm-lock-extras/pdm.lock b/syft/pkg/cataloger/python/testdata/pdm-lock-extras/pdm.lock similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/pdm-lock-extras/pdm.lock rename to syft/pkg/cataloger/python/testdata/pdm-lock-extras/pdm.lock diff --git a/syft/pkg/cataloger/python/test-fixtures/pdm-lock-separate-files/pdm.lock b/syft/pkg/cataloger/python/testdata/pdm-lock-separate-files/pdm.lock similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/pdm-lock-separate-files/pdm.lock rename to syft/pkg/cataloger/python/testdata/pdm-lock-separate-files/pdm.lock diff --git a/syft/pkg/cataloger/python/test-fixtures/pdm-lock/pdm.lock b/syft/pkg/cataloger/python/testdata/pdm-lock/pdm.lock similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/pdm-lock/pdm.lock rename to syft/pkg/cataloger/python/testdata/pdm-lock/pdm.lock diff --git a/syft/pkg/cataloger/python/test-fixtures/pipfile-lock/Pipfile.lock b/syft/pkg/cataloger/python/testdata/pipfile-lock/Pipfile.lock similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/pipfile-lock/Pipfile.lock rename to syft/pkg/cataloger/python/testdata/pipfile-lock/Pipfile.lock diff --git a/syft/pkg/cataloger/python/test-fixtures/poetry/case-sensitivity/poetry.lock b/syft/pkg/cataloger/python/testdata/poetry/case-sensitivity/poetry.lock similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/poetry/case-sensitivity/poetry.lock rename to syft/pkg/cataloger/python/testdata/poetry/case-sensitivity/poetry.lock diff --git a/syft/pkg/cataloger/python/test-fixtures/poetry/conflicting-with-extras/poetry.lock b/syft/pkg/cataloger/python/testdata/poetry/conflicting-with-extras/poetry.lock similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/poetry/conflicting-with-extras/poetry.lock rename to syft/pkg/cataloger/python/testdata/poetry/conflicting-with-extras/poetry.lock diff --git a/syft/pkg/cataloger/python/test-fixtures/poetry/conflicting-with-extras/pyproject.toml b/syft/pkg/cataloger/python/testdata/poetry/conflicting-with-extras/pyproject.toml similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/poetry/conflicting-with-extras/pyproject.toml rename to syft/pkg/cataloger/python/testdata/poetry/conflicting-with-extras/pyproject.toml diff --git a/syft/pkg/cataloger/python/test-fixtures/poetry/dev-deps/poetry.lock b/syft/pkg/cataloger/python/testdata/poetry/dev-deps/poetry.lock similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/poetry/dev-deps/poetry.lock rename to syft/pkg/cataloger/python/testdata/poetry/dev-deps/poetry.lock diff --git a/syft/pkg/cataloger/python/test-fixtures/poetry/multiple-extras/poetry.lock b/syft/pkg/cataloger/python/testdata/poetry/multiple-extras/poetry.lock similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/poetry/multiple-extras/poetry.lock rename to syft/pkg/cataloger/python/testdata/poetry/multiple-extras/poetry.lock diff --git a/syft/pkg/cataloger/python/test-fixtures/poetry/multiple-extras/pyproject.toml b/syft/pkg/cataloger/python/testdata/poetry/multiple-extras/pyproject.toml similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/poetry/multiple-extras/pyproject.toml rename to syft/pkg/cataloger/python/testdata/poetry/multiple-extras/pyproject.toml diff --git a/syft/pkg/cataloger/python/test-fixtures/poetry/nested-extras/poetry.lock b/syft/pkg/cataloger/python/testdata/poetry/nested-extras/poetry.lock similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/poetry/nested-extras/poetry.lock rename to syft/pkg/cataloger/python/testdata/poetry/nested-extras/poetry.lock diff --git a/syft/pkg/cataloger/python/test-fixtures/poetry/nested-extras/pyproject.toml b/syft/pkg/cataloger/python/testdata/poetry/nested-extras/pyproject.toml similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/poetry/nested-extras/pyproject.toml rename to syft/pkg/cataloger/python/testdata/poetry/nested-extras/pyproject.toml diff --git a/syft/pkg/cataloger/python/test-fixtures/poetry/simple-deps/poetry.lock b/syft/pkg/cataloger/python/testdata/poetry/simple-deps/poetry.lock similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/poetry/simple-deps/poetry.lock rename to syft/pkg/cataloger/python/testdata/poetry/simple-deps/poetry.lock diff --git a/syft/pkg/cataloger/python/test-fixtures/poetry/simple-deps/pyproject.toml b/syft/pkg/cataloger/python/testdata/poetry/simple-deps/pyproject.toml similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/poetry/simple-deps/pyproject.toml rename to syft/pkg/cataloger/python/testdata/poetry/simple-deps/pyproject.toml diff --git a/syft/pkg/cataloger/python/test-fixtures/pyenv/good-config b/syft/pkg/cataloger/python/testdata/pyenv/good-config similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/pyenv/good-config rename to syft/pkg/cataloger/python/testdata/pyenv/good-config diff --git a/syft/pkg/cataloger/python/test-fixtures/pyenv/trixy-config b/syft/pkg/cataloger/python/testdata/pyenv/trixy-config similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/pyenv/trixy-config rename to syft/pkg/cataloger/python/testdata/pyenv/trixy-config diff --git a/syft/pkg/cataloger/python/test-fixtures/pypi-remote/Pipfile.lock b/syft/pkg/cataloger/python/testdata/pypi-remote/Pipfile.lock similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/pypi-remote/Pipfile.lock rename to syft/pkg/cataloger/python/testdata/pypi-remote/Pipfile.lock diff --git a/syft/pkg/cataloger/python/test-fixtures/pypi-remote/pdm.lock b/syft/pkg/cataloger/python/testdata/pypi-remote/pdm.lock similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/pypi-remote/pdm.lock rename to syft/pkg/cataloger/python/testdata/pypi-remote/pdm.lock diff --git a/syft/pkg/cataloger/python/test-fixtures/pypi-remote/poetry.lock b/syft/pkg/cataloger/python/testdata/pypi-remote/poetry.lock similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/pypi-remote/poetry.lock rename to syft/pkg/cataloger/python/testdata/pypi-remote/poetry.lock diff --git a/syft/pkg/cataloger/python/test-fixtures/pypi-remote/pyproject.toml b/syft/pkg/cataloger/python/testdata/pypi-remote/pyproject.toml similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/pypi-remote/pyproject.toml rename to syft/pkg/cataloger/python/testdata/pypi-remote/pyproject.toml diff --git a/syft/pkg/cataloger/python/test-fixtures/pypi-remote/registry_response.json b/syft/pkg/cataloger/python/testdata/pypi-remote/registry_response.json similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/pypi-remote/registry_response.json rename to syft/pkg/cataloger/python/testdata/pypi-remote/registry_response.json diff --git a/syft/pkg/cataloger/python/test-fixtures/pypi-remote/registry_response_bad.json b/syft/pkg/cataloger/python/testdata/pypi-remote/registry_response_bad.json similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/pypi-remote/registry_response_bad.json rename to syft/pkg/cataloger/python/testdata/pypi-remote/registry_response_bad.json diff --git a/syft/pkg/cataloger/python/test-fixtures/pypi-remote/requirements.txt b/syft/pkg/cataloger/python/testdata/pypi-remote/requirements.txt similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/pypi-remote/requirements.txt rename to syft/pkg/cataloger/python/testdata/pypi-remote/requirements.txt diff --git a/syft/pkg/cataloger/python/test-fixtures/pypi-remote/setup.py b/syft/pkg/cataloger/python/testdata/pypi-remote/setup.py similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/pypi-remote/setup.py rename to syft/pkg/cataloger/python/testdata/pypi-remote/setup.py diff --git a/syft/pkg/cataloger/python/test-fixtures/pypi-remote/uv.lock b/syft/pkg/cataloger/python/testdata/pypi-remote/uv.lock similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/pypi-remote/uv.lock rename to syft/pkg/cataloger/python/testdata/pypi-remote/uv.lock diff --git a/syft/pkg/cataloger/python/test-fixtures/requires/requirements.txt b/syft/pkg/cataloger/python/testdata/requires/requirements.txt similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/requires/requirements.txt rename to syft/pkg/cataloger/python/testdata/requires/requirements.txt diff --git a/syft/pkg/cataloger/python/test-fixtures/setup/dynamic-setup.py b/syft/pkg/cataloger/python/testdata/setup/dynamic-setup.py similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/setup/dynamic-setup.py rename to syft/pkg/cataloger/python/testdata/setup/dynamic-setup.py diff --git a/syft/pkg/cataloger/python/test-fixtures/setup/mixed-format-setup.py b/syft/pkg/cataloger/python/testdata/setup/mixed-format-setup.py similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/setup/mixed-format-setup.py rename to syft/pkg/cataloger/python/testdata/setup/mixed-format-setup.py diff --git a/syft/pkg/cataloger/python/test-fixtures/setup/multiline-split-setup.py b/syft/pkg/cataloger/python/testdata/setup/multiline-split-setup.py similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/setup/multiline-split-setup.py rename to syft/pkg/cataloger/python/testdata/setup/multiline-split-setup.py diff --git a/syft/pkg/cataloger/python/test-fixtures/setup/setup.py b/syft/pkg/cataloger/python/testdata/setup/setup.py similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/setup/setup.py rename to syft/pkg/cataloger/python/testdata/setup/setup.py diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/license/with-license-file-declared.dist-info/LICENSE.txt b/syft/pkg/cataloger/python/testdata/site-packages/license/with-license-file-declared.dist-info/LICENSE.txt similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/license/with-license-file-declared.dist-info/LICENSE.txt rename to syft/pkg/cataloger/python/testdata/site-packages/license/with-license-file-declared.dist-info/LICENSE.txt diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/license/with-license-file-declared.dist-info/METADATA b/syft/pkg/cataloger/python/testdata/site-packages/license/with-license-file-declared.dist-info/METADATA similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/license/with-license-file-declared.dist-info/METADATA rename to syft/pkg/cataloger/python/testdata/site-packages/license/with-license-file-declared.dist-info/METADATA diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/license/with-license-file-declared.dist-info/RECORD b/syft/pkg/cataloger/python/testdata/site-packages/license/with-license-file-declared.dist-info/RECORD similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/license/with-license-file-declared.dist-info/RECORD rename to syft/pkg/cataloger/python/testdata/site-packages/license/with-license-file-declared.dist-info/RECORD diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/license/with-license-file-declared.dist-info/direct_url.json b/syft/pkg/cataloger/python/testdata/site-packages/license/with-license-file-declared.dist-info/direct_url.json similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/license/with-license-file-declared.dist-info/direct_url.json rename to syft/pkg/cataloger/python/testdata/site-packages/license/with-license-file-declared.dist-info/direct_url.json diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/license/with-license-file-declared.dist-info/top_level.txt b/syft/pkg/cataloger/python/testdata/site-packages/license/with-license-file-declared.dist-info/top_level.txt similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/license/with-license-file-declared.dist-info/top_level.txt rename to syft/pkg/cataloger/python/testdata/site-packages/license/with-license-file-declared.dist-info/top_level.txt diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/license/without-license-file-declared.dist-info/LICENSE.txt b/syft/pkg/cataloger/python/testdata/site-packages/license/without-license-file-declared.dist-info/LICENSE.txt similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/license/without-license-file-declared.dist-info/LICENSE.txt rename to syft/pkg/cataloger/python/testdata/site-packages/license/without-license-file-declared.dist-info/LICENSE.txt diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/license/without-license-file-declared.dist-info/METADATA b/syft/pkg/cataloger/python/testdata/site-packages/license/without-license-file-declared.dist-info/METADATA similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/license/without-license-file-declared.dist-info/METADATA rename to syft/pkg/cataloger/python/testdata/site-packages/license/without-license-file-declared.dist-info/METADATA diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/license/without-license-file-declared.dist-info/RECORD b/syft/pkg/cataloger/python/testdata/site-packages/license/without-license-file-declared.dist-info/RECORD similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/license/without-license-file-declared.dist-info/RECORD rename to syft/pkg/cataloger/python/testdata/site-packages/license/without-license-file-declared.dist-info/RECORD diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/license/without-license-file-declared.dist-info/direct_url.json b/syft/pkg/cataloger/python/testdata/site-packages/license/without-license-file-declared.dist-info/direct_url.json similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/license/without-license-file-declared.dist-info/direct_url.json rename to syft/pkg/cataloger/python/testdata/site-packages/license/without-license-file-declared.dist-info/direct_url.json diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/license/without-license-file-declared.dist-info/top_level.txt b/syft/pkg/cataloger/python/testdata/site-packages/license/without-license-file-declared.dist-info/top_level.txt similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/license/without-license-file-declared.dist-info/top_level.txt rename to syft/pkg/cataloger/python/testdata/site-packages/license/without-license-file-declared.dist-info/top_level.txt diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/malformed-record/dist-info/METADATA b/syft/pkg/cataloger/python/testdata/site-packages/malformed-record/dist-info/METADATA similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/malformed-record/dist-info/METADATA rename to syft/pkg/cataloger/python/testdata/site-packages/malformed-record/dist-info/METADATA diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/malformed-record/dist-info/RECORD b/syft/pkg/cataloger/python/testdata/site-packages/malformed-record/dist-info/RECORD similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/malformed-record/dist-info/RECORD rename to syft/pkg/cataloger/python/testdata/site-packages/malformed-record/dist-info/RECORD diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/nested/dist-name/dist-info/LICENSE.txt b/syft/pkg/cataloger/python/testdata/site-packages/nested/dist-name/dist-info/LICENSE.txt similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/nested/dist-name/dist-info/LICENSE.txt rename to syft/pkg/cataloger/python/testdata/site-packages/nested/dist-name/dist-info/LICENSE.txt diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/nested/dist-name/dist-info/METADATA b/syft/pkg/cataloger/python/testdata/site-packages/nested/dist-name/dist-info/METADATA similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/nested/dist-name/dist-info/METADATA rename to syft/pkg/cataloger/python/testdata/site-packages/nested/dist-name/dist-info/METADATA diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/nested/dist-name/dist-info/RECORD b/syft/pkg/cataloger/python/testdata/site-packages/nested/dist-name/dist-info/RECORD similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/nested/dist-name/dist-info/RECORD rename to syft/pkg/cataloger/python/testdata/site-packages/nested/dist-name/dist-info/RECORD diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/nested/dist-name/dist-info/direct_url.json b/syft/pkg/cataloger/python/testdata/site-packages/nested/dist-name/dist-info/direct_url.json similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/nested/dist-name/dist-info/direct_url.json rename to syft/pkg/cataloger/python/testdata/site-packages/nested/dist-name/dist-info/direct_url.json diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/nested/dist-name/dist-info/top_level.txt b/syft/pkg/cataloger/python/testdata/site-packages/nested/dist-name/dist-info/top_level.txt similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/nested/dist-name/dist-info/top_level.txt rename to syft/pkg/cataloger/python/testdata/site-packages/nested/dist-name/dist-info/top_level.txt diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/nested/egg-name/egg-info/PKG-INFO b/syft/pkg/cataloger/python/testdata/site-packages/nested/egg-name/egg-info/PKG-INFO similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/nested/egg-name/egg-info/PKG-INFO rename to syft/pkg/cataloger/python/testdata/site-packages/nested/egg-name/egg-info/PKG-INFO diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/nested/egg-name/egg-info/PKG-INFO-INVALID b/syft/pkg/cataloger/python/testdata/site-packages/nested/egg-name/egg-info/PKG-INFO-INVALID similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/nested/egg-name/egg-info/PKG-INFO-INVALID rename to syft/pkg/cataloger/python/testdata/site-packages/nested/egg-name/egg-info/PKG-INFO-INVALID diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/nested/egg-name/egg-info/RECORD b/syft/pkg/cataloger/python/testdata/site-packages/nested/egg-name/egg-info/RECORD similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/nested/egg-name/egg-info/RECORD rename to syft/pkg/cataloger/python/testdata/site-packages/nested/egg-name/egg-info/RECORD diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/nested/egg-name/egg-info/top_level.txt b/syft/pkg/cataloger/python/testdata/site-packages/nested/egg-name/egg-info/top_level.txt similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/nested/egg-name/egg-info/top_level.txt rename to syft/pkg/cataloger/python/testdata/site-packages/nested/egg-name/egg-info/top_level.txt diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/no-version/no-version-py3.8.egg-info b/syft/pkg/cataloger/python/testdata/site-packages/no-version/no-version-py3.8.egg-info similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/no-version/no-version-py3.8.egg-info rename to syft/pkg/cataloger/python/testdata/site-packages/no-version/no-version-py3.8.egg-info diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/partial.dist-info/METADATA b/syft/pkg/cataloger/python/testdata/site-packages/partial.dist-info/METADATA similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/partial.dist-info/METADATA rename to syft/pkg/cataloger/python/testdata/site-packages/partial.dist-info/METADATA diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/test/test.egg-info b/syft/pkg/cataloger/python/testdata/site-packages/test/test.egg-info similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/test/test.egg-info rename to syft/pkg/cataloger/python/testdata/site-packages/test/test.egg-info diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/uppercase/dist-name/DIST-INFO/METADATA b/syft/pkg/cataloger/python/testdata/site-packages/uppercase/dist-name/DIST-INFO/METADATA similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/uppercase/dist-name/DIST-INFO/METADATA rename to syft/pkg/cataloger/python/testdata/site-packages/uppercase/dist-name/DIST-INFO/METADATA diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/uppercase/dist-name/DIST-INFO/RECORD b/syft/pkg/cataloger/python/testdata/site-packages/uppercase/dist-name/DIST-INFO/RECORD similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/uppercase/dist-name/DIST-INFO/RECORD rename to syft/pkg/cataloger/python/testdata/site-packages/uppercase/dist-name/DIST-INFO/RECORD diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/uppercase/dist-name/DIST-INFO/direct_url.json b/syft/pkg/cataloger/python/testdata/site-packages/uppercase/dist-name/DIST-INFO/direct_url.json similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/uppercase/dist-name/DIST-INFO/direct_url.json rename to syft/pkg/cataloger/python/testdata/site-packages/uppercase/dist-name/DIST-INFO/direct_url.json diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/uppercase/dist-name/DIST-INFO/top_level.txt b/syft/pkg/cataloger/python/testdata/site-packages/uppercase/dist-name/DIST-INFO/top_level.txt similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/uppercase/dist-name/DIST-INFO/top_level.txt rename to syft/pkg/cataloger/python/testdata/site-packages/uppercase/dist-name/DIST-INFO/top_level.txt diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/uppercase/egg-name/EGG-INFO/PKG-INFO b/syft/pkg/cataloger/python/testdata/site-packages/uppercase/egg-name/EGG-INFO/PKG-INFO similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/uppercase/egg-name/EGG-INFO/PKG-INFO rename to syft/pkg/cataloger/python/testdata/site-packages/uppercase/egg-name/EGG-INFO/PKG-INFO diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/uppercase/egg-name/EGG-INFO/PKG-INFO-INVALID b/syft/pkg/cataloger/python/testdata/site-packages/uppercase/egg-name/EGG-INFO/PKG-INFO-INVALID similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/uppercase/egg-name/EGG-INFO/PKG-INFO-INVALID rename to syft/pkg/cataloger/python/testdata/site-packages/uppercase/egg-name/EGG-INFO/PKG-INFO-INVALID diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/uppercase/egg-name/EGG-INFO/RECORD b/syft/pkg/cataloger/python/testdata/site-packages/uppercase/egg-name/EGG-INFO/RECORD similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/uppercase/egg-name/EGG-INFO/RECORD rename to syft/pkg/cataloger/python/testdata/site-packages/uppercase/egg-name/EGG-INFO/RECORD diff --git a/syft/pkg/cataloger/python/test-fixtures/site-packages/uppercase/egg-name/EGG-INFO/top_level.txt b/syft/pkg/cataloger/python/testdata/site-packages/uppercase/egg-name/EGG-INFO/top_level.txt similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/site-packages/uppercase/egg-name/EGG-INFO/top_level.txt rename to syft/pkg/cataloger/python/testdata/site-packages/uppercase/egg-name/EGG-INFO/top_level.txt diff --git a/syft/pkg/cataloger/python/test-fixtures/uv/conflicting-with-extras/pyproject.toml b/syft/pkg/cataloger/python/testdata/uv/conflicting-with-extras/pyproject.toml similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/uv/conflicting-with-extras/pyproject.toml rename to syft/pkg/cataloger/python/testdata/uv/conflicting-with-extras/pyproject.toml diff --git a/syft/pkg/cataloger/python/test-fixtures/uv/conflicting-with-extras/uv.lock b/syft/pkg/cataloger/python/testdata/uv/conflicting-with-extras/uv.lock similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/uv/conflicting-with-extras/uv.lock rename to syft/pkg/cataloger/python/testdata/uv/conflicting-with-extras/uv.lock diff --git a/syft/pkg/cataloger/python/test-fixtures/uv/multiple-extras/pyproject.toml b/syft/pkg/cataloger/python/testdata/uv/multiple-extras/pyproject.toml similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/uv/multiple-extras/pyproject.toml rename to syft/pkg/cataloger/python/testdata/uv/multiple-extras/pyproject.toml diff --git a/syft/pkg/cataloger/python/test-fixtures/uv/multiple-extras/uv.lock b/syft/pkg/cataloger/python/testdata/uv/multiple-extras/uv.lock similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/uv/multiple-extras/uv.lock rename to syft/pkg/cataloger/python/testdata/uv/multiple-extras/uv.lock diff --git a/syft/pkg/cataloger/python/test-fixtures/uv/nested-extras/pyproject.toml b/syft/pkg/cataloger/python/testdata/uv/nested-extras/pyproject.toml similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/uv/nested-extras/pyproject.toml rename to syft/pkg/cataloger/python/testdata/uv/nested-extras/pyproject.toml diff --git a/syft/pkg/cataloger/python/test-fixtures/uv/nested-extras/uv.lock b/syft/pkg/cataloger/python/testdata/uv/nested-extras/uv.lock similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/uv/nested-extras/uv.lock rename to syft/pkg/cataloger/python/testdata/uv/nested-extras/uv.lock diff --git a/syft/pkg/cataloger/python/test-fixtures/uv/simple-deps/pyproject.toml b/syft/pkg/cataloger/python/testdata/uv/simple-deps/pyproject.toml similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/uv/simple-deps/pyproject.toml rename to syft/pkg/cataloger/python/testdata/uv/simple-deps/pyproject.toml diff --git a/syft/pkg/cataloger/python/test-fixtures/uv/simple-deps/uv.lock b/syft/pkg/cataloger/python/testdata/uv/simple-deps/uv.lock similarity index 100% rename from syft/pkg/cataloger/python/test-fixtures/uv/simple-deps/uv.lock rename to syft/pkg/cataloger/python/testdata/uv/simple-deps/uv.lock diff --git a/syft/pkg/cataloger/python/virtual_env_test.go b/syft/pkg/cataloger/python/virtual_env_test.go index a8705c152..c08f65097 100644 --- a/syft/pkg/cataloger/python/virtual_env_test.go +++ b/syft/pkg/cataloger/python/virtual_env_test.go @@ -21,7 +21,7 @@ func Test_parsePyvenvCfgReader(t *testing.T) { }{ { name: "parse basic pyenv file", - fixture: "test-fixtures/pyenv/good-config", + fixture: "testdata/pyenv/good-config", want: &virtualEnvInfo{ Location: location, Version: "3.9.5", @@ -30,7 +30,7 @@ func Test_parsePyvenvCfgReader(t *testing.T) { }, { name: "trixy config cases", - fixture: "test-fixtures/pyenv/trixy-config", + fixture: "testdata/pyenv/trixy-config", want: &virtualEnvInfo{ Location: location, Version: "3.3.3", diff --git a/syft/pkg/cataloger/r/cataloger_test.go b/syft/pkg/cataloger/r/cataloger_test.go index b545859a6..3297861a4 100644 --- a/syft/pkg/cataloger/r/cataloger_test.go +++ b/syft/pkg/cataloger/r/cataloger_test.go @@ -56,5 +56,5 @@ func TestRPackageCataloger(t *testing.T) { // TODO: relationships are not under test yet var expectedRelationships []artifact.Relationship - pkgtest.NewCatalogTester().FromDirectory(t, "test-fixtures/installed").Expects(expectedPkgs, expectedRelationships).TestCataloger(t, NewPackageCataloger()) + pkgtest.NewCatalogTester().FromDirectory(t, "testdata/installed").Expects(expectedPkgs, expectedRelationships).TestCataloger(t, NewPackageCataloger()) } diff --git a/syft/pkg/cataloger/r/parse_description_test.go b/syft/pkg/cataloger/r/parse_description_test.go index 868f6a2be..32d170b77 100644 --- a/syft/pkg/cataloger/r/parse_description_test.go +++ b/syft/pkg/cataloger/r/parse_description_test.go @@ -23,7 +23,7 @@ func Test_parseDescriptionFile(t *testing.T) { }{ { name: "no package is returned if no version found", - fixture: filepath.Join("test-fixtures", "map-parse", "no-version"), + fixture: filepath.Join("testdata", "map-parse", "no-version"), assertions: packageAssertions{ func(t *testing.T, p []pkg.Package) { assert.Empty(t, p) @@ -32,7 +32,7 @@ func Test_parseDescriptionFile(t *testing.T) { }, { name: "no package is returned if no package name found", - fixture: filepath.Join("test-fixtures", "map-parse", "no-name"), + fixture: filepath.Join("testdata", "map-parse", "no-name"), assertions: packageAssertions{ func(t *testing.T, p []pkg.Package) { assert.Empty(t, p) @@ -41,7 +41,7 @@ func Test_parseDescriptionFile(t *testing.T) { }, { name: "package return if both name and version found", - fixture: filepath.Join("test-fixtures", "map-parse", "simple"), + fixture: filepath.Join("testdata", "map-parse", "simple"), assertions: packageAssertions{ func(t *testing.T, p []pkg.Package) { assert.Equal(t, 1, len(p)) @@ -76,7 +76,7 @@ func Test_extractFieldsFromDescriptionFile(t *testing.T) { }{ { name: "go case", - fixture: "test-fixtures/map-parse/simple", + fixture: "testdata/map-parse/simple", want: map[string]string{ "Package": "base", "Version": "4.3.0", @@ -86,7 +86,7 @@ func Test_extractFieldsFromDescriptionFile(t *testing.T) { }, { name: "bad cases", - fixture: "test-fixtures/map-parse/bad", + fixture: "testdata/map-parse/bad", want: map[string]string{ "Key": "", "Whitespace": "", @@ -94,7 +94,7 @@ func Test_extractFieldsFromDescriptionFile(t *testing.T) { }, { name: "multiline key-value", - fixture: "test-fixtures/map-parse/multiline", + fixture: "testdata/map-parse/multiline", want: map[string]string{ "Description": `A consistent, simple and easy to use set of wrappers around the fantastic 'stringi' package. All function and argument names (and @@ -107,7 +107,7 @@ easy to feed into the input of another.`, }, { name: "eof multiline", - fixture: "test-fixtures/map-parse/eof-multiline", + fixture: "testdata/map-parse/eof-multiline", want: map[string]string{ "License": "MIT + file LICENSE", "Description": `A consistent, simple and easy to use set of wrappers around diff --git a/syft/pkg/cataloger/r/test-fixtures/DESCRIPTION b/syft/pkg/cataloger/r/testdata/DESCRIPTION similarity index 100% rename from syft/pkg/cataloger/r/test-fixtures/DESCRIPTION rename to syft/pkg/cataloger/r/testdata/DESCRIPTION diff --git a/syft/pkg/cataloger/r/test-fixtures/installed/base/DESCRIPTION b/syft/pkg/cataloger/r/testdata/installed/base/DESCRIPTION similarity index 100% rename from syft/pkg/cataloger/r/test-fixtures/installed/base/DESCRIPTION rename to syft/pkg/cataloger/r/testdata/installed/base/DESCRIPTION diff --git a/syft/pkg/cataloger/r/test-fixtures/installed/stringr/DESCRIPTION b/syft/pkg/cataloger/r/testdata/installed/stringr/DESCRIPTION similarity index 100% rename from syft/pkg/cataloger/r/test-fixtures/installed/stringr/DESCRIPTION rename to syft/pkg/cataloger/r/testdata/installed/stringr/DESCRIPTION diff --git a/syft/pkg/cataloger/r/test-fixtures/map-parse/bad b/syft/pkg/cataloger/r/testdata/map-parse/bad similarity index 100% rename from syft/pkg/cataloger/r/test-fixtures/map-parse/bad rename to syft/pkg/cataloger/r/testdata/map-parse/bad diff --git a/syft/pkg/cataloger/r/test-fixtures/map-parse/eof-multiline b/syft/pkg/cataloger/r/testdata/map-parse/eof-multiline similarity index 100% rename from syft/pkg/cataloger/r/test-fixtures/map-parse/eof-multiline rename to syft/pkg/cataloger/r/testdata/map-parse/eof-multiline diff --git a/syft/pkg/cataloger/r/test-fixtures/map-parse/multiline b/syft/pkg/cataloger/r/testdata/map-parse/multiline similarity index 100% rename from syft/pkg/cataloger/r/test-fixtures/map-parse/multiline rename to syft/pkg/cataloger/r/testdata/map-parse/multiline diff --git a/syft/pkg/cataloger/r/test-fixtures/map-parse/no-name b/syft/pkg/cataloger/r/testdata/map-parse/no-name similarity index 100% rename from syft/pkg/cataloger/r/test-fixtures/map-parse/no-name rename to syft/pkg/cataloger/r/testdata/map-parse/no-name diff --git a/syft/pkg/cataloger/r/test-fixtures/map-parse/no-version b/syft/pkg/cataloger/r/testdata/map-parse/no-version similarity index 100% rename from syft/pkg/cataloger/r/test-fixtures/map-parse/no-version rename to syft/pkg/cataloger/r/testdata/map-parse/no-version diff --git a/syft/pkg/cataloger/r/test-fixtures/map-parse/simple b/syft/pkg/cataloger/r/testdata/map-parse/simple similarity index 100% rename from syft/pkg/cataloger/r/test-fixtures/map-parse/simple rename to syft/pkg/cataloger/r/testdata/map-parse/simple diff --git a/syft/pkg/cataloger/redhat/cataloger_test.go b/syft/pkg/cataloger/redhat/cataloger_test.go index b7088346b..a12bc9bd3 100644 --- a/syft/pkg/cataloger/redhat/cataloger_test.go +++ b/syft/pkg/cataloger/redhat/cataloger_test.go @@ -199,7 +199,7 @@ func Test_DBCataloger_Globs(t *testing.T) { }{ { name: "obtain DB files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "usr/share/rpm/Packages", "usr/share/rpm/Packages.db", @@ -233,7 +233,7 @@ func Test_RPMFileCataloger_Globs(t *testing.T) { }{ { name: "obtain rpm files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "dive-0.10.0.rpm", }, diff --git a/syft/pkg/cataloger/redhat/parse_rpm_archive_test.go b/syft/pkg/cataloger/redhat/parse_rpm_archive_test.go index 25ef254ef..28083b6be 100644 --- a/syft/pkg/cataloger/redhat/parse_rpm_archive_test.go +++ b/syft/pkg/cataloger/redhat/parse_rpm_archive_test.go @@ -28,7 +28,7 @@ func TestParseRpmFiles(t *testing.T) { }{ { name: "go case", - fixtureDir: "test-fixtures/rpms", + fixtureDir: "testdata/rpms", expected: []pkg.Package{ { Name: "abc", @@ -110,7 +110,7 @@ func TestParseRpmFiles(t *testing.T) { }, { name: "bad rpms", - fixtureDir: "test-fixtures/bad", + fixtureDir: "testdata/bad", }, { name: "rpms with signatures from RSA header", @@ -233,7 +233,7 @@ func ref[T any](v T) *T { func Test_corruptRpmArchive(t *testing.T) { pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/bad/bad.rpm"). + FromFile(t, "testdata/bad/bad.rpm"). WithError(). TestParser(t, parseRpmArchive) } diff --git a/syft/pkg/cataloger/redhat/parse_rpm_db_test.go b/syft/pkg/cataloger/redhat/parse_rpm_db_test.go index aac34bf59..b1d10f0db 100644 --- a/syft/pkg/cataloger/redhat/parse_rpm_db_test.go +++ b/syft/pkg/cataloger/redhat/parse_rpm_db_test.go @@ -86,14 +86,14 @@ func (r *rpmdbTestFileResolverMock) FilesByMediaType(...string) ([]file.Location func TestParseRpmDB(t *testing.T) { ctx := context.TODO() - packagesLocation := file.NewLocation("test-fixtures/Packages") + packagesLocation := file.NewLocation("testdata/Packages") tests := []struct { fixture string expected []pkg.Package ignorePaths bool }{ { - fixture: "test-fixtures/Packages", + fixture: "testdata/Packages", // we only surface package paths for files that exist (here we DO NOT expect a path) ignorePaths: true, expected: []pkg.Package{ @@ -101,7 +101,7 @@ func TestParseRpmDB(t *testing.T) { Name: "dive", Version: "0.9.2-1", PURL: "pkg:rpm/dive@0.9.2-1?arch=x86_64&upstream=dive-0.9.2-1.src.rpm", - Locations: file.NewLocationSet(file.NewLocation("test-fixtures/Packages")), + Locations: file.NewLocationSet(file.NewLocation("testdata/Packages")), Type: pkg.RpmPkg, Licenses: pkg.NewLicenseSet( pkg.NewLicenseFromLocationsWithContext(ctx, "MIT", packagesLocation), @@ -123,7 +123,7 @@ func TestParseRpmDB(t *testing.T) { }, }, { - fixture: "test-fixtures/Packages", + fixture: "testdata/Packages", // we only surface package paths for files that exist (here we expect a path) ignorePaths: false, expected: []pkg.Package{ @@ -222,7 +222,7 @@ func TestToElVersion(t *testing.T) { func Test_corruptRpmDbEntry(t *testing.T) { pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/glob-paths/usr/lib/sysimage/rpm/Packages.db"). + FromFile(t, "testdata/glob-paths/usr/lib/sysimage/rpm/Packages.db"). WithError(). TestParser(t, parseRpmDB) } diff --git a/syft/pkg/cataloger/redhat/parse_rpm_manifest_test.go b/syft/pkg/cataloger/redhat/parse_rpm_manifest_test.go index 5a2cd2666..fdc80dce5 100644 --- a/syft/pkg/cataloger/redhat/parse_rpm_manifest_test.go +++ b/syft/pkg/cataloger/redhat/parse_rpm_manifest_test.go @@ -9,7 +9,7 @@ import ( ) func TestParseRpmManifest(t *testing.T) { - fixture := "test-fixtures/container-manifest-2" + fixture := "testdata/container-manifest-2" location := file.NewLocation(fixture) expected := []pkg.Package{ { diff --git a/syft/pkg/cataloger/redhat/sqlitetest/no_sqlite_driver_test.go b/syft/pkg/cataloger/redhat/sqlitetest/no_sqlite_driver_test.go index 894569200..1e42b5f1c 100644 --- a/syft/pkg/cataloger/redhat/sqlitetest/no_sqlite_driver_test.go +++ b/syft/pkg/cataloger/redhat/sqlitetest/no_sqlite_driver_test.go @@ -12,7 +12,7 @@ import ( func Test_noSQLiteDriverError(t *testing.T) { // this test package does must not import the sqlite library - file := "../test-fixtures/Packages" + file := "../testdata/Packages" resolver, err := fileresolver.NewFromFile(file) require.NoError(t, err) diff --git a/syft/pkg/cataloger/redhat/test-fixtures/.gitignore b/syft/pkg/cataloger/redhat/testdata/.gitignore similarity index 100% rename from syft/pkg/cataloger/redhat/test-fixtures/.gitignore rename to syft/pkg/cataloger/redhat/testdata/.gitignore diff --git a/syft/pkg/cataloger/redhat/test-fixtures/Makefile b/syft/pkg/cataloger/redhat/testdata/Makefile similarity index 100% rename from syft/pkg/cataloger/redhat/test-fixtures/Makefile rename to syft/pkg/cataloger/redhat/testdata/Makefile diff --git a/syft/pkg/cataloger/redhat/test-fixtures/Packages b/syft/pkg/cataloger/redhat/testdata/Packages similarity index 100% rename from syft/pkg/cataloger/redhat/test-fixtures/Packages rename to syft/pkg/cataloger/redhat/testdata/Packages diff --git a/syft/pkg/cataloger/redhat/test-fixtures/bad/bad.rpm b/syft/pkg/cataloger/redhat/testdata/bad/bad.rpm similarity index 100% rename from syft/pkg/cataloger/redhat/test-fixtures/bad/bad.rpm rename to syft/pkg/cataloger/redhat/testdata/bad/bad.rpm diff --git a/syft/pkg/cataloger/redhat/test-fixtures/container-manifest-2 b/syft/pkg/cataloger/redhat/testdata/container-manifest-2 similarity index 100% rename from syft/pkg/cataloger/redhat/test-fixtures/container-manifest-2 rename to syft/pkg/cataloger/redhat/testdata/container-manifest-2 diff --git a/syft/pkg/cataloger/redhat/test-fixtures/generate-fixture.sh b/syft/pkg/cataloger/redhat/testdata/generate-fixture.sh similarity index 100% rename from syft/pkg/cataloger/redhat/test-fixtures/generate-fixture.sh rename to syft/pkg/cataloger/redhat/testdata/generate-fixture.sh diff --git a/syft/pkg/cataloger/redhat/test-fixtures/glob-paths/dive-0.10.0.rpm b/syft/pkg/cataloger/redhat/testdata/glob-paths/dive-0.10.0.rpm similarity index 100% rename from syft/pkg/cataloger/redhat/test-fixtures/glob-paths/dive-0.10.0.rpm rename to syft/pkg/cataloger/redhat/testdata/glob-paths/dive-0.10.0.rpm diff --git a/syft/pkg/cataloger/redhat/test-fixtures/glob-paths/usr/lib/sysimage/rpm/Packages b/syft/pkg/cataloger/redhat/testdata/glob-paths/usr/lib/sysimage/rpm/Packages similarity index 100% rename from syft/pkg/cataloger/redhat/test-fixtures/glob-paths/usr/lib/sysimage/rpm/Packages rename to syft/pkg/cataloger/redhat/testdata/glob-paths/usr/lib/sysimage/rpm/Packages diff --git a/syft/pkg/cataloger/redhat/test-fixtures/glob-paths/usr/lib/sysimage/rpm/Packages.db b/syft/pkg/cataloger/redhat/testdata/glob-paths/usr/lib/sysimage/rpm/Packages.db similarity index 100% rename from syft/pkg/cataloger/redhat/test-fixtures/glob-paths/usr/lib/sysimage/rpm/Packages.db rename to syft/pkg/cataloger/redhat/testdata/glob-paths/usr/lib/sysimage/rpm/Packages.db diff --git a/syft/pkg/cataloger/redhat/test-fixtures/glob-paths/usr/lib/sysimage/rpm/rpmdb.sqlite b/syft/pkg/cataloger/redhat/testdata/glob-paths/usr/lib/sysimage/rpm/rpmdb.sqlite similarity index 100% rename from syft/pkg/cataloger/redhat/test-fixtures/glob-paths/usr/lib/sysimage/rpm/rpmdb.sqlite rename to syft/pkg/cataloger/redhat/testdata/glob-paths/usr/lib/sysimage/rpm/rpmdb.sqlite diff --git a/syft/pkg/cataloger/redhat/test-fixtures/glob-paths/usr/share/rpm/Packages b/syft/pkg/cataloger/redhat/testdata/glob-paths/usr/share/rpm/Packages similarity index 100% rename from syft/pkg/cataloger/redhat/test-fixtures/glob-paths/usr/share/rpm/Packages rename to syft/pkg/cataloger/redhat/testdata/glob-paths/usr/share/rpm/Packages diff --git a/syft/pkg/cataloger/redhat/test-fixtures/glob-paths/usr/share/rpm/Packages.db b/syft/pkg/cataloger/redhat/testdata/glob-paths/usr/share/rpm/Packages.db similarity index 100% rename from syft/pkg/cataloger/redhat/test-fixtures/glob-paths/usr/share/rpm/Packages.db rename to syft/pkg/cataloger/redhat/testdata/glob-paths/usr/share/rpm/Packages.db diff --git a/syft/pkg/cataloger/redhat/test-fixtures/glob-paths/usr/share/rpm/rpmdb.sqlite b/syft/pkg/cataloger/redhat/testdata/glob-paths/usr/share/rpm/rpmdb.sqlite similarity index 100% rename from syft/pkg/cataloger/redhat/test-fixtures/glob-paths/usr/share/rpm/rpmdb.sqlite rename to syft/pkg/cataloger/redhat/testdata/glob-paths/usr/share/rpm/rpmdb.sqlite diff --git a/syft/pkg/cataloger/redhat/test-fixtures/glob-paths/var/lib/rpm/Packages b/syft/pkg/cataloger/redhat/testdata/glob-paths/var/lib/rpm/Packages similarity index 100% rename from syft/pkg/cataloger/redhat/test-fixtures/glob-paths/var/lib/rpm/Packages rename to syft/pkg/cataloger/redhat/testdata/glob-paths/var/lib/rpm/Packages diff --git a/syft/pkg/cataloger/redhat/test-fixtures/glob-paths/var/lib/rpm/Packages.db b/syft/pkg/cataloger/redhat/testdata/glob-paths/var/lib/rpm/Packages.db similarity index 100% rename from syft/pkg/cataloger/redhat/test-fixtures/glob-paths/var/lib/rpm/Packages.db rename to syft/pkg/cataloger/redhat/testdata/glob-paths/var/lib/rpm/Packages.db diff --git a/syft/pkg/cataloger/redhat/test-fixtures/glob-paths/var/lib/rpm/rpmdb.sqlite b/syft/pkg/cataloger/redhat/testdata/glob-paths/var/lib/rpm/rpmdb.sqlite similarity index 100% rename from syft/pkg/cataloger/redhat/test-fixtures/glob-paths/var/lib/rpm/rpmdb.sqlite rename to syft/pkg/cataloger/redhat/testdata/glob-paths/var/lib/rpm/rpmdb.sqlite diff --git a/syft/pkg/cataloger/redhat/test-fixtures/glob-paths/var/lib/rpmmanifest/container-manifest-2 b/syft/pkg/cataloger/redhat/testdata/glob-paths/var/lib/rpmmanifest/container-manifest-2 similarity index 100% rename from syft/pkg/cataloger/redhat/test-fixtures/glob-paths/var/lib/rpmmanifest/container-manifest-2 rename to syft/pkg/cataloger/redhat/testdata/glob-paths/var/lib/rpmmanifest/container-manifest-2 diff --git a/syft/pkg/cataloger/redhat/test-fixtures/image-minimal/Dockerfile b/syft/pkg/cataloger/redhat/testdata/image-minimal/Dockerfile similarity index 100% rename from syft/pkg/cataloger/redhat/test-fixtures/image-minimal/Dockerfile rename to syft/pkg/cataloger/redhat/testdata/image-minimal/Dockerfile diff --git a/syft/pkg/cataloger/redhat/test-fixtures/image-minimal/remove.sh b/syft/pkg/cataloger/redhat/testdata/image-minimal/remove.sh similarity index 100% rename from syft/pkg/cataloger/redhat/test-fixtures/image-minimal/remove.sh rename to syft/pkg/cataloger/redhat/testdata/image-minimal/remove.sh diff --git a/syft/pkg/cataloger/redhat/test-fixtures/image-rpm-archive/Dockerfile b/syft/pkg/cataloger/redhat/testdata/image-rpm-archive/Dockerfile similarity index 100% rename from syft/pkg/cataloger/redhat/test-fixtures/image-rpm-archive/Dockerfile rename to syft/pkg/cataloger/redhat/testdata/image-rpm-archive/Dockerfile diff --git a/syft/pkg/cataloger/ruby/cataloger_test.go b/syft/pkg/cataloger/ruby/cataloger_test.go index 92a364ae7..e05a0ad3b 100644 --- a/syft/pkg/cataloger/ruby/cataloger_test.go +++ b/syft/pkg/cataloger/ruby/cataloger_test.go @@ -14,7 +14,7 @@ func Test_GemFileLock_Globs(t *testing.T) { }{ { name: "obtain gemfile lock files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "src/Gemfile.lock", "src/Gemfile.next.lock", @@ -40,7 +40,7 @@ func Test_GemSpec_Globs(t *testing.T) { }{ { name: "obtain gemspec files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "specifications/root.gemspec", "specifications/pkg/nested.gemspec", diff --git a/syft/pkg/cataloger/ruby/parse_gemfile_lock_test.go b/syft/pkg/cataloger/ruby/parse_gemfile_lock_test.go index ad94283aa..1b210ff32 100644 --- a/syft/pkg/cataloger/ruby/parse_gemfile_lock_test.go +++ b/syft/pkg/cataloger/ruby/parse_gemfile_lock_test.go @@ -9,7 +9,7 @@ import ( ) func TestParseGemfileLockEntries(t *testing.T) { - fixture := "test-fixtures/Gemfile.lock" + fixture := "testdata/Gemfile.lock" locations := file.NewLocationSet(file.NewLocation(fixture)) var expectedPkgs = []pkg.Package{ {Name: "actionmailer", Version: "4.1.1", PURL: "pkg:gem/actionmailer@4.1.1", Locations: locations, Language: pkg.Ruby, Type: pkg.GemPkg}, diff --git a/syft/pkg/cataloger/ruby/parse_gemspec_test.go b/syft/pkg/cataloger/ruby/parse_gemspec_test.go index b0b9fd56a..8ed52b834 100644 --- a/syft/pkg/cataloger/ruby/parse_gemspec_test.go +++ b/syft/pkg/cataloger/ruby/parse_gemspec_test.go @@ -10,7 +10,7 @@ import ( ) func TestParseGemspec(t *testing.T) { - fixture := "test-fixtures/bundler.gemspec" + fixture := "testdata/bundler.gemspec" ctx := context.TODO() locations := file.NewLocationSet(file.NewLocation(fixture)) diff --git a/syft/pkg/cataloger/ruby/test-fixtures/Gemfile.lock b/syft/pkg/cataloger/ruby/testdata/Gemfile.lock similarity index 100% rename from syft/pkg/cataloger/ruby/test-fixtures/Gemfile.lock rename to syft/pkg/cataloger/ruby/testdata/Gemfile.lock diff --git a/syft/pkg/cataloger/ruby/test-fixtures/bundler.gemspec b/syft/pkg/cataloger/ruby/testdata/bundler.gemspec similarity index 100% rename from syft/pkg/cataloger/ruby/test-fixtures/bundler.gemspec rename to syft/pkg/cataloger/ruby/testdata/bundler.gemspec diff --git a/syft/pkg/cataloger/ruby/test-fixtures/glob-paths/specifications/pkg/nested.gemspec b/syft/pkg/cataloger/ruby/testdata/glob-paths/specifications/pkg/nested.gemspec similarity index 100% rename from syft/pkg/cataloger/ruby/test-fixtures/glob-paths/specifications/pkg/nested.gemspec rename to syft/pkg/cataloger/ruby/testdata/glob-paths/specifications/pkg/nested.gemspec diff --git a/syft/pkg/cataloger/ruby/test-fixtures/glob-paths/specifications/root.gemspec b/syft/pkg/cataloger/ruby/testdata/glob-paths/specifications/root.gemspec similarity index 100% rename from syft/pkg/cataloger/ruby/test-fixtures/glob-paths/specifications/root.gemspec rename to syft/pkg/cataloger/ruby/testdata/glob-paths/specifications/root.gemspec diff --git a/syft/pkg/cataloger/ruby/test-fixtures/glob-paths/src/Gemfile.lock b/syft/pkg/cataloger/ruby/testdata/glob-paths/src/Gemfile.lock similarity index 100% rename from syft/pkg/cataloger/ruby/test-fixtures/glob-paths/src/Gemfile.lock rename to syft/pkg/cataloger/ruby/testdata/glob-paths/src/Gemfile.lock diff --git a/syft/pkg/cataloger/ruby/test-fixtures/glob-paths/src/Gemfile.next.lock b/syft/pkg/cataloger/ruby/testdata/glob-paths/src/Gemfile.next.lock similarity index 100% rename from syft/pkg/cataloger/ruby/test-fixtures/glob-paths/src/Gemfile.next.lock rename to syft/pkg/cataloger/ruby/testdata/glob-paths/src/Gemfile.next.lock diff --git a/syft/pkg/cataloger/rust/cataloger_test.go b/syft/pkg/cataloger/rust/cataloger_test.go index c933d2fc7..3428c3bf4 100644 --- a/syft/pkg/cataloger/rust/cataloger_test.go +++ b/syft/pkg/cataloger/rust/cataloger_test.go @@ -268,7 +268,7 @@ func Test_CargoLockCataloger_Globs(t *testing.T) { }{ { name: "obtain Cargo.lock files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "src/Cargo.lock", }, @@ -293,7 +293,7 @@ func Test_AuditBinaryCataloger_Globs(t *testing.T) { }{ { name: "obtain audit binary files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "partial-binary", }, @@ -312,7 +312,7 @@ func Test_AuditBinaryCataloger_Globs(t *testing.T) { func Test_corruptAuditBinary(t *testing.T) { pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/glob-paths/partial-binary"). + FromFile(t, "testdata/glob-paths/partial-binary"). WithError(). TestParser(t, parseAuditBinary) } diff --git a/syft/pkg/cataloger/rust/parse_cargo_lock_test.go b/syft/pkg/cataloger/rust/parse_cargo_lock_test.go index 15313f55a..aa13b3755 100644 --- a/syft/pkg/cataloger/rust/parse_cargo_lock_test.go +++ b/syft/pkg/cataloger/rust/parse_cargo_lock_test.go @@ -12,7 +12,7 @@ import ( ) func TestParseCargoLock(t *testing.T) { - fixture := "test-fixtures/Cargo.lock" + fixture := "testdata/Cargo.lock" locations := file.NewLocationSet(file.NewLocation(fixture)) ansiTerm := pkg.Package{ Name: "ansi_term", @@ -326,7 +326,7 @@ func TestParseCargoLock(t *testing.T) { } func TestCargoLockWithGitDependencies(t *testing.T) { - fixture := "test-fixtures/Cargo.lock-with-git-deps" + fixture := "testdata/Cargo.lock-with-git-deps" locations := file.NewLocationSet(file.NewLocation(fixture)) ahoCorasick := pkg.Package{ @@ -834,7 +834,7 @@ func TestCargoLockDependencySpecification(t *testing.T) { func Test_corruptCargoLock(t *testing.T) { pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/glob-paths/src/Cargo.lock"). + FromFile(t, "testdata/glob-paths/src/Cargo.lock"). WithError(). TestParser(t, parseCargoLock) } diff --git a/syft/pkg/cataloger/rust/test-fixtures/Cargo.lock b/syft/pkg/cataloger/rust/testdata/Cargo.lock similarity index 100% rename from syft/pkg/cataloger/rust/test-fixtures/Cargo.lock rename to syft/pkg/cataloger/rust/testdata/Cargo.lock diff --git a/syft/pkg/cataloger/rust/test-fixtures/Cargo.lock-with-git-deps b/syft/pkg/cataloger/rust/testdata/Cargo.lock-with-git-deps similarity index 100% rename from syft/pkg/cataloger/rust/test-fixtures/Cargo.lock-with-git-deps rename to syft/pkg/cataloger/rust/testdata/Cargo.lock-with-git-deps diff --git a/syft/pkg/cataloger/rust/test-fixtures/glob-paths/partial-binary b/syft/pkg/cataloger/rust/testdata/glob-paths/partial-binary similarity index 100% rename from syft/pkg/cataloger/rust/test-fixtures/glob-paths/partial-binary rename to syft/pkg/cataloger/rust/testdata/glob-paths/partial-binary diff --git a/syft/pkg/cataloger/rust/test-fixtures/glob-paths/src/Cargo.lock b/syft/pkg/cataloger/rust/testdata/glob-paths/src/Cargo.lock similarity index 100% rename from syft/pkg/cataloger/rust/test-fixtures/glob-paths/src/Cargo.lock rename to syft/pkg/cataloger/rust/testdata/glob-paths/src/Cargo.lock diff --git a/syft/pkg/cataloger/rust/test-fixtures/image-audit/Cargo.lock b/syft/pkg/cataloger/rust/testdata/image-audit/Cargo.lock similarity index 100% rename from syft/pkg/cataloger/rust/test-fixtures/image-audit/Cargo.lock rename to syft/pkg/cataloger/rust/testdata/image-audit/Cargo.lock diff --git a/syft/pkg/cataloger/rust/test-fixtures/image-audit/Cargo.toml b/syft/pkg/cataloger/rust/testdata/image-audit/Cargo.toml similarity index 100% rename from syft/pkg/cataloger/rust/test-fixtures/image-audit/Cargo.toml rename to syft/pkg/cataloger/rust/testdata/image-audit/Cargo.toml diff --git a/syft/pkg/cataloger/rust/test-fixtures/image-audit/Dockerfile b/syft/pkg/cataloger/rust/testdata/image-audit/Dockerfile similarity index 100% rename from syft/pkg/cataloger/rust/test-fixtures/image-audit/Dockerfile rename to syft/pkg/cataloger/rust/testdata/image-audit/Dockerfile diff --git a/syft/pkg/cataloger/rust/test-fixtures/image-audit/src/main.rs b/syft/pkg/cataloger/rust/testdata/image-audit/src/main.rs similarity index 100% rename from syft/pkg/cataloger/rust/test-fixtures/image-audit/src/main.rs rename to syft/pkg/cataloger/rust/testdata/image-audit/src/main.rs diff --git a/syft/pkg/cataloger/sbom/cataloger_test.go b/syft/pkg/cataloger/sbom/cataloger_test.go index 68a6bc35c..7617e9e9b 100644 --- a/syft/pkg/cataloger/sbom/cataloger_test.go +++ b/syft/pkg/cataloger/sbom/cataloger_test.go @@ -402,7 +402,7 @@ func Test_parseSBOM(t *testing.T) { }{ { name: "parse syft JSON", - fixture: "test-fixtures/alpine/syft-json", + fixture: "testdata/alpine/syft-json", wantPkgs: expectedPkgs, wantRelationships: expectedRelationships, }, @@ -426,7 +426,7 @@ func Test_Cataloger_Globs(t *testing.T) { }{ { name: "obtain sbom files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "bom", "sbom", @@ -455,7 +455,7 @@ func Test_Cataloger_Globs(t *testing.T) { func Test_corruptSBOM(t *testing.T) { pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/glob-paths/app.spdx.json"). + FromFile(t, "testdata/glob-paths/app.spdx.json"). WithError(). TestParser(t, parseSBOM) } diff --git a/syft/pkg/cataloger/sbom/test-fixtures/alpine/syft-json/sbom.syft.json b/syft/pkg/cataloger/sbom/testdata/alpine/syft-json/sbom.syft.json similarity index 100% rename from syft/pkg/cataloger/sbom/test-fixtures/alpine/syft-json/sbom.syft.json rename to syft/pkg/cataloger/sbom/testdata/alpine/syft-json/sbom.syft.json diff --git a/syft/pkg/cataloger/sbom/test-fixtures/glob-paths/app.bom b/syft/pkg/cataloger/sbom/testdata/glob-paths/app.bom similarity index 100% rename from syft/pkg/cataloger/sbom/test-fixtures/glob-paths/app.bom rename to syft/pkg/cataloger/sbom/testdata/glob-paths/app.bom diff --git a/syft/pkg/cataloger/sbom/test-fixtures/glob-paths/app.bom.json b/syft/pkg/cataloger/sbom/testdata/glob-paths/app.bom.json similarity index 100% rename from syft/pkg/cataloger/sbom/test-fixtures/glob-paths/app.bom.json rename to syft/pkg/cataloger/sbom/testdata/glob-paths/app.bom.json diff --git a/syft/pkg/cataloger/sbom/test-fixtures/glob-paths/app.cdx b/syft/pkg/cataloger/sbom/testdata/glob-paths/app.cdx similarity index 100% rename from syft/pkg/cataloger/sbom/test-fixtures/glob-paths/app.cdx rename to syft/pkg/cataloger/sbom/testdata/glob-paths/app.cdx diff --git a/syft/pkg/cataloger/sbom/test-fixtures/glob-paths/app.cdx.json b/syft/pkg/cataloger/sbom/testdata/glob-paths/app.cdx.json similarity index 100% rename from syft/pkg/cataloger/sbom/test-fixtures/glob-paths/app.cdx.json rename to syft/pkg/cataloger/sbom/testdata/glob-paths/app.cdx.json diff --git a/syft/pkg/cataloger/sbom/test-fixtures/glob-paths/app.sbom b/syft/pkg/cataloger/sbom/testdata/glob-paths/app.sbom similarity index 100% rename from syft/pkg/cataloger/sbom/test-fixtures/glob-paths/app.sbom rename to syft/pkg/cataloger/sbom/testdata/glob-paths/app.sbom diff --git a/syft/pkg/cataloger/sbom/test-fixtures/glob-paths/app.sbom.json b/syft/pkg/cataloger/sbom/testdata/glob-paths/app.sbom.json similarity index 100% rename from syft/pkg/cataloger/sbom/test-fixtures/glob-paths/app.sbom.json rename to syft/pkg/cataloger/sbom/testdata/glob-paths/app.sbom.json diff --git a/syft/pkg/cataloger/sbom/test-fixtures/glob-paths/app.spdx b/syft/pkg/cataloger/sbom/testdata/glob-paths/app.spdx similarity index 100% rename from syft/pkg/cataloger/sbom/test-fixtures/glob-paths/app.spdx rename to syft/pkg/cataloger/sbom/testdata/glob-paths/app.spdx diff --git a/syft/pkg/cataloger/sbom/test-fixtures/glob-paths/app.spdx.json b/syft/pkg/cataloger/sbom/testdata/glob-paths/app.spdx.json similarity index 100% rename from syft/pkg/cataloger/sbom/test-fixtures/glob-paths/app.spdx.json rename to syft/pkg/cataloger/sbom/testdata/glob-paths/app.spdx.json diff --git a/syft/pkg/cataloger/sbom/test-fixtures/glob-paths/app.syft.json b/syft/pkg/cataloger/sbom/testdata/glob-paths/app.syft.json similarity index 100% rename from syft/pkg/cataloger/sbom/test-fixtures/glob-paths/app.syft.json rename to syft/pkg/cataloger/sbom/testdata/glob-paths/app.syft.json diff --git a/syft/pkg/cataloger/sbom/test-fixtures/glob-paths/bom b/syft/pkg/cataloger/sbom/testdata/glob-paths/bom similarity index 100% rename from syft/pkg/cataloger/sbom/test-fixtures/glob-paths/bom rename to syft/pkg/cataloger/sbom/testdata/glob-paths/bom diff --git a/syft/pkg/cataloger/sbom/test-fixtures/glob-paths/sbom b/syft/pkg/cataloger/sbom/testdata/glob-paths/sbom similarity index 100% rename from syft/pkg/cataloger/sbom/test-fixtures/glob-paths/sbom rename to syft/pkg/cataloger/sbom/testdata/glob-paths/sbom diff --git a/syft/pkg/cataloger/snap/cataloger_test.go b/syft/pkg/cataloger/snap/cataloger_test.go index 56ba63359..0d6ab0d2d 100644 --- a/syft/pkg/cataloger/snap/cataloger_test.go +++ b/syft/pkg/cataloger/snap/cataloger_test.go @@ -13,11 +13,11 @@ func TestCataloger_Globs(t *testing.T) { }{ { name: "base snap with dpkg.yaml", - fixture: "test-fixtures/glob-paths/base", + fixture: "testdata/glob-paths/base", }, { name: "system snap with manifest.yaml", - fixture: "test-fixtures/glob-paths/system", + fixture: "testdata/glob-paths/system", }, } diff --git a/syft/pkg/cataloger/snap/integration_test.go b/syft/pkg/cataloger/snap/integration_test.go index 128aad402..92e575b07 100644 --- a/syft/pkg/cataloger/snap/integration_test.go +++ b/syft/pkg/cataloger/snap/integration_test.go @@ -14,7 +14,7 @@ import ( ) func TestRealDpkgYamlParsing(t *testing.T) { - fixture := "test-fixtures/real-dpkg.yaml" + fixture := "testdata/real-dpkg.yaml" // Open the file f, err := os.Open(fixture) diff --git a/syft/pkg/cataloger/snap/parse_base_dpkg_test.go b/syft/pkg/cataloger/snap/parse_base_dpkg_test.go index b9e4c7ab6..4e58931c1 100644 --- a/syft/pkg/cataloger/snap/parse_base_dpkg_test.go +++ b/syft/pkg/cataloger/snap/parse_base_dpkg_test.go @@ -9,7 +9,7 @@ import ( ) func TestParseBaseDpkgYaml(t *testing.T) { - fixture := "test-fixtures/dpkg.yaml" + fixture := "testdata/dpkg.yaml" locations := file.NewLocationSet(file.NewLocation(fixture)) expected := []pkg.Package{ diff --git a/syft/pkg/cataloger/snap/parse_integration_test.go b/syft/pkg/cataloger/snap/parse_integration_test.go index 76f66b86f..c0d6217a2 100644 --- a/syft/pkg/cataloger/snap/parse_integration_test.go +++ b/syft/pkg/cataloger/snap/parse_integration_test.go @@ -9,7 +9,7 @@ import ( ) func TestParseSystemManifest(t *testing.T) { - fixture := "test-fixtures/manifest.yaml" + fixture := "testdata/manifest.yaml" locations := file.NewLocationSet(file.NewLocation(fixture)) expected := []pkg.Package{ diff --git a/syft/pkg/cataloger/snap/parse_kernel_changelog_test.go b/syft/pkg/cataloger/snap/parse_kernel_changelog_test.go index 3f564234a..df0c15767 100644 --- a/syft/pkg/cataloger/snap/parse_kernel_changelog_test.go +++ b/syft/pkg/cataloger/snap/parse_kernel_changelog_test.go @@ -29,7 +29,7 @@ func gzipContent(t *testing.T, content string) []byte { func locationReadCloser(t *testing.T, data []byte) file.LocationReadCloser { t.Helper() return file.LocationReadCloser{ - Location: file.NewLocation("test-fixtures/changelog.Debian.gz"), + Location: file.NewLocation("testdata/changelog.Debian.gz"), ReadCloser: io.NopCloser(bytes.NewReader(data)), } } @@ -106,7 +106,7 @@ func TestExtractKernelVersion(t *testing.T) { } func TestCreateMainKernelPackage(t *testing.T) { - location := file.NewLocation("test-fixtures/changelog.Debian.gz") + location := file.NewLocation("testdata/changelog.Debian.gz") versionInfo := &kernelVersionInfo{ baseVersion: "5.4.0-195", releaseVersion: "215", @@ -131,7 +131,7 @@ func TestCreateMainKernelPackage(t *testing.T) { } func TestParseBaseKernelLine(t *testing.T) { - location := file.NewLocation("test-fixtures/changelog.Debian.gz") + location := file.NewLocation("testdata/changelog.Debian.gz") snapMetadata := pkg.SnapEntry{ SnapType: pkg.SnapTypeKernel, } diff --git a/syft/pkg/cataloger/snap/test-fixtures/dpkg.yaml b/syft/pkg/cataloger/snap/testdata/dpkg.yaml similarity index 100% rename from syft/pkg/cataloger/snap/test-fixtures/dpkg.yaml rename to syft/pkg/cataloger/snap/testdata/dpkg.yaml diff --git a/syft/pkg/cataloger/snap/test-fixtures/glob-paths/base/usr/share/snappy/dpkg.yaml b/syft/pkg/cataloger/snap/testdata/glob-paths/base/usr/share/snappy/dpkg.yaml similarity index 100% rename from syft/pkg/cataloger/snap/test-fixtures/glob-paths/base/usr/share/snappy/dpkg.yaml rename to syft/pkg/cataloger/snap/testdata/glob-paths/base/usr/share/snappy/dpkg.yaml diff --git a/syft/pkg/cataloger/snap/test-fixtures/glob-paths/system/snap/manifest.yaml b/syft/pkg/cataloger/snap/testdata/glob-paths/system/snap/manifest.yaml similarity index 100% rename from syft/pkg/cataloger/snap/test-fixtures/glob-paths/system/snap/manifest.yaml rename to syft/pkg/cataloger/snap/testdata/glob-paths/system/snap/manifest.yaml diff --git a/syft/pkg/cataloger/snap/test-fixtures/manifest.yaml b/syft/pkg/cataloger/snap/testdata/manifest.yaml similarity index 100% rename from syft/pkg/cataloger/snap/test-fixtures/manifest.yaml rename to syft/pkg/cataloger/snap/testdata/manifest.yaml diff --git a/syft/pkg/cataloger/snap/test-fixtures/real-dpkg.yaml b/syft/pkg/cataloger/snap/testdata/real-dpkg.yaml similarity index 100% rename from syft/pkg/cataloger/snap/test-fixtures/real-dpkg.yaml rename to syft/pkg/cataloger/snap/testdata/real-dpkg.yaml diff --git a/syft/pkg/cataloger/swift/cataloger_test.go b/syft/pkg/cataloger/swift/cataloger_test.go index 8100ce8b1..62c6cfa19 100644 --- a/syft/pkg/cataloger/swift/cataloger_test.go +++ b/syft/pkg/cataloger/swift/cataloger_test.go @@ -14,7 +14,7 @@ func Test_Cataloger_Globs(t *testing.T) { }{ { name: "obtain swift files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "src/Podfile.lock", }, diff --git a/syft/pkg/cataloger/swift/parse_package_resolved_test.go b/syft/pkg/cataloger/swift/parse_package_resolved_test.go index bf16d7542..cd2565924 100644 --- a/syft/pkg/cataloger/swift/parse_package_resolved_test.go +++ b/syft/pkg/cataloger/swift/parse_package_resolved_test.go @@ -14,7 +14,7 @@ import ( ) func TestParsePackageResolved(t *testing.T) { - fixture := "test-fixtures/Package.resolved" + fixture := "testdata/Package.resolved" locations := file.NewLocationSet(file.NewLocation(fixture)) expectedPkgs := []pkg.Package{ { @@ -81,7 +81,7 @@ func TestParsePackageResolved(t *testing.T) { } func TestParsePackageResolvedV3(t *testing.T) { - fixture := "test-fixtures/PackageV3.resolved" + fixture := "testdata/PackageV3.resolved" locations := file.NewLocationSet(file.NewLocation(fixture)) expectedPkgs := []pkg.Package{ { @@ -116,7 +116,7 @@ func TestParsePackageResolvedV3(t *testing.T) { func TestParsePackageResolved_empty(t *testing.T) { // regression for https://github.com/anchore/syft/issues/2225 - fixture := "test-fixtures/empty-packages.resolved" + fixture := "testdata/empty-packages.resolved" pkgtest.TestFileParser(t, fixture, parsePackageResolved, nil, nil) @@ -130,14 +130,14 @@ func TestParsePackageResolved_empty(t *testing.T) { func TestParsePackageResolved_versionNotANumber(t *testing.T) { // regression for https://github.com/anchore/syft/issues/2225 - fixture := "test-fixtures/bad-version-packages.resolved" + fixture := "testdata/bad-version-packages.resolved" pkgtest.NewCatalogTester().FromFile(t, fixture).WithError().TestParser(t, parsePackageResolved) } func Test_corruptPackageResolved(t *testing.T) { pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/bad-version-packages.resolved"). + FromFile(t, "testdata/bad-version-packages.resolved"). WithError(). TestParser(t, parsePackageResolved) } diff --git a/syft/pkg/cataloger/swift/parse_podfile_lock_test.go b/syft/pkg/cataloger/swift/parse_podfile_lock_test.go index c76b92255..7769d85c5 100644 --- a/syft/pkg/cataloger/swift/parse_podfile_lock_test.go +++ b/syft/pkg/cataloger/swift/parse_podfile_lock_test.go @@ -10,7 +10,7 @@ import ( ) func TestParsePodfileLock(t *testing.T) { - fixture := "test-fixtures/Podfile.lock" + fixture := "testdata/Podfile.lock" locations := file.NewLocationSet(file.NewLocation(fixture)) expectedPkgs := []pkg.Package{ { @@ -276,7 +276,7 @@ func TestParsePodfileLock(t *testing.T) { func Test_corruptPodfile(t *testing.T) { pkgtest.NewCatalogTester(). - FromFile(t, "test-fixtures/glob-paths/src/Podfile.lock"). + FromFile(t, "testdata/glob-paths/src/Podfile.lock"). WithError(). TestParser(t, parsePodfileLock) } diff --git a/syft/pkg/cataloger/swift/test-fixtures/Package.resolved b/syft/pkg/cataloger/swift/testdata/Package.resolved similarity index 100% rename from syft/pkg/cataloger/swift/test-fixtures/Package.resolved rename to syft/pkg/cataloger/swift/testdata/Package.resolved diff --git a/syft/pkg/cataloger/swift/test-fixtures/PackageV3.resolved b/syft/pkg/cataloger/swift/testdata/PackageV3.resolved similarity index 100% rename from syft/pkg/cataloger/swift/test-fixtures/PackageV3.resolved rename to syft/pkg/cataloger/swift/testdata/PackageV3.resolved diff --git a/syft/pkg/cataloger/swift/test-fixtures/Podfile.lock b/syft/pkg/cataloger/swift/testdata/Podfile.lock similarity index 100% rename from syft/pkg/cataloger/swift/test-fixtures/Podfile.lock rename to syft/pkg/cataloger/swift/testdata/Podfile.lock diff --git a/syft/pkg/cataloger/swift/test-fixtures/bad-version-packages.resolved b/syft/pkg/cataloger/swift/testdata/bad-version-packages.resolved similarity index 100% rename from syft/pkg/cataloger/swift/test-fixtures/bad-version-packages.resolved rename to syft/pkg/cataloger/swift/testdata/bad-version-packages.resolved diff --git a/syft/pkg/cataloger/swift/test-fixtures/empty-packages.resolved b/syft/pkg/cataloger/swift/testdata/empty-packages.resolved similarity index 100% rename from syft/pkg/cataloger/swift/test-fixtures/empty-packages.resolved rename to syft/pkg/cataloger/swift/testdata/empty-packages.resolved diff --git a/syft/pkg/cataloger/swift/test-fixtures/glob-paths/src/Podfile.lock b/syft/pkg/cataloger/swift/testdata/glob-paths/src/Podfile.lock similarity index 100% rename from syft/pkg/cataloger/swift/test-fixtures/glob-paths/src/Podfile.lock rename to syft/pkg/cataloger/swift/testdata/glob-paths/src/Podfile.lock diff --git a/syft/pkg/cataloger/swipl/cataloger_test.go b/syft/pkg/cataloger/swipl/cataloger_test.go index dbe53b4f0..0ed16dc3e 100644 --- a/syft/pkg/cataloger/swipl/cataloger_test.go +++ b/syft/pkg/cataloger/swipl/cataloger_test.go @@ -14,7 +14,7 @@ func Test_Cataloger_Globs(t *testing.T) { }{ { name: "obtain swipl pack files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "pack.pl", }, diff --git a/syft/pkg/cataloger/swipl/parse_pack_test.go b/syft/pkg/cataloger/swipl/parse_pack_test.go index 28feb7690..4b903eadc 100644 --- a/syft/pkg/cataloger/swipl/parse_pack_test.go +++ b/syft/pkg/cataloger/swipl/parse_pack_test.go @@ -10,7 +10,7 @@ import ( ) func TestParsePackPackage(t *testing.T) { - fixture := "test-fixtures/pack.pl" + fixture := "testdata/pack.pl" locations := file.NewLocationSet(file.NewLocation(fixture)) expectedPkgs := []pkg.Package{ { diff --git a/syft/pkg/cataloger/swipl/test-fixtures/glob-paths/pack.pl b/syft/pkg/cataloger/swipl/testdata/glob-paths/pack.pl similarity index 100% rename from syft/pkg/cataloger/swipl/test-fixtures/glob-paths/pack.pl rename to syft/pkg/cataloger/swipl/testdata/glob-paths/pack.pl diff --git a/syft/pkg/cataloger/swipl/test-fixtures/pack.pl b/syft/pkg/cataloger/swipl/testdata/pack.pl similarity index 100% rename from syft/pkg/cataloger/swipl/test-fixtures/pack.pl rename to syft/pkg/cataloger/swipl/testdata/pack.pl diff --git a/syft/pkg/cataloger/terraform/cataloger_test.go b/syft/pkg/cataloger/terraform/cataloger_test.go index 618f069f6..b7ba9e674 100644 --- a/syft/pkg/cataloger/terraform/cataloger_test.go +++ b/syft/pkg/cataloger/terraform/cataloger_test.go @@ -95,7 +95,7 @@ func TestTerraformCataloger(t *testing.T) { for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { pkgtest.NewCatalogTester(). - WithResolver(fileresolver.NewFromUnindexedDirectory(filepath.Join("test-fixtures", tt.name))). + WithResolver(fileresolver.NewFromUnindexedDirectory(filepath.Join("testdata", tt.name))). Expects(tt.expected, nil). TestCataloger(t, c) }) diff --git a/syft/pkg/cataloger/terraform/test-fixtures/two-providers/.terraform.lock.hcl b/syft/pkg/cataloger/terraform/testdata/two-providers/.terraform.lock.hcl similarity index 100% rename from syft/pkg/cataloger/terraform/test-fixtures/two-providers/.terraform.lock.hcl rename to syft/pkg/cataloger/terraform/testdata/two-providers/.terraform.lock.hcl diff --git a/syft/pkg/cataloger/wordpress/cataloger_test.go b/syft/pkg/cataloger/wordpress/cataloger_test.go index bbca86d5c..68f7d914f 100644 --- a/syft/pkg/cataloger/wordpress/cataloger_test.go +++ b/syft/pkg/cataloger/wordpress/cataloger_test.go @@ -14,7 +14,7 @@ func Test_WordpressPlugin_Globs(t *testing.T) { }{ { name: "obtain wordpress plugin files", - fixture: "test-fixtures/glob-paths", + fixture: "testdata/glob-paths", expected: []string{ "wp-content/plugins/akismet/akismet.php", "wp-content/plugins/all-in-one-wp-migration/all-in-one-wp-migration.php", diff --git a/syft/pkg/cataloger/wordpress/parse_plugin_test.go b/syft/pkg/cataloger/wordpress/parse_plugin_test.go index 4b95fd91e..640f1d42b 100644 --- a/syft/pkg/cataloger/wordpress/parse_plugin_test.go +++ b/syft/pkg/cataloger/wordpress/parse_plugin_test.go @@ -12,7 +12,7 @@ import ( ) func TestParseWordpressPluginFiles(t *testing.T) { - fixture := "test-fixtures/glob-paths/wp-content/plugins/akismet/akismet.php" + fixture := "testdata/glob-paths/wp-content/plugins/akismet/akismet.php" locations := file.NewLocationSet(file.NewLocation(fixture)) ctx := context.TODO() var expectedPkg = pkg.Package{ diff --git a/syft/pkg/cataloger/wordpress/test-fixtures/glob-paths/wp-admin/index.php b/syft/pkg/cataloger/wordpress/testdata/glob-paths/wp-admin/index.php similarity index 100% rename from syft/pkg/cataloger/wordpress/test-fixtures/glob-paths/wp-admin/index.php rename to syft/pkg/cataloger/wordpress/testdata/glob-paths/wp-admin/index.php diff --git a/syft/pkg/cataloger/wordpress/test-fixtures/glob-paths/wp-content/plugins/akismet/akismet.php b/syft/pkg/cataloger/wordpress/testdata/glob-paths/wp-content/plugins/akismet/akismet.php similarity index 100% rename from syft/pkg/cataloger/wordpress/test-fixtures/glob-paths/wp-content/plugins/akismet/akismet.php rename to syft/pkg/cataloger/wordpress/testdata/glob-paths/wp-content/plugins/akismet/akismet.php diff --git a/syft/pkg/cataloger/wordpress/test-fixtures/glob-paths/wp-content/plugins/all-in-one-wp-migration/all-in-one-wp-migration.php b/syft/pkg/cataloger/wordpress/testdata/glob-paths/wp-content/plugins/all-in-one-wp-migration/all-in-one-wp-migration.php similarity index 100% rename from syft/pkg/cataloger/wordpress/test-fixtures/glob-paths/wp-content/plugins/all-in-one-wp-migration/all-in-one-wp-migration.php rename to syft/pkg/cataloger/wordpress/testdata/glob-paths/wp-content/plugins/all-in-one-wp-migration/all-in-one-wp-migration.php diff --git a/syft/pkg/cataloger/wordpress/test-fixtures/glob-paths/wp-includes/index.php b/syft/pkg/cataloger/wordpress/testdata/glob-paths/wp-includes/index.php similarity index 100% rename from syft/pkg/cataloger/wordpress/test-fixtures/glob-paths/wp-includes/index.php rename to syft/pkg/cataloger/wordpress/testdata/glob-paths/wp-includes/index.php diff --git a/syft/pkg/license_set_test.go b/syft/pkg/license_set_test.go index ea7f81f75..c6e420a3d 100644 --- a/syft/pkg/license_set_test.go +++ b/syft/pkg/license_set_test.go @@ -137,20 +137,20 @@ func TestLicenseSet_Add(t *testing.T) { { name: "licenses that are unknown with different contents can exist in the same set", licenses: []License{ - NewLicenseWithContext(ctx, readFileAsString("../../internal/licenses/test-fixtures/nvidia-software-and-cuda-supplement")), - NewLicenseWithContext(ctx, readFileAsString("../../internal/licenses/test-fixtures/apache-license-2.0")), + NewLicenseWithContext(ctx, readFileAsString("../../internal/licenses/testdata/nvidia-software-and-cuda-supplement")), + NewLicenseWithContext(ctx, readFileAsString("../../internal/licenses/testdata/apache-license-2.0")), }, want: []License{ { SPDXExpression: "Apache-2.0", Value: "Apache-2.0", Type: license.Declared, - Contents: readFileAsString("../../internal/licenses/test-fixtures/apache-license-2.0"), + Contents: readFileAsString("../../internal/licenses/testdata/apache-license-2.0"), Locations: file.NewLocationSet(), }, { Value: "sha256:eebcea3ab1d1a28e671de90119ffcfb35fe86951e4af1b17af52b7a82fcf7d0a", - Contents: readFileAsString("../../internal/licenses/test-fixtures/nvidia-software-and-cuda-supplement"), + Contents: readFileAsString("../../internal/licenses/testdata/nvidia-software-and-cuda-supplement"), Type: license.Declared, }, }, diff --git a/syft/pkg/license_test.go b/syft/pkg/license_test.go index ac3066d31..a348885f9 100644 --- a/syft/pkg/license_test.go +++ b/syft/pkg/license_test.go @@ -90,14 +90,14 @@ func Test_Sort(t *testing.T) { { name: "multiple licenses with only contents are still sorted by their computed lic.value references", licenses: []License{ - NewLicenseWithContext(ctx, readFileAsString("../../internal/licenses/test-fixtures/nvidia-software-and-cuda-supplement")), - NewLicenseWithContext(ctx, readFileAsString("../../internal/licenses/test-fixtures/Knuth-CTAN")), - NewLicenseWithContext(ctx, readFileAsString("../../internal/licenses/test-fixtures/apache-license-2.0")), + NewLicenseWithContext(ctx, readFileAsString("../../internal/licenses/testdata/nvidia-software-and-cuda-supplement")), + NewLicenseWithContext(ctx, readFileAsString("../../internal/licenses/testdata/Knuth-CTAN")), + NewLicenseWithContext(ctx, readFileAsString("../../internal/licenses/testdata/apache-license-2.0")), }, expected: Licenses{ - NewLicenseWithContext(ctx, readFileAsString("../../internal/licenses/test-fixtures/apache-license-2.0")), - NewLicenseWithContext(ctx, readFileAsString("../../internal/licenses/test-fixtures/nvidia-software-and-cuda-supplement")), - NewLicenseWithContext(ctx, readFileAsString("../../internal/licenses/test-fixtures/Knuth-CTAN")), + NewLicenseWithContext(ctx, readFileAsString("../../internal/licenses/testdata/apache-license-2.0")), + NewLicenseWithContext(ctx, readFileAsString("../../internal/licenses/testdata/nvidia-software-and-cuda-supplement")), + NewLicenseWithContext(ctx, readFileAsString("../../internal/licenses/testdata/Knuth-CTAN")), }, }, } diff --git a/syft/source/directorysource/directory_source_test.go b/syft/source/directorysource/directory_source_test.go index fcadfbf86..aac93a88d 100644 --- a/syft/source/directorysource/directory_source_test.go +++ b/syft/source/directorysource/directory_source_test.go @@ -18,7 +18,7 @@ import ( ) func TestNewFromDirectory(t *testing.T) { - testutil.Chdir(t, "..") // run with source/test-fixtures + testutil.Chdir(t, "..") // run with source/testdata testCases := []struct { desc string @@ -36,19 +36,19 @@ func TestNewFromDirectory(t *testing.T) { }, { desc: "path detected", - input: "test-fixtures", + input: "testdata", inputPaths: []string{"path-detected/.vimrc"}, expectedRefs: 1, }, { desc: "directory ignored", - input: "test-fixtures", + input: "testdata", inputPaths: []string{"path-detected"}, expectedRefs: 0, }, { desc: "no files-by-path detected", - input: "test-fixtures", + input: "testdata", inputPaths: []string{"no-path-detected"}, expectedRefs: 0, }, @@ -86,7 +86,7 @@ func TestNewFromDirectory(t *testing.T) { } func Test_DirectorySource_FilesByGlob(t *testing.T) { - testutil.Chdir(t, "..") // run with source/test-fixtures + testutil.Chdir(t, "..") // run with source/testdata testCases := []struct { desc string @@ -95,19 +95,19 @@ func Test_DirectorySource_FilesByGlob(t *testing.T) { expected int }{ { - input: "test-fixtures", + input: "testdata", desc: "no matches", glob: "bar/foo", expected: 0, }, { - input: "test-fixtures/path-detected", + input: "testdata/path-detected", desc: "a single match", glob: "**/*vimrc", expected: 1, }, { - input: "test-fixtures/path-detected", + input: "testdata/path-detected", desc: "multiple matches", glob: "**", expected: 2, @@ -135,7 +135,7 @@ func Test_DirectorySource_FilesByGlob(t *testing.T) { } func Test_DirectorySource_Exclusions(t *testing.T) { - testutil.Chdir(t, "..") // run with source/test-fixtures + testutil.Chdir(t, "..") // run with source/testdata testCases := []struct { desc string @@ -146,14 +146,14 @@ func Test_DirectorySource_Exclusions(t *testing.T) { err bool }{ { - input: "test-fixtures/system_paths", + input: "testdata/system_paths", desc: "exclude everything", glob: "**", expected: nil, exclusions: []string{"**/*"}, }, { - input: "test-fixtures/image-simple", + input: "testdata/image-simple", desc: "a single path excluded", glob: "**", expected: []string{ @@ -164,7 +164,7 @@ func Test_DirectorySource_Exclusions(t *testing.T) { exclusions: []string{"**/target/**"}, }, { - input: "test-fixtures/image-simple", + input: "testdata/image-simple", desc: "exclude explicit directory relative to the root", glob: "**", expected: []string{ @@ -176,7 +176,7 @@ func Test_DirectorySource_Exclusions(t *testing.T) { exclusions: []string{"./target"}, }, { - input: "test-fixtures/image-simple", + input: "testdata/image-simple", desc: "exclude explicit file relative to the root", glob: "**", expected: []string{ @@ -188,7 +188,7 @@ func Test_DirectorySource_Exclusions(t *testing.T) { exclusions: []string{"./file-1.txt"}, }, { - input: "test-fixtures/image-simple", + input: "testdata/image-simple", desc: "exclude wildcard relative to the root", glob: "**", expected: []string{ @@ -200,7 +200,7 @@ func Test_DirectorySource_Exclusions(t *testing.T) { exclusions: []string{"./*.txt"}, }, { - input: "test-fixtures/image-simple", + input: "testdata/image-simple", desc: "exclude files deeper", glob: "**", expected: []string{ @@ -212,7 +212,7 @@ func Test_DirectorySource_Exclusions(t *testing.T) { exclusions: []string{"**/really/**"}, }, { - input: "test-fixtures/image-simple", + input: "testdata/image-simple", desc: "files excluded with extension", glob: "**", expected: []string{ @@ -224,7 +224,7 @@ func Test_DirectorySource_Exclusions(t *testing.T) { exclusions: []string{"**/*.txt"}, }, { - input: "test-fixtures/image-simple", + input: "testdata/image-simple", desc: "keep files with different extensions", glob: "**", expected: []string{ @@ -236,7 +236,7 @@ func Test_DirectorySource_Exclusions(t *testing.T) { exclusions: []string{"**/target/**/*.jar"}, }, { - input: "test-fixtures/path-detected", + input: "testdata/path-detected", desc: "file directly excluded", glob: "**", expected: []string{ @@ -245,7 +245,7 @@ func Test_DirectorySource_Exclusions(t *testing.T) { exclusions: []string{"**/empty"}, }, { - input: "test-fixtures/path-detected", + input: "testdata/path-detected", desc: "pattern error containing **/", glob: "**", expected: []string{ @@ -255,7 +255,7 @@ func Test_DirectorySource_Exclusions(t *testing.T) { err: true, }, { - input: "test-fixtures/path-detected", + input: "testdata/path-detected", desc: "pattern error incorrect start", glob: "**", expected: []string{ @@ -265,7 +265,7 @@ func Test_DirectorySource_Exclusions(t *testing.T) { err: true, }, { - input: "test-fixtures/path-detected", + input: "testdata/path-detected", desc: "pattern error starting with /", glob: "**", expected: []string{ @@ -408,7 +408,7 @@ func Test_getDirectoryExclusionFunctions_crossPlatform(t *testing.T) { } func Test_DirectorySource_FilesByPathDoesNotExist(t *testing.T) { - testutil.Chdir(t, "..") // run with source/test-fixtures + testutil.Chdir(t, "..") // run with source/testdata testCases := []struct { desc string @@ -417,7 +417,7 @@ func Test_DirectorySource_FilesByPathDoesNotExist(t *testing.T) { expected string }{ { - input: "test-fixtures/path-detected", + input: "testdata/path-detected", desc: "path does not exist", path: "foo", }, @@ -442,7 +442,7 @@ func Test_DirectorySource_FilesByPathDoesNotExist(t *testing.T) { } func Test_DirectorySource_ID(t *testing.T) { - testutil.Chdir(t, "..") // run with source/test-fixtures + testutil.Chdir(t, "..") // run with source/testdata tests := []struct { name string @@ -458,26 +458,26 @@ func Test_DirectorySource_ID(t *testing.T) { { name: "to a non-existent directory", cfg: Config{ - Path: "./test-fixtures/does-not-exist", + Path: "./testdata/does-not-exist", }, wantErr: require.Error, }, { name: "with odd unclean path through non-existent directory", - cfg: Config{Path: "test-fixtures/does-not-exist/../"}, + cfg: Config{Path: "testdata/does-not-exist/../"}, wantErr: require.Error, }, { name: "to a file (not a directory)", cfg: Config{ - Path: "./test-fixtures/image-simple/Dockerfile", + Path: "./testdata/image-simple/Dockerfile", }, wantErr: require.Error, }, { name: "to dir with name and version and supplier", cfg: Config{ - Path: "./test-fixtures", + Path: "./testdata", Alias: source.Alias{ Name: "name-me-that!", Version: "version-me-this!", @@ -489,7 +489,7 @@ func Test_DirectorySource_ID(t *testing.T) { { name: "to different dir with name and version", cfg: Config{ - Path: "./test-fixtures/image-simple", + Path: "./testdata/image-simple", Alias: source.Alias{ Name: "name-me-that!", Version: "version-me-this!", @@ -501,24 +501,24 @@ func Test_DirectorySource_ID(t *testing.T) { }, { name: "with path", - cfg: Config{Path: "./test-fixtures"}, - want: artifact.ID("c2f936b0054dc6114fc02a3446bf8916bde8fdf87166a23aee22ea011b443522"), + cfg: Config{Path: "./testdata"}, + want: artifact.ID("810ff2fb242a5dee4220f2cb0e6a519891fb67f2f828a6cab4ef8894633b1f50"), }, { name: "with unclean path", - cfg: Config{Path: "test-fixtures/image-simple/../"}, - want: artifact.ID("c2f936b0054dc6114fc02a3446bf8916bde8fdf87166a23aee22ea011b443522"), + cfg: Config{Path: "testdata/image-simple/../"}, + want: artifact.ID("810ff2fb242a5dee4220f2cb0e6a519891fb67f2f828a6cab4ef8894633b1f50"), }, { name: "other fields do not affect ID", cfg: Config{ - Path: "test-fixtures", + Path: "testdata", Base: "a-base!", Exclude: source.ExcludeConfig{ Paths: []string{"a", "b"}, }, }, - want: artifact.ID("c2f936b0054dc6114fc02a3446bf8916bde8fdf87166a23aee22ea011b443522"), + want: artifact.ID("810ff2fb242a5dee4220f2cb0e6a519891fb67f2f828a6cab4ef8894633b1f50"), }, } for _, tt := range tests { @@ -537,9 +537,9 @@ func Test_DirectorySource_ID(t *testing.T) { } func Test_cleanDirPath(t *testing.T) { - testutil.Chdir(t, "..") // run with source/test-fixtures + testutil.Chdir(t, "..") // run with source/testdata - abs, err := filepath.Abs("test-fixtures") + abs, err := filepath.Abs("testdata") require.NoError(t, err) tests := []struct { diff --git a/syft/source/filesource/file_source_test.go b/syft/source/filesource/file_source_test.go index ff5bc824a..87fe2a795 100644 --- a/syft/source/filesource/file_source_test.go +++ b/syft/source/filesource/file_source_test.go @@ -19,7 +19,7 @@ import ( ) func TestNewFromFile(t *testing.T) { - testutil.Chdir(t, "..") // run with source/test-fixtures + testutil.Chdir(t, "..") // run with source/testdata testCases := []struct { desc string @@ -30,7 +30,7 @@ func TestNewFromFile(t *testing.T) { }{ { desc: "path detected by glob", - input: "test-fixtures/file-index-filter/.vimrc", + input: "testdata/file-index-filter/.vimrc", testPathFn: func(resolver file.Resolver) ([]file.Location, error) { return resolver.FilesByGlob("**/.vimrc", "**/.2", "**/.1/*", "**/empty") }, @@ -38,7 +38,7 @@ func TestNewFromFile(t *testing.T) { }, { desc: "path detected by abs path", - input: "test-fixtures/file-index-filter/.vimrc", + input: "testdata/file-index-filter/.vimrc", testPathFn: func(resolver file.Resolver) ([]file.Location, error) { return resolver.FilesByPath("/.vimrc", "/.2", "/.1/something", "/empty") }, @@ -46,7 +46,7 @@ func TestNewFromFile(t *testing.T) { }, { desc: "path detected by relative path", - input: "test-fixtures/file-index-filter/.vimrc", + input: "testdata/file-index-filter/.vimrc", testPathFn: func(resolver file.Resolver) ([]file.Location, error) { return resolver.FilesByPath(".vimrc", "/.2", "/.1/something", "empty") }, @@ -54,7 +54,7 @@ func TestNewFromFile(t *testing.T) { }, { desc: "normal path", - input: "test-fixtures/actual-path/empty", + input: "testdata/actual-path/empty", testPathFn: func(resolver file.Resolver) ([]file.Location, error) { return resolver.FilesByPath("empty") }, @@ -62,7 +62,7 @@ func TestNewFromFile(t *testing.T) { }, { desc: "path containing symlink", - input: "test-fixtures/symlink/empty", + input: "testdata/symlink/empty", testPathFn: func(resolver file.Resolver) ([]file.Location, error) { return resolver.FilesByPath("empty") }, @@ -96,7 +96,7 @@ func TestNewFromFile(t *testing.T) { } func TestNewFromFile_WithArchive(t *testing.T) { - testutil.Chdir(t, "..") // run with source/test-fixtures + testutil.Chdir(t, "..") // run with source/testdata testCases := []struct { desc string @@ -110,13 +110,13 @@ func TestNewFromFile_WithArchive(t *testing.T) { }{ { desc: "path detected", - input: "test-fixtures/path-detected", + input: "testdata/path-detected", inputPaths: []string{"/.vimrc"}, expRefs: 1, }, { desc: "use first entry for duplicate paths", - input: "test-fixtures/path-detected", + input: "testdata/path-detected", inputPaths: []string{"/.vimrc"}, expRefs: 1, layer2: true, @@ -124,7 +124,7 @@ func TestNewFromFile_WithArchive(t *testing.T) { }, { desc: "skip extract archive", - input: "test-fixtures/path-detected", + input: "testdata/path-detected", inputPaths: []string{"/.vimrc"}, expRefs: 0, layer2: false, @@ -209,7 +209,7 @@ func createArchive(t testing.TB, sourceDirPath, destinationArchivePath string, l } cmd := exec.Command("./generate-tar-fixture-from-source-dir.sh", destinationArchivePath, path.Base(sourceDirPath)) - cmd.Dir = filepath.Join(cwd, "test-fixtures") + cmd.Dir = filepath.Join(cwd, "testdata") if err := cmd.Start(); err != nil { t.Fatalf("unable to start generate zip fixture script: %+v", err) @@ -235,7 +235,7 @@ func createArchive(t testing.TB, sourceDirPath, destinationArchivePath string, l if layer2 { cmd = exec.Command("tar", "-rvf", destinationArchivePath, ".") - cmd.Dir = filepath.Join(cwd, "test-fixtures", path.Base(sourceDirPath+"-2")) + cmd.Dir = filepath.Join(cwd, "testdata", path.Base(sourceDirPath+"-2")) if err := cmd.Start(); err != nil { t.Fatalf("unable to start tar appending fixture script: %+v", err) } @@ -244,7 +244,7 @@ func createArchive(t testing.TB, sourceDirPath, destinationArchivePath string, l } func Test_FileSource_ID(t *testing.T) { - testutil.Chdir(t, "..") // run with source/test-fixtures + testutil.Chdir(t, "..") // run with source/testdata tests := []struct { name string @@ -261,27 +261,27 @@ func Test_FileSource_ID(t *testing.T) { { name: "does not exist", cfg: Config{ - Path: "./test-fixtures/does-not-exist", + Path: "./testdata/does-not-exist", }, wantErr: require.Error, }, { name: "to dir", cfg: Config{ - Path: "./test-fixtures/image-simple", + Path: "./testdata/image-simple", }, wantErr: require.Error, }, { name: "with path", - cfg: Config{Path: "./test-fixtures/image-simple/Dockerfile"}, + cfg: Config{Path: "./testdata/image-simple/Dockerfile"}, want: artifact.ID("db7146472cf6d49b3ac01b42812fb60020b0b4898b97491b21bb690c808d5159"), wantDigest: "sha256:38601c0bb4269a10ce1d00590ea7689c1117dd9274c758653934ab4f2016f80f", }, { name: "with path and alias", cfg: Config{ - Path: "./test-fixtures/image-simple/Dockerfile", + Path: "./testdata/image-simple/Dockerfile", Alias: source.Alias{ Name: "name-me-that!", Version: "version-me-this!", @@ -293,7 +293,7 @@ func Test_FileSource_ID(t *testing.T) { { name: "other fields do not affect ID", cfg: Config{ - Path: "test-fixtures/image-simple/Dockerfile", + Path: "testdata/image-simple/Dockerfile", Exclude: source.ExcludeConfig{ Paths: []string{"a", "b"}, }, diff --git a/syft/source/stereoscopesource/image_source_test.go b/syft/source/stereoscopesource/image_source_test.go index 1faaaa611..4b8f709af 100644 --- a/syft/source/stereoscopesource/image_source_test.go +++ b/syft/source/stereoscopesource/image_source_test.go @@ -15,7 +15,7 @@ import ( ) func Test_StereoscopeImage_Exclusions(t *testing.T) { - testutil.Chdir(t, "..") // run with source/test-fixtures + testutil.Chdir(t, "..") // run with source/testdata testCases := []struct { desc string diff --git a/syft/source/test-fixtures/actual-path/empty b/syft/source/testdata/actual-path/empty similarity index 100% rename from syft/source/test-fixtures/actual-path/empty rename to syft/source/testdata/actual-path/empty diff --git a/syft/source/test-fixtures/file-index-filter/.1/something b/syft/source/testdata/file-index-filter/.1/something similarity index 100% rename from syft/source/test-fixtures/file-index-filter/.1/something rename to syft/source/testdata/file-index-filter/.1/something diff --git a/syft/source/test-fixtures/file-index-filter/.2 b/syft/source/testdata/file-index-filter/.2 similarity index 100% rename from syft/source/test-fixtures/file-index-filter/.2 rename to syft/source/testdata/file-index-filter/.2 diff --git a/syft/source/test-fixtures/file-index-filter/.vimrc b/syft/source/testdata/file-index-filter/.vimrc similarity index 100% rename from syft/source/test-fixtures/file-index-filter/.vimrc rename to syft/source/testdata/file-index-filter/.vimrc diff --git a/syft/source/test-fixtures/file-index-filter/empty b/syft/source/testdata/file-index-filter/empty similarity index 100% rename from syft/source/test-fixtures/file-index-filter/empty rename to syft/source/testdata/file-index-filter/empty diff --git a/syft/source/test-fixtures/generate-tar-fixture-from-source-dir.sh b/syft/source/testdata/generate-tar-fixture-from-source-dir.sh similarity index 100% rename from syft/source/test-fixtures/generate-tar-fixture-from-source-dir.sh rename to syft/source/testdata/generate-tar-fixture-from-source-dir.sh diff --git a/syft/source/test-fixtures/image-simple/Dockerfile b/syft/source/testdata/image-simple/Dockerfile similarity index 100% rename from syft/source/test-fixtures/image-simple/Dockerfile rename to syft/source/testdata/image-simple/Dockerfile diff --git a/syft/source/test-fixtures/image-simple/file-1.txt b/syft/source/testdata/image-simple/file-1.txt similarity index 100% rename from syft/source/test-fixtures/image-simple/file-1.txt rename to syft/source/testdata/image-simple/file-1.txt diff --git a/syft/source/test-fixtures/image-simple/file-2.txt b/syft/source/testdata/image-simple/file-2.txt similarity index 100% rename from syft/source/test-fixtures/image-simple/file-2.txt rename to syft/source/testdata/image-simple/file-2.txt diff --git a/syft/source/test-fixtures/image-simple/target/really/nested/file-3.txt b/syft/source/testdata/image-simple/target/really/nested/file-3.txt similarity index 100% rename from syft/source/test-fixtures/image-simple/target/really/nested/file-3.txt rename to syft/source/testdata/image-simple/target/really/nested/file-3.txt diff --git a/syft/source/test-fixtures/path-detected-2/.vimrc b/syft/source/testdata/path-detected-2/.vimrc similarity index 100% rename from syft/source/test-fixtures/path-detected-2/.vimrc rename to syft/source/testdata/path-detected-2/.vimrc diff --git a/syft/source/test-fixtures/path-detected-2/empty b/syft/source/testdata/path-detected-2/empty similarity index 100% rename from syft/source/test-fixtures/path-detected-2/empty rename to syft/source/testdata/path-detected-2/empty diff --git a/syft/source/test-fixtures/path-detected/.vimrc b/syft/source/testdata/path-detected/.vimrc similarity index 100% rename from syft/source/test-fixtures/path-detected/.vimrc rename to syft/source/testdata/path-detected/.vimrc diff --git a/syft/source/test-fixtures/path-detected/empty b/syft/source/testdata/path-detected/empty similarity index 100% rename from syft/source/test-fixtures/path-detected/empty rename to syft/source/testdata/path-detected/empty diff --git a/syft/source/test-fixtures/symlink b/syft/source/testdata/symlink similarity index 100% rename from syft/source/test-fixtures/symlink rename to syft/source/testdata/symlink diff --git a/syft/source/test-fixtures/system_paths/outside_root/link_target/place b/syft/source/testdata/system_paths/outside_root/link_target/place similarity index 100% rename from syft/source/test-fixtures/system_paths/outside_root/link_target/place rename to syft/source/testdata/system_paths/outside_root/link_target/place diff --git a/syft/source/test-fixtures/system_paths/target/dev/place b/syft/source/testdata/system_paths/target/dev/place similarity index 100% rename from syft/source/test-fixtures/system_paths/target/dev/place rename to syft/source/testdata/system_paths/target/dev/place diff --git a/syft/source/test-fixtures/system_paths/target/home/place b/syft/source/testdata/system_paths/target/home/place similarity index 100% rename from syft/source/test-fixtures/system_paths/target/home/place rename to syft/source/testdata/system_paths/target/home/place diff --git a/syft/source/test-fixtures/system_paths/target/link/a-symlink/place b/syft/source/testdata/system_paths/target/link/a-symlink/place similarity index 100% rename from syft/source/test-fixtures/system_paths/target/link/a-symlink/place rename to syft/source/testdata/system_paths/target/link/a-symlink/place diff --git a/syft/source/test-fixtures/system_paths/target/proc/place b/syft/source/testdata/system_paths/target/proc/place similarity index 100% rename from syft/source/test-fixtures/system_paths/target/proc/place rename to syft/source/testdata/system_paths/target/proc/place diff --git a/syft/source/test-fixtures/system_paths/target/sys/place b/syft/source/testdata/system_paths/target/sys/place similarity index 100% rename from syft/source/test-fixtures/system_paths/target/sys/place rename to syft/source/testdata/system_paths/target/sys/place diff --git a/test/cli/all_formats_convertible_test.go b/test/cli/all_formats_convertible_test.go index d855a69aa..8b5a27798 100644 --- a/test/cli/all_formats_convertible_test.go +++ b/test/cli/all_formats_convertible_test.go @@ -25,7 +25,7 @@ func TestAllFormatsConvertable(t *testing.T) { {to: "syft-json", from: "spdx-json"}, {to: "syft-json", from: "cyclonedx-json"}, {to: "spdx-json", from: "syft-json"}, - {to: "template", from: "syft-json", template: "test-fixtures/csv.template"}, + {to: "template", from: "syft-json", template: "testdata/csv.template"}, {to: "spdx-json", from: "cyclonedx-json"}, {to: "cyclonedx-json", from: "syft-json"}, {to: "cyclonedx-json", from: "spdx-json"}, @@ -33,7 +33,7 @@ func TestAllFormatsConvertable(t *testing.T) { for _, test := range tests { t.Run(fmt.Sprintf("from %s to %s", test.from, test.to), func(t *testing.T) { - sbomArgs := []string{"dir:./test-fixtures/image-pkg-coverage", "-o", test.from} + sbomArgs := []string{"dir:./testdata/image-pkg-coverage", "-o", test.from} cmd, stdout, stderr := runSyft(t, test.env, sbomArgs...) if cmd.ProcessState.ExitCode() != 0 { t.Log("STDOUT:\n", stdout) diff --git a/test/cli/all_formats_expressible_test.go b/test/cli/all_formats_expressible_test.go index f19bf6188..f13d4c883 100644 --- a/test/cli/all_formats_expressible_test.go +++ b/test/cli/all_formats_expressible_test.go @@ -26,9 +26,9 @@ func TestAllFormatsExpressible(t *testing.T) { require.NotEmpty(t, formatIDs) for _, o := range formatIDs { t.Run(fmt.Sprintf("format:%s", o), func(t *testing.T) { - args := []string{"dir:./test-fixtures/image-pkg-coverage", "-o", string(o)} + args := []string{"dir:./testdata/image-pkg-coverage", "-o", string(o)} if o == template.ID { - args = append(args, "-t", "test-fixtures/csv.template") + args = append(args, "-t", "testdata/csv.template") } cmd, stdout, stderr := runSyft(t, nil, args...) @@ -69,7 +69,7 @@ func Test_formatVersionsExpressible(t *testing.T) { for _, test := range tests { t.Run(test.format, func(t *testing.T) { - args := []string{"dir:./test-fixtures/image-pkg-coverage", "-o", test.format} + args := []string{"dir:./testdata/image-pkg-coverage", "-o", test.format} cmd, stdout, stderr := runSyft(t, nil, args...) test.assertion(t, stdout, stderr, cmd.ProcessState.ExitCode()) logOutputOnFailure(t, cmd, stdout, stderr) diff --git a/test/cli/archive_test.go b/test/cli/archive_test.go index a35b4ead2..3c00c1d46 100644 --- a/test/cli/archive_test.go +++ b/test/cli/archive_test.go @@ -23,7 +23,7 @@ func TestArchiveScan(t *testing.T) { "scan", "-o", "json", - "file:" + createArchive(t, "test-fixtures/archive", t.TempDir()), + "file:" + createArchive(t, "testdata/archive", t.TempDir()), }, assertions: []traitAssertion{ assertSuccessfulReturnCode, diff --git a/test/cli/config_test.go b/test/cli/config_test.go index 3fd8287a2..3f45b0529 100644 --- a/test/cli/config_test.go +++ b/test/cli/config_test.go @@ -15,7 +15,7 @@ func Test_configLoading(t *testing.T) { require.NoError(t, err) defer func() { require.NoError(t, os.Chdir(cwd)) }() - configsDir := filepath.Join(cwd, "test-fixtures", "configs") + configsDir := filepath.Join(cwd, "testdata", "configs") path := func(path string) string { return filepath.Join(configsDir, filepath.Join(strings.Split(path, "/")...)) } diff --git a/test/cli/convert_cmd_test.go b/test/cli/convert_cmd_test.go index 2ec1455fc..944eb4876 100644 --- a/test/cli/convert_cmd_test.go +++ b/test/cli/convert_cmd_test.go @@ -34,7 +34,7 @@ func TestConvertCmd(t *testing.T) { for _, test := range tests { t.Run(fmt.Sprintf("from %s to %s", test.from, test.to), func(t *testing.T) { - sbomArgs := []string{"dir:./test-fixtures/image-pkg-coverage", "-o", test.from} + sbomArgs := []string{"dir:./testdata/image-pkg-coverage", "-o", test.from} cmd, stdout, stderr := runSyft(t, nil, sbomArgs...) if cmd.ProcessState.ExitCode() != 0 { t.Log("STDOUT:\n", stdout) diff --git a/test/cli/json_schema_test.go b/test/cli/json_schema_test.go index 31b3e4245..bf8a88554 100644 --- a/test/cli/json_schema_test.go +++ b/test/cli/json_schema_test.go @@ -41,7 +41,7 @@ func TestJSONSchema(t *testing.T) { subcommand: "scan", args: []string{"-o", "json"}, fixture: func(t *testing.T) string { - return "dir:test-fixtures/image-pkg-coverage" + return "dir:testdata/image-pkg-coverage" }, }, } diff --git a/test/cli/spdx_json_schema_test.go b/test/cli/spdx_json_schema_test.go index db518d57f..61c6972a3 100644 --- a/test/cli/spdx_json_schema_test.go +++ b/test/cli/spdx_json_schema_test.go @@ -39,7 +39,7 @@ func TestSPDXJSONSchema(t *testing.T) { subcommand: "scan", args: []string{"-o", "spdx-json"}, fixture: func(t *testing.T) string { - return "dir:test-fixtures/image-pkg-coverage" + return "dir:testdata/image-pkg-coverage" }, }, } diff --git a/test/cli/spdx_tooling_validation_test.go b/test/cli/spdx_tooling_validation_test.go index 257c84877..5d1444007 100644 --- a/test/cli/spdx_tooling_validation_test.go +++ b/test/cli/spdx_tooling_validation_test.go @@ -96,7 +96,7 @@ func TestSpdxValidationTooling(t *testing.T) { imageArg := fmt.Sprintf("IMAGE=%s", imgTag) validateCmd := exec.Command("make", "validate", fileArg, mountArg, imageArg) - validateCmd.Dir = filepath.Join(cwd, "test-fixtures", "image-java-spdx-tools") + validateCmd.Dir = filepath.Join(cwd, "testdata", "image-java-spdx-tools") stdout, stderr, err := runCommand(validateCmd, map[string]string{}) if err != nil { diff --git a/test/cli/symlink_test.go b/test/cli/symlink_test.go index 35ae90b52..c3936fa2a 100644 --- a/test/cli/symlink_test.go +++ b/test/cli/symlink_test.go @@ -8,7 +8,7 @@ import ( func Test_RequestedPathIncludesSymlink(t *testing.T) { // path contains a symlink - path := "test-fixtures/image-pkg-coverage/pkgs/java/example-java-app-maven-0.1.0.jar" + path := "testdata/image-pkg-coverage/pkgs/java/example-java-app-maven-0.1.0.jar" _, stdout, _ := runSyft(t, nil, "scan", path) assert.Contains(t, stdout, "example-java-app-maven") } diff --git a/test/cli/test-fixtures/image-pkg-coverage b/test/cli/test-fixtures/image-pkg-coverage deleted file mode 120000 index b46a39b2e..000000000 --- a/test/cli/test-fixtures/image-pkg-coverage +++ /dev/null @@ -1 +0,0 @@ -../../../cmd/syft/internal/test/integration/test-fixtures/image-pkg-coverage \ No newline at end of file diff --git a/test/cli/testdata/.gitignore b/test/cli/testdata/.gitignore new file mode 100644 index 000000000..3e8e5ed17 --- /dev/null +++ b/test/cli/testdata/.gitignore @@ -0,0 +1,3 @@ +# negate jar and zip exclusions for test fixtures that need these file types +!image-unknowns/*.jar +!image-unknowns/*.zip diff --git a/test/cli/test-fixtures/Makefile b/test/cli/testdata/Makefile similarity index 100% rename from test/cli/test-fixtures/Makefile rename to test/cli/testdata/Makefile diff --git a/test/cli/test-fixtures/archive/dist-info/METADATA b/test/cli/testdata/archive/dist-info/METADATA similarity index 100% rename from test/cli/test-fixtures/archive/dist-info/METADATA rename to test/cli/testdata/archive/dist-info/METADATA diff --git a/test/cli/test-fixtures/archive/dist-info/RECORD b/test/cli/testdata/archive/dist-info/RECORD similarity index 100% rename from test/cli/test-fixtures/archive/dist-info/RECORD rename to test/cli/testdata/archive/dist-info/RECORD diff --git a/test/cli/test-fixtures/archive/dist-info/top_level.txt b/test/cli/testdata/archive/dist-info/top_level.txt similarity index 100% rename from test/cli/test-fixtures/archive/dist-info/top_level.txt rename to test/cli/testdata/archive/dist-info/top_level.txt diff --git a/test/cli/test-fixtures/attestation/Dockerfile.ctfe_init b/test/cli/testdata/attestation/Dockerfile.ctfe_init similarity index 100% rename from test/cli/test-fixtures/attestation/Dockerfile.ctfe_init rename to test/cli/testdata/attestation/Dockerfile.ctfe_init diff --git a/test/cli/test-fixtures/attestation/config/config.json b/test/cli/testdata/attestation/config/config.json similarity index 100% rename from test/cli/test-fixtures/attestation/config/config.json rename to test/cli/testdata/attestation/config/config.json diff --git a/test/cli/test-fixtures/attestation/config/ctfe/ct_server.cfg b/test/cli/testdata/attestation/config/ctfe/ct_server.cfg similarity index 100% rename from test/cli/test-fixtures/attestation/config/ctfe/ct_server.cfg rename to test/cli/testdata/attestation/config/ctfe/ct_server.cfg diff --git a/test/cli/test-fixtures/attestation/config/ctfe/privkey.pem b/test/cli/testdata/attestation/config/ctfe/privkey.pem similarity index 100% rename from test/cli/test-fixtures/attestation/config/ctfe/privkey.pem rename to test/cli/testdata/attestation/config/ctfe/privkey.pem diff --git a/test/cli/test-fixtures/attestation/config/ctfe/pubkey.pem b/test/cli/testdata/attestation/config/ctfe/pubkey.pem similarity index 100% rename from test/cli/test-fixtures/attestation/config/ctfe/pubkey.pem rename to test/cli/testdata/attestation/config/ctfe/pubkey.pem diff --git a/test/cli/test-fixtures/attestation/config/dex/docker-compose-config.yaml b/test/cli/testdata/attestation/config/dex/docker-compose-config.yaml similarity index 100% rename from test/cli/test-fixtures/attestation/config/dex/docker-compose-config.yaml rename to test/cli/testdata/attestation/config/dex/docker-compose-config.yaml diff --git a/test/cli/test-fixtures/attestation/config/logid.sh b/test/cli/testdata/attestation/config/logid.sh similarity index 100% rename from test/cli/test-fixtures/attestation/config/logid.sh rename to test/cli/testdata/attestation/config/logid.sh diff --git a/test/cli/test-fixtures/attestation/docker-compose-config.yaml b/test/cli/testdata/attestation/docker-compose-config.yaml similarity index 100% rename from test/cli/test-fixtures/attestation/docker-compose-config.yaml rename to test/cli/testdata/attestation/docker-compose-config.yaml diff --git a/test/cli/test-fixtures/attestation/docker-compose.yaml b/test/cli/testdata/attestation/docker-compose.yaml similarity index 100% rename from test/cli/test-fixtures/attestation/docker-compose.yaml rename to test/cli/testdata/attestation/docker-compose.yaml diff --git a/test/cli/test-fixtures/configs/dir1/.syft.yaml b/test/cli/testdata/configs/dir1/.syft.yaml similarity index 100% rename from test/cli/test-fixtures/configs/dir1/.syft.yaml rename to test/cli/testdata/configs/dir1/.syft.yaml diff --git a/test/cli/test-fixtures/configs/dir2/.syft.yaml b/test/cli/testdata/configs/dir2/.syft.yaml similarity index 100% rename from test/cli/test-fixtures/configs/dir2/.syft.yaml rename to test/cli/testdata/configs/dir2/.syft.yaml diff --git a/test/cli/test-fixtures/csv.template b/test/cli/testdata/csv.template similarity index 100% rename from test/cli/test-fixtures/csv.template rename to test/cli/testdata/csv.template diff --git a/test/cli/test-fixtures/image-bad-binaries/Dockerfile b/test/cli/testdata/image-bad-binaries/Dockerfile similarity index 100% rename from test/cli/test-fixtures/image-bad-binaries/Dockerfile rename to test/cli/testdata/image-bad-binaries/Dockerfile diff --git a/test/cli/test-fixtures/image-bad-binaries/sources.list b/test/cli/testdata/image-bad-binaries/sources.list similarity index 100% rename from test/cli/test-fixtures/image-bad-binaries/sources.list rename to test/cli/testdata/image-bad-binaries/sources.list diff --git a/test/cli/test-fixtures/image-hidden-packages/Dockerfile b/test/cli/testdata/image-hidden-packages/Dockerfile similarity index 100% rename from test/cli/test-fixtures/image-hidden-packages/Dockerfile rename to test/cli/testdata/image-hidden-packages/Dockerfile diff --git a/test/cli/test-fixtures/image-java-spdx-tools/Dockerfile b/test/cli/testdata/image-java-spdx-tools/Dockerfile similarity index 100% rename from test/cli/test-fixtures/image-java-spdx-tools/Dockerfile rename to test/cli/testdata/image-java-spdx-tools/Dockerfile diff --git a/test/cli/test-fixtures/image-java-spdx-tools/Makefile b/test/cli/testdata/image-java-spdx-tools/Makefile similarity index 100% rename from test/cli/test-fixtures/image-java-spdx-tools/Makefile rename to test/cli/testdata/image-java-spdx-tools/Makefile diff --git a/test/cli/test-fixtures/image-node-binary/Dockerfile b/test/cli/testdata/image-node-binary/Dockerfile similarity index 100% rename from test/cli/test-fixtures/image-node-binary/Dockerfile rename to test/cli/testdata/image-node-binary/Dockerfile diff --git a/test/cli/testdata/image-pkg-coverage b/test/cli/testdata/image-pkg-coverage new file mode 120000 index 000000000..4919a689a --- /dev/null +++ b/test/cli/testdata/image-pkg-coverage @@ -0,0 +1 @@ +../../../cmd/syft/internal/test/integration/testdata/image-pkg-coverage \ No newline at end of file diff --git a/test/cli/test-fixtures/image-unknowns/Dockerfile b/test/cli/testdata/image-unknowns/Dockerfile similarity index 100% rename from test/cli/test-fixtures/image-unknowns/Dockerfile rename to test/cli/testdata/image-unknowns/Dockerfile diff --git a/test/cli/test-fixtures/image-unknowns/exe b/test/cli/testdata/image-unknowns/exe similarity index 100% rename from test/cli/test-fixtures/image-unknowns/exe rename to test/cli/testdata/image-unknowns/exe diff --git a/test/cli/test-fixtures/image-unknowns/executable-script b/test/cli/testdata/image-unknowns/executable-script similarity index 100% rename from test/cli/test-fixtures/image-unknowns/executable-script rename to test/cli/testdata/image-unknowns/executable-script diff --git a/test/cli/test-fixtures/image-unknowns/package-lock.json b/test/cli/testdata/image-unknowns/package-lock.json similarity index 100% rename from test/cli/test-fixtures/image-unknowns/package-lock.json rename to test/cli/testdata/image-unknowns/package-lock.json diff --git a/test/cli/test-fixtures/image-unknowns/unextracted.tar.gz b/test/cli/testdata/image-unknowns/unextracted.tar.gz similarity index 100% rename from test/cli/test-fixtures/image-unknowns/unextracted.tar.gz rename to test/cli/testdata/image-unknowns/unextracted.tar.gz diff --git a/test/cli/test-fixtures/image-unknowns/unextracted.zip b/test/cli/testdata/image-unknowns/unextracted.zip similarity index 100% rename from test/cli/test-fixtures/image-unknowns/unextracted.zip rename to test/cli/testdata/image-unknowns/unextracted.zip diff --git a/test/cli/test-fixtures/image-unknowns/unknown-readable.jar b/test/cli/testdata/image-unknowns/unknown-readable.jar similarity index 100% rename from test/cli/test-fixtures/image-unknowns/unknown-readable.jar rename to test/cli/testdata/image-unknowns/unknown-readable.jar diff --git a/test/cli/test-fixtures/image-unknowns/unknown-unreadable.jar b/test/cli/testdata/image-unknowns/unknown-unreadable.jar similarity index 100% rename from test/cli/test-fixtures/image-unknowns/unknown-unreadable.jar rename to test/cli/testdata/image-unknowns/unknown-unreadable.jar diff --git a/test/cli/test-fixtures/registry/.dockerignore b/test/cli/testdata/registry/.dockerignore similarity index 100% rename from test/cli/test-fixtures/registry/.dockerignore rename to test/cli/testdata/registry/.dockerignore diff --git a/test/cli/test-fixtures/registry/Dockerfile b/test/cli/testdata/registry/Dockerfile similarity index 100% rename from test/cli/test-fixtures/registry/Dockerfile rename to test/cli/testdata/registry/Dockerfile diff --git a/test/cli/test-fixtures/registry/Makefile b/test/cli/testdata/registry/Makefile similarity index 100% rename from test/cli/test-fixtures/registry/Makefile rename to test/cli/testdata/registry/Makefile diff --git a/test/compare/deb.sh b/test/compare/deb.sh index 46793472d..55002b464 100755 --- a/test/compare/deb.sh +++ b/test/compare/deb.sh @@ -11,7 +11,7 @@ TEST_TYPE=deb WORK_DIR=`mktemp -d -t "syft-acceptance-test-${TEST_TYPE}-XXXXXX"` NORMAL_TEST_IMAGE=$(echo ${TEST_IMAGE} | tr ':' '-' ) REPORT=${WORK_DIR}/acceptance-${TEST_TYPE}-${NORMAL_TEST_IMAGE}.json -GOLDEN_REPORT=${ACC_DIR}/test-fixtures/acceptance-${NORMAL_TEST_IMAGE}.json +GOLDEN_REPORT=${ACC_DIR}/testdata/acceptance-${NORMAL_TEST_IMAGE}.json # check if tmp dir was created if [[ ! "${WORK_DIR}" || ! -d "${WORK_DIR}" ]]; then diff --git a/test/compare/mac.sh b/test/compare/mac.sh index 3aadab2e2..2cbefd34e 100755 --- a/test/compare/mac.sh +++ b/test/compare/mac.sh @@ -12,7 +12,7 @@ TEST_TYPE=mac WORK_DIR=`mktemp -d -t "syft-acceptance-test-${TEST_TYPE}-XXXXXX"` NORMAL_TEST_IMAGE=$(echo ${TEST_IMAGE} | tr ':' '-' ) REPORT=${WORK_DIR}/acceptance-${TEST_TYPE}-${NORMAL_TEST_IMAGE}.json -GOLDEN_REPORT=${ACC_DIR}/test-fixtures/acceptance-${NORMAL_TEST_IMAGE}.json +GOLDEN_REPORT=${ACC_DIR}/testdata/acceptance-${NORMAL_TEST_IMAGE}.json # check if tmp dir was created if [[ ! "${WORK_DIR}" || ! -d "${WORK_DIR}" ]]; then diff --git a/test/compare/rpm.sh b/test/compare/rpm.sh index d857822e8..2f08f7c1e 100755 --- a/test/compare/rpm.sh +++ b/test/compare/rpm.sh @@ -12,7 +12,7 @@ TEST_TYPE=rpm WORK_DIR=`mktemp -d -t "syft-acceptance-test-${TEST_TYPE}-XXXXXX"` NORMAL_TEST_IMAGE=$(echo ${TEST_IMAGE} | tr ':' '-' ) REPORT=${WORK_DIR}/acceptance-${TEST_TYPE}-${NORMAL_TEST_IMAGE}.json -GOLDEN_REPORT=${ACC_DIR}/test-fixtures/acceptance-${NORMAL_TEST_IMAGE}.json +GOLDEN_REPORT=${ACC_DIR}/testdata/acceptance-${NORMAL_TEST_IMAGE}.json # check if tmp dir was created if [[ ! "${WORK_DIR}" || ! -d "${WORK_DIR}" ]]; then diff --git a/test/compare/test-fixtures/acceptance-centos-8.2.2004.json b/test/compare/testdata/acceptance-centos-8.2.2004.json similarity index 100% rename from test/compare/test-fixtures/acceptance-centos-8.2.2004.json rename to test/compare/testdata/acceptance-centos-8.2.2004.json diff --git a/test/install/0_checksums_test.sh b/test/install/0_checksums_test.sh index 2bc992d6a..9257f55c9 100755 --- a/test/install/0_checksums_test.sh +++ b/test/install/0_checksums_test.sh @@ -2,7 +2,7 @@ # search for an asset in a release checksums file test_search_for_asset_release() { - fixture=./test-fixtures/syft_0.36.0_checksums.txt + fixture=./testdata/syft_0.36.0_checksums.txt # search_for_asset [checksums-file-path] [name] [os] [arch] [format] @@ -24,7 +24,7 @@ run_test_case test_search_for_asset_release # search for an asset in a snapshot checksums file test_search_for_asset_snapshot() { - fixture=./test-fixtures/syft_0.35.1-SNAPSHOT-d461f63_checksums.txt + fixture=./testdata/syft_0.35.1-SNAPSHOT-d461f63_checksums.txt # search_for_asset [checksums-file-path] [name] [os] [arch] [format] @@ -42,7 +42,7 @@ run_test_case test_search_for_asset_snapshot # verify 256 digest of a file test_hash_sha256() { - target=./test-fixtures/assets/valid/syft_1.5.0_linux_arm64.tar.gz + target=./testdata/assets/valid/syft_1.5.0_linux_arm64.tar.gz # hash_sha256 [target] @@ -61,8 +61,8 @@ test_hash_sha256_verify() { # positive case - checksums=./test-fixtures/assets/valid/checksums.txt - target=./test-fixtures/assets/valid/syft_1.5.0_linux_arm64.tar.gz + checksums=./testdata/assets/valid/checksums.txt + target=./testdata/assets/valid/syft_1.5.0_linux_arm64.tar.gz hash_sha256_verify "${target}" "${checksums}" assertEquals "0" "$?" "mismatched checksum" @@ -73,8 +73,8 @@ test_hash_sha256_verify() { # we are expecting error messages, which is confusing to look at in passing tests... disable logging for now log_set_priority -1 - checksums=./test-fixtures/assets/invalid/checksums.txt - target=./test-fixtures/assets/invalid/syft_1.5.0_linux_arm64.tar.gz + checksums=./testdata/assets/invalid/checksums.txt + target=./testdata/assets/invalid/syft_1.5.0_linux_arm64.tar.gz hash_sha256_verify "${target}" "${checksums}" assertEquals "1" "$?" "verification did not catch mismatched checksum" diff --git a/test/install/github_test.sh b/test/install/github_test.sh index 29d9ed9c5..e3a4a661d 100755 --- a/test/install/github_test.sh +++ b/test/install/github_test.sh @@ -2,7 +2,7 @@ # check that we can extract single json values test_extract_json_value() { - fixture=./test-fixtures/github-api-syft-v0.36.0-release.json + fixture=./testdata/github-api-syft-v0.36.0-release.json content=$(cat ${fixture}) actual=$(extract_json_value "${content}" "tag_name") @@ -17,7 +17,7 @@ run_test_case test_extract_json_value # check that we can extract github release tag from github api json test_github_release_tag() { - fixture=./test-fixtures/github-api-syft-v0.36.0-release.json + fixture=./testdata/github-api-syft-v0.36.0-release.json content=$(cat ${fixture}) actual=$(github_release_tag "${content}") @@ -38,7 +38,7 @@ test_download_github_release_checksums() { actual_filepath=$(download_github_release_checksums "${github_download}" "${name}" "${version}" "${tmpdir}") assertFilesEqual \ - "./test-fixtures/syft_0.36.0_checksums.txt" \ + "./testdata/syft_0.36.0_checksums.txt" \ "${actual_filepath}" \ "unable to find release tag" diff --git a/test/install/test-fixtures/assets/invalid/.gitignore b/test/install/testdata/assets/invalid/.gitignore similarity index 100% rename from test/install/test-fixtures/assets/invalid/.gitignore rename to test/install/testdata/assets/invalid/.gitignore diff --git a/test/install/test-fixtures/assets/invalid/checksums.txt b/test/install/testdata/assets/invalid/checksums.txt similarity index 100% rename from test/install/test-fixtures/assets/invalid/checksums.txt rename to test/install/testdata/assets/invalid/checksums.txt diff --git a/test/install/test-fixtures/assets/invalid/syft_1.5.0_linux_arm64.tar.gz b/test/install/testdata/assets/invalid/syft_1.5.0_linux_arm64.tar.gz similarity index 100% rename from test/install/test-fixtures/assets/invalid/syft_1.5.0_linux_arm64.tar.gz rename to test/install/testdata/assets/invalid/syft_1.5.0_linux_arm64.tar.gz diff --git a/test/install/test-fixtures/assets/valid/.gitignore b/test/install/testdata/assets/valid/.gitignore similarity index 100% rename from test/install/test-fixtures/assets/valid/.gitignore rename to test/install/testdata/assets/valid/.gitignore diff --git a/test/install/test-fixtures/assets/valid/checksums.txt b/test/install/testdata/assets/valid/checksums.txt similarity index 100% rename from test/install/test-fixtures/assets/valid/checksums.txt rename to test/install/testdata/assets/valid/checksums.txt diff --git a/test/install/test-fixtures/assets/valid/syft_1.5.0_linux_arm64.tar.gz b/test/install/testdata/assets/valid/syft_1.5.0_linux_arm64.tar.gz similarity index 100% rename from test/install/test-fixtures/assets/valid/syft_1.5.0_linux_arm64.tar.gz rename to test/install/testdata/assets/valid/syft_1.5.0_linux_arm64.tar.gz diff --git a/test/install/test-fixtures/github-api-syft-v0.36.0-release.json b/test/install/testdata/github-api-syft-v0.36.0-release.json similarity index 100% rename from test/install/test-fixtures/github-api-syft-v0.36.0-release.json rename to test/install/testdata/github-api-syft-v0.36.0-release.json diff --git a/test/install/test-fixtures/syft_0.35.1-SNAPSHOT-d461f63_checksums.txt b/test/install/testdata/syft_0.35.1-SNAPSHOT-d461f63_checksums.txt similarity index 100% rename from test/install/test-fixtures/syft_0.35.1-SNAPSHOT-d461f63_checksums.txt rename to test/install/testdata/syft_0.35.1-SNAPSHOT-d461f63_checksums.txt diff --git a/test/install/test-fixtures/syft_0.36.0_checksums.txt b/test/install/testdata/syft_0.36.0_checksums.txt similarity index 100% rename from test/install/test-fixtures/syft_0.36.0_checksums.txt rename to test/install/testdata/syft_0.36.0_checksums.txt