Skip to content

adding unit test variations for sigstore #6023

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

mikebrow
Copy link
Contributor

@mikebrow mikebrow commented Apr 21, 2025

Improve unit coverage for sigstore

Pull Request check list

  • Commit conforms to CONTRIBUTING.md?
  • Proper tests/regressions included?
  • Documentation updated?

Affected functionality

added unit test coverage for internal processRegistryCredentials() ignore invalid credential options (nil, and no user/password)
https://github.com/spiffe/spire/blob/main/pkg/agent/common/sigstore/sigstore.go#L401-L424

and setting default public rekor URL
(https://github.com/spiffe/spire/blob/main/pkg/agent/common/sigstore/sigstore.go#L94-L96)

and various checks against failures to extract details from signatures

from
ok github.com/spiffe/spire/pkg/agent/common/sigstore 0.019s coverage: 85.4% of statements

to
ok github.com/spiffe/spire/pkg/agent/common/sigstore 0.013s coverage: 91.0% of statements

@amartinezfayo amartinezfayo self-assigned this Apr 22, 2025
@mikebrow mikebrow force-pushed the sigstore-unit-test-additions branch 2 times, most recently from 75410be to 3ac6d99 Compare April 23, 2025 17:31
@mikebrow
Copy link
Contributor Author

mikebrow commented Apr 23, 2025

finished adding unit buckets for this .go for now hit my 90% target :-)

@mikebrow mikebrow force-pushed the sigstore-unit-test-additions branch from 3ac6d99 to 435eb4b Compare April 23, 2025 19:46
@mikebrow
Copy link
Contributor Author

mikebrow commented Apr 23, 2025

bumped commit header to re-run tests looks like possible 404 flake (unrelated to this PR) in the httpchallenge bucket

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants