Этот коммит содержится в:
Softonik 2025-06-27 01:32:08 +03:00
родитель 61d22264e4
коммит fe103371e1

Просмотреть файл

@ -4,6 +4,7 @@ import (
"errors" "errors"
"fmt" "fmt"
"strconv" "strconv"
"time"
. "github.com/onsi/gomega" . "github.com/onsi/gomega"
) )
@ -43,3 +44,11 @@ func Atof(in string) float64 {
Ok(err) Ok(err)
return res return res
} }
func SetTestDeadlockProtection() {
go checkTestTimeout(1 * time.Second)
}
func checkTestTimeout(t time.Duration) {
<-time.After(t)
panic("Test Suite Timeout")
}