Skip to content

Commit

Permalink
#1825 Update eth_call unit test
Browse files Browse the repository at this point in the history
  • Loading branch information
DmytroNazarenko committed Mar 18, 2024
1 parent 5452ee7 commit 263d4b7
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions test/unittests/libweb3jsonrpc/jsonrpc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -855,6 +855,16 @@ BOOST_AUTO_TEST_CASE( simple_contract ) {
string result = fixture.rpcClient->eth_call( call, "latest" );
BOOST_CHECK_EQUAL(
result, "0x0000000000000000000000000000000000000000000000000000000000000007" );

Json::Value inputCall;
inputCall["to"] = contractAddress;
inputCall["input"] = "0xb3de648b0000000000000000000000000000000000000000000000000000000000000001";
inputCall["gas"] = "1000000";
inputCall["gasPrice"] = "0";
result = fixture.rpcClient->eth_call( inputCall, "latest" );
BOOST_CHECK_EQUAL(
result, "0x0000000000000000000000000000000000000000000000000000000000000007" );

}

/*
Expand Down

0 comments on commit 263d4b7

Please sign in to comment.