Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
93d969ce86 | ||
|
|
f46b1a08ee | ||
|
|
a4c99c70f4 |
@@ -19,7 +19,7 @@ func TestStruct(t *testing.T) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func genClient() (*Client, error) {
|
func genClient() (*Client, error) {
|
||||||
url := "https://cpnode.demo.internetapi.cn/api/ctrlproxy/SCIDE"
|
url := "http://021.node.internetapi.cn:43030/SCIDE"
|
||||||
|
|
||||||
pub, err := sm2util.ParsePublicKey("04153ad2d70e67741e0fc33e0c92c702e2afba2480dbea73d23fd02a3ce3a1b69979a7006a8e045f8836ae4797a8fe426823d7ad3450817e794948c8e47b60b711")
|
pub, err := sm2util.ParsePublicKey("04153ad2d70e67741e0fc33e0c92c702e2afba2480dbea73d23fd02a3ce3a1b69979a7006a8e045f8836ae4797a8fe426823d7ad3450817e794948c8e47b60b711")
|
||||||
if err != nil {
|
if err != nil {
|
||||||
@@ -86,7 +86,7 @@ func TestClient_ExecuteContract(t *testing.T) {
|
|||||||
t.Error(err)
|
t.Error(err)
|
||||||
}
|
}
|
||||||
|
|
||||||
resp, err := client.ExecuteContract("ShanxiControlProxy", "listRepository", "", false, true)
|
resp, err := client.ExecuteContract("GlobalRouter", "resolveDoIdTest", "{\"doId\":\"bdtest021/ControlProxy\"}", false, true)
|
||||||
|
|
||||||
if err != nil {
|
if err != nil {
|
||||||
t.Log(resp)
|
t.Log(resp)
|
||||||
@@ -11,11 +11,7 @@ type ClientResponse[T any] struct {
|
|||||||
NeedSeq bool `json:"needSeq,omitempty"`
|
NeedSeq bool `json:"needSeq,omitempty"`
|
||||||
Seq int `json:"seq,omitempty"`
|
Seq int `json:"seq,omitempty"`
|
||||||
Status string `json:"status,omitempty"`
|
Status string `json:"status,omitempty"`
|
||||||
Result struct {
|
Result T `json:"result,omitempty"`
|
||||||
Data T `json:"data,omitempty"`
|
|
||||||
Count int `json:"count,omitempty"`
|
|
||||||
Code int `json:"code,omitempty"`
|
|
||||||
} `json:"result,omitempty"`
|
|
||||||
IsInsnLimit bool `json:"isInsnLimit,omitempty"`
|
IsInsnLimit bool `json:"isInsnLimit,omitempty"`
|
||||||
TotalGas int `json:"totalGas,omitempty"`
|
TotalGas int `json:"totalGas,omitempty"`
|
||||||
ExecutionGas int `json:"executionGas,omitempty"`
|
ExecutionGas int `json:"executionGas,omitempty"`
|
||||||
@@ -4,4 +4,4 @@ go 1.23
|
|||||||
|
|
||||||
require github.com/tjfoc/gmsm v1.4.1
|
require github.com/tjfoc/gmsm v1.4.1
|
||||||
|
|
||||||
require golang.org/x/sync v0.9.0 // indirect
|
require golang.org/x/sync v0.9.0
|
||||||
Reference in New Issue
Block a user