parent
39ce8cd516
commit
2f1b3ce16e
@ -0,0 +1,12 @@
|
||||
package cos
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/tencentyun/cos-go-sdk-v5"
|
||||
"net/http"
|
||||
"net/url"
|
||||
_ "unsafe"
|
||||
)
|
||||
|
||||
//go:linkname newRequest github.com/tencentyun/cos-go-sdk-v5.(*Client).newRequest
|
||||
func newRequest(c *cos.Client, ctx context.Context, baseURL *url.URL, uri, method string, body interface{}, optQuery interface{}, optHeader interface{}) (req *http.Request, err error)
|
@ -0,0 +1,10 @@
|
||||
package cos
|
||||
|
||||
import (
|
||||
"testing"
|
||||
)
|
||||
|
||||
func TestName(t *testing.T) {
|
||||
newRequest(nil, nil, nil, "", "", nil, nil, nil)
|
||||
|
||||
}
|
@ -0,0 +1,10 @@
|
||||
package minio
|
||||
|
||||
import (
|
||||
"github.com/minio/minio-go/v7"
|
||||
"net/url"
|
||||
_ "unsafe"
|
||||
)
|
||||
|
||||
//go:linkname makeTargetURL github.com/minio/minio-go/v7.(*Client).makeTargetURL
|
||||
func makeTargetURL(client *minio.Client, bucketName, objectName, bucketLocation string, isVirtualHostStyle bool, queryValues url.Values) (*url.URL, error)
|
@ -0,0 +1,19 @@
|
||||
package minio
|
||||
|
||||
import (
|
||||
"testing"
|
||||
)
|
||||
|
||||
func TestName(t *testing.T) {
|
||||
//u, err := makeTargetURL(&minio.Client{}, "openim", "test.png", "", false, nil)
|
||||
//if err != nil {
|
||||
// panic(err)
|
||||
//}
|
||||
//u.String()
|
||||
//t.Log(percentEncodeSlash("1234"))
|
||||
//
|
||||
//t.Log(FastRand())
|
||||
t.Log(makeTargetURL(nil, "", "", "", false, nil))
|
||||
//t.Log(privateNew("", nil))
|
||||
|
||||
}
|
@ -0,0 +1,27 @@
|
||||
package oss
|
||||
|
||||
import (
|
||||
"testing"
|
||||
)
|
||||
|
||||
func TestName(t *testing.T) {
|
||||
//ossSignHeader(nil, nil, "")
|
||||
//t.Log("ossSignHeader")
|
||||
|
||||
//var c oss.Conn
|
||||
//blc := reflect.ValueOf(&c).Elem().FieldByName("url") // *urlMaker
|
||||
//
|
||||
//urlPtr := reflect.New(blc.Type().Elem()).Addr() // *urlMaker
|
||||
//
|
||||
//vblc := reflect.New(reflect.PtrTo(blc.Type()))
|
||||
//*(*unsafe.Pointer)(vblc.UnsafePointer()) = unsafe.Pointer(blc.UnsafeAddr())
|
||||
//vblc.Elem().Elem().Interface().(interface{ Set(string, string) }).Set(conf.Bucket, m.location)
|
||||
//
|
||||
//
|
||||
//
|
||||
//
|
||||
//fmt.Println(inter)
|
||||
|
||||
//getURL(nil, "", "", "")
|
||||
|
||||
}
|
Loading…
Reference in new issue