refactor: move some io, http and string utils to separate repo

This commit is contained in:
yusing
2025-09-27 12:46:41 +08:00
parent acecd827d6
commit 22bcf1201b
115 changed files with 125 additions and 3815 deletions

View File

@@ -11,9 +11,9 @@ import (
"github.com/yusing/godoxy/internal/common"
"github.com/yusing/godoxy/internal/gperr"
"github.com/yusing/godoxy/internal/net/gphttp/reverseproxy"
nettypes "github.com/yusing/godoxy/internal/net/types"
. "github.com/yusing/godoxy/internal/utils/testing"
"github.com/yusing/goutils/http/reverseproxy"
)
//go:embed test_data/sample_headers.json
@@ -152,7 +152,7 @@ func newMiddlewaresTest(middlewares []*Middleware, args *testArgs) (*TestResult,
rr.parent = http.DefaultTransport
}
rp := reverseproxy.NewReverseProxy("test", args.upstreamURL, rr)
rp := reverseproxy.NewReverseProxy("test", &args.upstreamURL.URL, rr)
patchReverseProxy(rp, middlewares)
rp.ServeHTTP(w, req)