Skip to content

Commit

Permalink
implemented some of modulitos' review proposals
Browse files Browse the repository at this point in the history
  • Loading branch information
roehrijn committed Aug 29, 2024
1 parent fe74545 commit e20c44f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pkg/cache/cache.go
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ type Response struct {
TokenExpiration int64
FoundInSACache bool
FoundInCMCache bool
Notifier chan struct{}
Notifier <-chan struct{}
}

type ServiceAccountCache interface {
Expand Down
3 changes: 2 additions & 1 deletion pkg/cache/cache_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,8 @@ func TestNotification(t *testing.T) {
for i := 0; i < 10; i++ {
wg.Add(1)
go func() {
defer wg.Done()

// wait for the notification
select {
case <-resp.Notifier:
Expand All @@ -136,7 +138,6 @@ func TestNotification(t *testing.T) {
case <-time.After(1 * time.Second):
t.Error("timeout waiting for notification")
}
wg.Done()
}()
}

Expand Down

0 comments on commit e20c44f

Please sign in to comment.