diff --git a/accounts/abi/event_test.go b/accounts/abi/event_test.go index 5c999fc63a..e735cceb88 100644 --- a/accounts/abi/event_test.go +++ b/accounts/abi/event_test.go @@ -123,8 +123,8 @@ func TestEventString(t *testing.T) { { "type" : "event", "name" : "Transfer", "inputs": [{ "name": "from", "type": "address", "indexed": true }, { "name": "to", "type": "address", "indexed": true }, { "name": "value", "type": "uint256" }] } ]`, expectations: map[string]string{ - "Balance": "event Balance(uint256 in)", - "Check": "event Check(address t, uint256 b)", + "Balance": "event Balance(uint256 in)", + "Check": "event Check(address t, uint256 b)", "Transfer": "event Transfer(address indexed from, address indexed to, uint256 value)", }, }, diff --git a/accounts/abi/method_test.go b/accounts/abi/method_test.go index e39b0dc8f1..a98f1cd31f 100644 --- a/accounts/abi/method_test.go +++ b/accounts/abi/method_test.go @@ -28,25 +28,23 @@ const methoddata = ` { "type" : "function", "name" : "transfer", "constant" : false, "inputs" : [ { "name" : "from", "type" : "address" }, { "name" : "to", "type" : "address" }, { "name" : "value", "type" : "uint256" } ], "outputs" : [ { "name" : "success", "type" : "bool" } ] } ]` - func TestMethodString(t *testing.T) { var table = []struct { - method string + method string expectation string }{ { - method: "balance", - expectation:"function balance() constant returns()", + method: "balance", + expectation: "function balance() constant returns()", }, { - method: "send", - expectation:"function send(uint256 amount) returns()", + method: "send", + expectation: "function send(uint256 amount) returns()", }, { - method: "transfer", - expectation:"function transfer(address from, address to, uint256 value) returns(bool success)", + method: "transfer", + expectation: "function transfer(address from, address to, uint256 value) returns(bool success)", }, - } abi, err := JSON(strings.NewReader(methoddata)) @@ -56,8 +54,8 @@ func TestMethodString(t *testing.T) { for _, test := range table { got := abi.Methods[test.method].String() - if got != test.expectation { - t.Errorf("expected string to be %s, got %s", test.expectation, got) - } + if got != test.expectation { + t.Errorf("expected string to be %s, got %s", test.expectation, got) + } } }