Vet/race fixes (#4421)

This addresses all found vet/race fixes in community edition.

---------

Co-authored-by: Damian Debkowski <damian.debkowski@hashicorp.com>
This commit is contained in:
Jeff MitchellandDamian Debkowski authored and GitHub committed 2024-02-21 16:32:26 -05:00
1 parent 4535af25aa
commit 014a5a7aae
46 files changed
+411 -176

No files matched your search

+2 -2
View File
@@ -155,7 +155,7 @@ func TestService_List(t *testing.T) {
filterFunc := func(_ context.Context, at *authtoken.AuthToken) (bool, error) {
return true, nil
}
_, err = authtoken.ListPage(ctx, []byte("some hash"), 1, filterFunc, nil, repo, []string{org.GetPublicId()})
_, err := authtoken.ListPage(ctx, []byte("some hash"), 1, filterFunc, nil, repo, []string{org.GetPublicId()})
require.ErrorContains(t, err, "missing token")
})
t.Run("wrong token type", func(t *testing.T) {
@@ -243,7 +243,7 @@ func TestService_List(t *testing.T) {
filterFunc := func(_ context.Context, at *authtoken.AuthToken) (bool, error) {
return true, nil
}
_, err = authtoken.ListRefresh(ctx, []byte("some hash"), 1, filterFunc, nil, repo, []string{org.GetPublicId()})
_, err := authtoken.ListRefresh(ctx, []byte("some hash"), 1, filterFunc, nil, repo, []string{org.GetPublicId()})
require.ErrorContains(t, err, "missing token")
})
t.Run("wrong token type", func(t *testing.T) {