Skip to content

Commit

Permalink
update tests with vars
Browse files Browse the repository at this point in the history
  • Loading branch information
ysebyy committed Sep 11, 2024
1 parent c6f882c commit e8d7826
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions internal/requests_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ func TestWalkRepositories(t *testing.T) {
reqConf := createGetRepositoriesConfig(goodResponseServer.URL)
err := WalkRepositories(reqConf, func(repos []string, apiToken string) {
collectedRepos = append(collectedRepos, repos...)
})
}, 0, 0)
require.NoError(t, err)
assert.Equal(t, 4, hitCounter)

Expand All @@ -159,7 +159,7 @@ func TestWalkRepositories(t *testing.T) {
})

t.Run("return an error when request config contains invalid URL", func(t *testing.T) {
err := WalkRepositories(createGetRepositoriesConfig("http://bad url.com"), nil)
err := WalkRepositories(createGetRepositoriesConfig("http://bad url.com"), nil, 0, 0)
var e url.InvalidHostError
assert.ErrorAs(t, err, &e)
assert.Contains(t, err.Error(), repositoryWalkFailed)
Expand Down

0 comments on commit e8d7826

Please sign in to comment.