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

Fix logic with service accounts. Update e2e tests. Add test coverage #141

Merged
merged 5 commits into from
Oct 23, 2020

Conversation

sudermanjr
Copy link
Member

@sudermanjr sudermanjr commented Oct 22, 2020

I found a bug in the subjectKey logic in the lister where we would miss a lot of bindings that were related to service accounts. I have added test coverage and e2e tests to cover this.

Fixes #42

@sudermanjr sudermanjr changed the title Write tests to prove that #42 is a bug Issues with multiple roleBindings in multiple namespaces for a single service account Oct 22, 2020
@codecov
Copy link

codecov bot commented Oct 22, 2020

Codecov Report

Merging #141 into master will increase coverage by 5.01%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #141      +/-   ##
==========================================
+ Coverage   36.00%   41.01%   +5.01%     
==========================================
  Files           4        4              
  Lines         175      178       +3     
==========================================
+ Hits           63       73      +10     
+ Misses        103      100       -3     
+ Partials        9        5       -4     
Impacted Files Coverage Δ
lookup/lister.go 59.25% <100.00%> (+8.64%) ⬆️
lookup/rbac_subject.go 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update feaf45b...c3e415b. Read the comment docs.

@sudermanjr sudermanjr changed the title Issues with multiple roleBindings in multiple namespaces for a single service account Fix logic with service accounts. Update e2e tests. Add test coverage Oct 22, 2020
@sudermanjr sudermanjr marked this pull request as ready for review October 22, 2020 23:47
Copy link
Contributor

@lucasreed lucasreed left a comment

Choose a reason for hiding this comment

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

Fix a bug and increase test coverage :amaze:

Thanks!

@lucasreed lucasreed merged commit 030e248 into master Oct 23, 2020
@lucasreed lucasreed deleted the sudermanjr/service-account-bugs branch October 23, 2020 15:46
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.

Missing Rolebindings from lookup
2 participants