mirror of
https://github.com/coder/coder.git
synced 2025-07-12 00:14:10 +00:00
Addresses the following flakes: - https://github.com/coder/internal/issues/222 - https://github.com/coder/internal/issues/223 - https://github.com/coder/internal/issues/224 - https://github.com/coder/internal/issues/225 - https://github.com/coder/internal/issues/226 - https://github.com/coder/internal/issues/227 - https://github.com/coder/internal/issues/228 - https://github.com/coder/internal/issues/229 - https://github.com/coder/internal/issues/230
25 lines
613 B
Go
25 lines
613 B
Go
package testutil
|
|
|
|
import "time"
|
|
|
|
// Constants for timing out operations, usable for creating contexts
|
|
// that timeout or in require.Eventually.
|
|
//
|
|
// Windows durations are adjusted for slow CI workers.
|
|
const (
|
|
WaitShort = 30 * time.Second
|
|
WaitMedium = 40 * time.Second
|
|
WaitLong = 70 * time.Second
|
|
WaitSuperLong = 240 * time.Second
|
|
)
|
|
|
|
// Constants for delaying repeated operations, e.g. in
|
|
// require.Eventually.
|
|
//
|
|
// Windows durations are adjusted for slow CI workers.
|
|
const (
|
|
IntervalFast = 100 * time.Millisecond
|
|
IntervalMedium = 1000 * time.Millisecond
|
|
IntervalSlow = 4 * time.Second
|
|
)
|