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

[CAPPL-471] Add more tests to verify that panic is handled #1003

Merged
merged 1 commit into from
Jan 17, 2025

Conversation

cedric-cordenier
Copy link
Contributor

Requires

Supports

Copy link
Contributor

@krehermann krehermann left a comment

Choose a reason for hiding this comment

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

small suggested improvements at your discretion

EnvVarsAssignedToNodes: nil,
},
}
_, err = DecryptSecretsForNode(results, k, "owner")
Copy link
Contributor

Choose a reason for hiding this comment

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

table driven test for multiple error paths? can't tell from the test which of the field is required to be non-nil.


// Define test cases
tests := []struct {
name string
inputData []byte
encryptionPublicKeys map[string][32]byte
workflowOwner string
shouldError bool
errMsg string
Copy link
Contributor

Choose a reason for hiding this comment

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

nit/ rename to wantErrMsg or expectedErrMsg

@cedric-cordenier cedric-cordenier merged commit 2b05726 into main Jan 17, 2025
10 of 11 checks passed
@cedric-cordenier cedric-cordenier deleted the CAPPL-471-handle-panic branch January 17, 2025 14:44
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.

3 participants