diff --git a/internal/ztest/timeout.go b/internal/ztest/timeout.go index f7d58f316..e4222f947 100644 --- a/internal/ztest/timeout.go +++ b/internal/ztest/timeout.go @@ -42,11 +42,11 @@ func Sleep(base time.Duration) { // Initialize checks the environment and alters the timeout scale accordingly. // It returns a function to undo the scaling. func Initialize(factor string) func() { - original := _timeoutScale fv, err := strconv.ParseFloat(factor, 64) if err != nil { panic(err) } + original := _timeoutScale _timeoutScale = fv return func() { _timeoutScale = original } }