Browse Source

test info

pull/418/head
Ethan Frey 8 years ago
parent
commit
5ea3f24304
1 changed files with 12 additions and 0 deletions
  1. +12
    -0
      rpc/client/rpc_test.go

+ 12
- 0
rpc/client/rpc_test.go View File

@ -1,6 +1,7 @@
package client_test
import (
"strings"
"testing"
"time"
@ -21,6 +22,17 @@ func TestStatus(t *testing.T) {
}
}
// Make sure info is correct (we connect properly)
func TestInfo(t *testing.T) {
c := rpctest.GetClient()
status, err := c.Status()
require.Nil(t, err)
info, err := c.ABCIInfo()
require.Nil(t, err)
assert.EqualValues(t, status.LatestBlockHeight, info.Response.LastBlockHeight)
assert.True(t, strings.HasPrefix(info.Response.Data, "size:"))
}
// Make some app checks
func TestAppCalls(t *testing.T) {
assert, require := assert.New(t), require.New(t)


Loading…
Cancel
Save