Skip to content

Commit

Permalink
Update pkg/graph/cache_test.go
Browse files Browse the repository at this point in the history
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
  • Loading branch information
naveensrinivasan and coderabbitai[bot] authored Aug 22, 2024
1 parent 5a581a9 commit e8456c2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/graph/cache_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ func TestRandomGraphDependenciesWithControlledCircles(t *testing.T) {
}

// Set random dependencies, allowing controlled circles
rand.Seed(time.Now().UnixNano())
r := rand.New(rand.NewSource(time.Now().UnixNano()))

Check failure on line 69 in pkg/graph/cache_test.go

View workflow job for this annotation

GitHub Actions / build-and-test

r declared and not used
cycleProbability := 0.01 // 1% chance to create a cycle
for i := 0; i < n; i++ {
possibleDeps := rand.Perm(n - i) // Generate a random permutation of indices [0, min(90, n-i)-1]
Expand Down

0 comments on commit e8456c2

Please sign in to comment.