aboutsummaryrefslogtreecommitdiffstats
path: root/tests/integration/api_keys_test.go
diff options
context:
space:
mode:
authorTheFox0x7 <thefox0x7@gmail.com>2024-12-15 11:41:29 +0100
committerGitHub <noreply@github.com>2024-12-15 10:41:29 +0000
commit33e8e82c4b528db8efb1cf9fc4dbab2d9e21ace8 (patch)
tree6ee296e2ef469911d0db440100e1eb835945af89 /tests/integration/api_keys_test.go
parentdf9a78cd04e364264c103cf3a92d94179cc1dd4f (diff)
downloadgitea-33e8e82c4b528db8efb1cf9fc4dbab2d9e21ace8.tar.gz
gitea-33e8e82c4b528db8efb1cf9fc4dbab2d9e21ace8.zip
Enable tenv and testifylint rules (#32852)
Enables tenv and testifylint linters closes: https://github.com/go-gitea/gitea/issues/32842
Diffstat (limited to 'tests/integration/api_keys_test.go')
-rw-r--r--tests/integration/api_keys_test.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/integration/api_keys_test.go b/tests/integration/api_keys_test.go
index 89ad1ec0df..2276b955cf 100644
--- a/tests/integration/api_keys_test.go
+++ b/tests/integration/api_keys_test.go
@@ -168,7 +168,7 @@ func TestCreateUserKey(t *testing.T) {
resp = MakeRequest(t, req, http.StatusOK)
DecodeJSON(t, resp, &fingerprintPublicKeys)
- assert.Len(t, fingerprintPublicKeys, 0)
+ assert.Empty(t, fingerprintPublicKeys)
// Fail searching for wrong users key
req = NewRequest(t, "GET", fmt.Sprintf("/api/v1/users/%s/keys?fingerprint=%s", "user2", newPublicKey.Fingerprint)).
@@ -176,7 +176,7 @@ func TestCreateUserKey(t *testing.T) {
resp = MakeRequest(t, req, http.StatusOK)
DecodeJSON(t, resp, &fingerprintPublicKeys)
- assert.Len(t, fingerprintPublicKeys, 0)
+ assert.Empty(t, fingerprintPublicKeys)
// Now login as user 2
session2 := loginUser(t, "user2")
@@ -208,5 +208,5 @@ func TestCreateUserKey(t *testing.T) {
resp = MakeRequest(t, req, http.StatusOK)
DecodeJSON(t, resp, &fingerprintPublicKeys)
- assert.Len(t, fingerprintPublicKeys, 0)
+ assert.Empty(t, fingerprintPublicKeys)
}