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
authz: End2End test for AuditLogger #6304
Merged
Merged
Changes from 1 commit
Commits
Show all changes
23 commits
Select commit
Hold shift + click to select a range
5778913
Draft of e2e test
erm-g cebf932
No Audit, Audit on Allow and Deny
erm-g d405ab2
Audit on Allow, Audit on Deny
erm-g 0baf0e6
fix typo
erm-g b569c67
SPIFFE related testing
erm-g 135565a
SPIFFE Id validation and certs creation script
erm-g c19e304
Address PR comments
erm-g 1e7fcc4
Wrap tests using grpctest.Tester
erm-g e5991f2
Address PR comments
erm-g 620d990
Change package name to authz_test to fit other end2end tests
erm-g cba398c
Add licence header, remove SPIFFE slice
erm-g de59ce5
Licence year change
erm-g 9a8ee49
Address PR comments part 1
erm-g 36bc552
Address PR comments part 2
erm-g b255385
Address PR comments part 3
erm-g 7777c5b
Address PR comments final part
erm-g 191fdf6
Drop newline for a brace
erm-g 80d38b4
Address PR comments, fix outdated function comment
erm-g 46fda00
Address PR comments
erm-g a02960d
Fix typo
erm-g 56eba6e
Remove unused var
erm-g cb01a30
Address PR comment, change most test error handling to Errorf
erm-g 4f30f15
Address PR comments
erm-g File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This one needs to be
Fatal
because using thestream
is illegal.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I need some help here - go/go-style/decisions.md?cl=head#keep-going suggests to prefer
Error
overFatal
So for this test even if stream is not usable I can still proceed with unary calls to get the test results for it.
However the same doc suggests
and unusable stream is definitely something we don't expect.
WDYT?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
True,
Error
is nicer, generally, but this is a precondition for (some of) the rest of the test. The "ideal" would be to skip just the streaming calls and the checks that depend on them happening, but that really clutters the code and isn't worth it at all. JustFatal
since a precondition failed and keep things simple.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, sounds good - I changed
Errorf
to be used forcmp.Diff
casesstatus.Code
is not expected