Skip to content

Commit

Permalink
update wait_test indices
Browse files Browse the repository at this point in the history
Signed-off-by: redwrasse <[email protected]>
  • Loading branch information
redwrasse committed Jul 29, 2024
1 parent 5f782c3 commit 7a82606
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions pkg/wait/wait_time_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,10 @@ func TestWaitTime(t *testing.T) {
func TestWaitTestStress(t *testing.T) {
chs := make([]<-chan struct{}, 0)
wt := NewTimeList()
for i := 0; i < 10000; i++ {
for i := 0; i <= 10000; i++ {
chs = append(chs, wt.Wait(uint64(i)))
}
wt.Trigger(10000 - 1)
wt.Trigger(10000)

for _, ch := range chs {
select {
Expand All @@ -78,9 +78,9 @@ func BenchmarkWaitTime(b *testing.B) {
func BenchmarkTriggerAnd10KWaitTime(b *testing.B) {
for i := 0; i < b.N; i++ {
wt := NewTimeList()
for j := 0; j < 10000; j++ {
for j := 0; j <= 10000; j++ {
wt.Wait(uint64(j))
}
wt.Trigger(10000 - 1)
wt.Trigger(10000)
}
}

0 comments on commit 7a82606

Please sign in to comment.