aboutsummaryrefslogtreecommitdiff
path: root/libgo/go/rpc/jsonrpc/all_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'libgo/go/rpc/jsonrpc/all_test.go')
-rw-r--r--libgo/go/rpc/jsonrpc/all_test.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/libgo/go/rpc/jsonrpc/all_test.go b/libgo/go/rpc/jsonrpc/all_test.go
index 764ee7f..c1a9e8e 100644
--- a/libgo/go/rpc/jsonrpc/all_test.go
+++ b/libgo/go/rpc/jsonrpc/all_test.go
@@ -35,7 +35,7 @@ func (t *Arith) Mul(args *Args, reply *Reply) os.Error {
func (t *Arith) Div(args *Args, reply *Reply) os.Error {
if args.B == 0 {
- return os.ErrorString("divide by zero")
+ return os.NewError("divide by zero")
}
reply.C = args.A / args.B
return nil
@@ -51,9 +51,9 @@ func init() {
func TestServer(t *testing.T) {
type addResp struct {
- Id interface{} "id"
- Result Reply "result"
- Error interface{} "error"
+ Id interface{} `json:"id"`
+ Result Reply `json:"result"`
+ Error interface{} `json:"error"`
}
cli, srv := net.Pipe()