From 1b239dadcc766fa08fc8612a8562f2ca75b2ad0c Mon Sep 17 00:00:00 2001 From: Gustavo Santos Ferreira Date: Thu, 25 Oct 2018 17:42:14 -0300 Subject: [PATCH] update tests --- apps/ethereum_jsonrpc/lib/ethereum_jsonrpc/receipt.ex | 2 ++ apps/ethereum_jsonrpc/lib/ethereum_jsonrpc/receipts.ex | 1 + apps/ethereum_jsonrpc/test/ethereum_jsonrpc/receipts_test.exs | 4 ++++ 3 files changed, 7 insertions(+) diff --git a/apps/ethereum_jsonrpc/lib/ethereum_jsonrpc/receipt.ex b/apps/ethereum_jsonrpc/lib/ethereum_jsonrpc/receipt.ex index 52af2031f4..b2a0271e80 100644 --- a/apps/ethereum_jsonrpc/lib/ethereum_jsonrpc/receipt.ex +++ b/apps/ethereum_jsonrpc/lib/ethereum_jsonrpc/receipt.ex @@ -65,6 +65,7 @@ defmodule EthereumJSONRPC.Receipt do ...> } ...> ) %{ + created_contract_address_hash: "0xffc87239eb0267bc3ca2cd51d12fbf278e02ccb4", cumulative_gas_used: 269607, gas_used: 269607, status: :ok, @@ -97,6 +98,7 @@ defmodule EthereumJSONRPC.Receipt do ...> } ...> ) %{ + created_contract_address_hash: nil, cumulative_gas_used: 21001, gas_used: 21001, status: nil, diff --git a/apps/ethereum_jsonrpc/lib/ethereum_jsonrpc/receipts.ex b/apps/ethereum_jsonrpc/lib/ethereum_jsonrpc/receipts.ex index 6056e07ba4..e5d706589c 100644 --- a/apps/ethereum_jsonrpc/lib/ethereum_jsonrpc/receipts.ex +++ b/apps/ethereum_jsonrpc/lib/ethereum_jsonrpc/receipts.ex @@ -97,6 +97,7 @@ defmodule EthereumJSONRPC.Receipts do ...> ]) [ %{ + created_contract_address_hash: nil, cumulative_gas_used: 50450, gas_used: 50450, status: :ok, diff --git a/apps/ethereum_jsonrpc/test/ethereum_jsonrpc/receipts_test.exs b/apps/ethereum_jsonrpc/test/ethereum_jsonrpc/receipts_test.exs index 59e29b2511..d8eef3b6da 100644 --- a/apps/ethereum_jsonrpc/test/ethereum_jsonrpc/receipts_test.exs +++ b/apps/ethereum_jsonrpc/test/ethereum_jsonrpc/receipts_test.exs @@ -14,6 +14,7 @@ defmodule EthereumJSONRPC.ReceiptsTest do describe "fetch/2" do test "with receipts and logs", %{json_rpc_named_arguments: json_rpc_named_arguments} do %{ + created_contract_address_hash: nil, cumulative_gas_used: cumulative_gas_used, gas_used: gas_used, address_hash: address_hash, @@ -29,6 +30,7 @@ defmodule EthereumJSONRPC.ReceiptsTest do case Keyword.fetch!(json_rpc_named_arguments, :variant) do EthereumJSONRPC.Geth -> %{ + created_contract_address_hash: nil, cumulative_gas_used: 884_322, address_hash: "0x1e2fbe6be9eb39fc894d38be976111f332172d83", block_number: 3_560_000, @@ -45,6 +47,7 @@ defmodule EthereumJSONRPC.ReceiptsTest do EthereumJSONRPC.Parity -> %{ + created_contract_address_hash: nil, cumulative_gas_used: 50450, gas_used: 50450, address_hash: "0x8bf38d4764929064f2d4d3a56520a76ab3df415b", @@ -73,6 +76,7 @@ defmodule EthereumJSONRPC.ReceiptsTest do %{ id: 0, result: %{ + "contractAddress" => nil, "cumulativeGasUsed" => integer_to_quantity(cumulative_gas_used), "gasUsed" => integer_to_quantity(gas_used), "logs" => [