fix(tests): update goleak check condition to use GOLEAK environment variable
Signed-off-by: Deluan <deluan@navidrome.org>
This commit is contained in:
parent
4ec6e7c56e
commit
fd620413b8
1 changed files with 2 additions and 2 deletions
|
|
@ -14,8 +14,8 @@ import (
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestScanner(t *testing.T) {
|
func TestScanner(t *testing.T) {
|
||||||
// Only run goleak checks when not in CI environment
|
// Only run goleak checks when the GOLEAK env var is set
|
||||||
if os.Getenv("CI") == "" {
|
if os.Getenv("GOLEAK") != "" {
|
||||||
// Detect any goroutine leaks in the scanner code under test
|
// Detect any goroutine leaks in the scanner code under test
|
||||||
defer goleak.VerifyNone(t,
|
defer goleak.VerifyNone(t,
|
||||||
goleak.IgnoreTopFunction("github.com/onsi/ginkgo/v2/internal/interrupt_handler.(*InterruptHandler).registerForInterrupts.func2"),
|
goleak.IgnoreTopFunction("github.com/onsi/ginkgo/v2/internal/interrupt_handler.(*InterruptHandler).registerForInterrupts.func2"),
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue