fix: connection keep alive

This commit is contained in:
debugtalk
2021-10-31 18:00:25 +08:00
parent ed2ab201f0
commit 04808d9f9f
+9 -3
View File
@@ -12,6 +12,7 @@ import (
"strconv" "strconv"
"strings" "strings"
"testing" "testing"
"time"
"github.com/pkg/errors" "github.com/pkg/errors"
) )
@@ -23,9 +24,14 @@ func Run(t *testing.T, testcases ...ITestCase) error {
func NewRunner() *Runner { func NewRunner() *Runner {
return &Runner{ return &Runner{
t: &testing.T{}, t: &testing.T{},
debug: false, // default to turn off debug debug: false, // default to turn off debug
client: &http.Client{}, client: &http.Client{
Transport: &http.Transport{
TLSClientConfig: &tls.Config{InsecureSkipVerify: true},
},
Timeout: 30 * time.Second,
},
} }
} }