Skip to content

Commit d08f486

Browse files
Gustedearl-warren
authored andcommitted
[GITEA] Simplify cron list test (squash)
- As per https://codeberg.org/forgejo/forgejo/pulls/1352#issuecomment-1076074 - Only test if the returned stuff is correct, not necessarily accurate. (cherry picked from commit 55bcaf60ec21aec000ff79635981a16566c77d43) (cherry picked from commit 4f03e4810619455e7dca65741cb53a9fd2d98bfe) (cherry picked from commit f35c31b9beef33e0aafc4e62e5b8fa38b3623494)
1 parent 360ac8e commit d08f486

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

tests/integration/api_admin_test.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -298,11 +298,12 @@ func TestAPICron(t *testing.T) {
298298
req := NewRequest(t, "GET", urlStr)
299299
resp := MakeRequest(t, req, http.StatusOK)
300300

301-
assert.Equal(t, "27", resp.Header().Get("X-Total-Count"))
301+
assert.NotEmpty(t, resp.Header().Get("X-Total-Count"))
302302

303303
var crons []api.Cron
304304
DecodeJSON(t, resp, &crons)
305-
assert.Len(t, crons, 27)
305+
306+
assert.NotEmpty(t, crons)
306307
})
307308

308309
t.Run("Execute", func(t *testing.T) {

0 commit comments

Comments
 (0)