mirror of
https://github.com/tendermint/tendermint.git
synced 2026-09-07 00:26:58 +00:00
use TendermintResult for rpctypes.Result
This commit is contained in:
@@ -29,7 +29,7 @@ func TestJSONStatus(t *testing.T) {
|
||||
}
|
||||
|
||||
func testStatus(t *testing.T, result interface{}) {
|
||||
status := result.(*ctypes.ResultStatus)
|
||||
status := result.(*ctypes.TendermintResult).Result.(*ctypes.ResultStatus)
|
||||
if status.NodeInfo.Network != chainID {
|
||||
t.Fatal(fmt.Errorf("ChainID mismatch: got %s expected %s",
|
||||
status.NodeInfo.Network, chainID))
|
||||
|
||||
+2
-2
@@ -137,7 +137,7 @@ func waitForEvent(t *testing.T, con *websocket.Conn, eventid string, dieOnTimeou
|
||||
errCh <- err
|
||||
break
|
||||
}
|
||||
event, ok := response.Result.(*ctypes.ResultEvent)
|
||||
event, ok := response.Result.(*ctypes.TendermintResult).Result.(*ctypes.ResultEvent)
|
||||
if ok && event.Event == eventid {
|
||||
goodCh <- p
|
||||
break
|
||||
@@ -191,7 +191,7 @@ func unmarshalResponseNewBlock(b []byte) (*types.Block, error) {
|
||||
if response.Error != "" {
|
||||
return nil, fmt.Errorf(response.Error)
|
||||
}
|
||||
block := response.Result.(*ctypes.ResultEvent).Data.(types.EventDataNewBlock).Block
|
||||
block := response.Result.(*ctypes.TendermintResult).Result.(*ctypes.ResultEvent).Data.(types.EventDataNewBlock).Block
|
||||
return block, nil
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user