rpc: add Magic to Version
This commit is contained in:
parent
c50f3db6ad
commit
474d2dfb65
3 changed files with 10 additions and 5 deletions
|
@ -631,9 +631,10 @@ var rpcClientTestCases = map[string][]rpcClientTestCase{
|
|||
invoke: func(c *Client) (interface{}, error) {
|
||||
return c.GetVersion()
|
||||
},
|
||||
serverResponse: `{"id":1,"jsonrpc":"2.0","result":{"tcpport":20332,"wsport":20342,"nonce":2153672787,"useragent":"/NEO-GO:0.73.1-pre-273-ge381358/"}}`,
|
||||
serverResponse: `{"id":1,"jsonrpc":"2.0","result":{"magic":42,"tcpport":20332,"wsport":20342,"nonce":2153672787,"useragent":"/NEO-GO:0.73.1-pre-273-ge381358/"}}`,
|
||||
result: func(c *Client) interface{} {
|
||||
return &result.Version{
|
||||
Magic: netmode.UnitTestNet,
|
||||
TCPPort: uint16(20332),
|
||||
WSPort: uint16(20342),
|
||||
Nonce: 2153672787,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue