From 54bc57094f5e524456d3c74c771c388a7a540f2f Mon Sep 17 00:00:00 2001 From: Timothy Messier Date: Fri, 23 Feb 2024 15:49:49 +0000 Subject: [PATCH] chore(authtoken): Fix lint errors in tests --- internal/authtoken/authtoken_test.go | 3 ++- internal/authtoken/repository_test.go | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/internal/authtoken/authtoken_test.go b/internal/authtoken/authtoken_test.go index 6bc4e9451c..f524aa0847 100644 --- a/internal/authtoken/authtoken_test.go +++ b/internal/authtoken/authtoken_test.go @@ -140,7 +140,8 @@ func TestAuthToken_DbCreate(t *testing.T) { am := password.TestAuthMethods(t, conn, org.GetPublicId(), 1)[0] acct := password.TestAccount(t, conn, am.GetPublicId(), "name1") createdAuthToken := TestAuthToken(t, conn, kms, org.GetPublicId()) - iamRepo.AddUserAccounts(ctx, user.GetPublicId(), user.GetVersion(), []string{acct.GetPublicId()}) + _, err = iamRepo.AddUserAccounts(ctx, user.GetPublicId(), user.GetVersion(), []string{acct.GetPublicId()}) + require.NoError(t, err) testAuthTokenId := func() string { id, err := NewAuthTokenId(ctx) diff --git a/internal/authtoken/repository_test.go b/internal/authtoken/repository_test.go index 8ad38c330e..c37b2588df 100644 --- a/internal/authtoken/repository_test.go +++ b/internal/authtoken/repository_test.go @@ -914,7 +914,7 @@ func Test_CloseExpiredPendingTokens(t *testing.T) { user, _, err = iamRepo.LookupUser(ctx, user.GetPublicId()) require.NoError(t, err) - iamRepo.AddUserAccounts(ctx, user.GetPublicId(), user.GetVersion(), []string{accts[i].GetPublicId()}) + _, _ = iamRepo.AddUserAccounts(ctx, user.GetPublicId(), user.GetVersion(), []string{accts[i].GetPublicId()}) at := allocAuthToken() id, err := NewAuthTokenId(ctx)