cmd/documentation: Add pagination support for contributors (#1885)

* cmd/documentation: Add pagination support for contributors

* Drop break and return immediately

* documentation: change defaultGithubAPIPerPageLimit to an integer and update usage in GetContributorList
This commit is contained in:
Adrian Gallagher
2025-04-15 15:08:02 +10:00
committed by GitHub
parent 228f26e087
commit 3fc40292b7
5 changed files with 159 additions and 198 deletions

View File

@@ -0,0 +1,15 @@
package main
import (
"testing"
"github.com/stretchr/testify/require"
)
func TestGetContributorList(t *testing.T) {
t.Parallel()
c, err := GetContributorList(t.Context(), DefaultRepo, true)
require.NoError(t, err, "GetContributorList must not error")
require.NotEmpty(t, c, "GetContributorList must not return empty list")
}