Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Internalize majority of cmd package #2533

Merged
merged 6 commits into from
Jan 24, 2024
Merged

Conversation

wagoodman
Copy link
Contributor

@wagoodman wagoodman commented Jan 23, 2024

This migrates thecmd/syft/cli/commands and cmd/syft/cli/options to cmd/syft/internal. In the process of doing so it became necessary to:

  • migrate integration tests to cmd/syft/internal... as well since there are specific options.* objects that help test against real CLI defaults (which is important in integration testing).
  • add internal/encoders to act as an internal API for the full set of encoders that we can express, so that the CLI tests understand what formats should be under test.

@wagoodman wagoodman added the breaking-change Change is not backwards compatible label Jan 23, 2024
@wagoodman wagoodman added this to the Syft 1.0 milestone Jan 23, 2024
@wagoodman wagoodman requested a review from a team January 23, 2024 17:21
@wagoodman wagoodman self-assigned this Jan 23, 2024
@wagoodman wagoodman marked this pull request as ready for review January 23, 2024 21:24
Copy link
Contributor

@spiffcs spiffcs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approve with just the nit on if a change was inadvertent from some find/replace command or if automated tooling did that

@wagoodman wagoodman merged commit e0e1c4b into main Jan 24, 2024
11 checks passed
@wagoodman wagoodman deleted the migrate-integration-tests branch January 24, 2024 18:29
GijsCalis pushed a commit to GijsCalis/syft that referenced this pull request Feb 19, 2024
* internalize majority of cmd package and migrate integration tests

Signed-off-by: Alex Goodman <[email protected]>

* add internal api encoder

Signed-off-by: Alex Goodman <[email protected]>

* create internal representation of all formats

Signed-off-by: Alex Goodman <[email protected]>

* export capability to get default encoders

Signed-off-by: Alex Goodman <[email protected]>

* restore test fixtures

Signed-off-by: Alex Goodman <[email protected]>

---------

Signed-off-by: Alex Goodman <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking-change Change is not backwards compatible
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants