1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
|
From: Daniel Swarbrick <dswarbrick@debian.org>
Date: Fri, 13 May 2022 20:19:41 +0200
Subject: Disable network tests
Forwarded: not-needed
Use testing '-short' flag to disable tests requiring network.
---
helpers_test.go | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/helpers_test.go b/helpers_test.go
index 29e0ab4..5302780 100644
--- a/helpers_test.go
+++ b/helpers_test.go
@@ -9,6 +9,11 @@ import (
)
func TestCreatProxyHelper(t *testing.T) {
+ // createProxyHeader calls net.LookupIP, which will fail in a build env
+ if testing.Short() {
+ t.Skip("skipping testing in short mode")
+ }
+
cfg := &config.Config{
ListenAddress: "192.0.2.1:3192",
SquidHostname: "127.0.0.1",
|