mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-27 15:16:43 +00:00
fix testcase
This commit is contained in:
parent
3c666fde68
commit
75eea85168
2 changed files with 104 additions and 102 deletions
|
|
@ -583,7 +583,8 @@ func (b testBackend) GetBorBlockTransaction(ctx context.Context, hash common.Has
|
|||
}
|
||||
|
||||
func (b testBackend) GetBorBlockTransactionWithBlockHash(ctx context.Context, txHash common.Hash, blockHash common.Hash) (*types.Transaction, common.Hash, uint64, uint64, error) {
|
||||
panic("implement me")
|
||||
tx, blockHash, blockNumber, index := rawdb.ReadBorTransactionWithBlockHash(b.ChainDb(), txHash, blockHash)
|
||||
return tx, blockHash, blockNumber, index, nil
|
||||
}
|
||||
|
||||
func (b testBackend) GetRootHash(ctx context.Context, starBlockNr uint64, endBlockNr uint64) (string, error) {
|
||||
|
|
@ -1153,8 +1154,6 @@ func TestRPCMarshalBlock(t *testing.T) {
|
|||
|
||||
func TestRPCGetBlockOrHeader(t *testing.T) {
|
||||
t.Parallel()
|
||||
// TODO - Arpit Fix hashes
|
||||
t.Skip()
|
||||
|
||||
// Initialize test accounts
|
||||
var (
|
||||
|
|
@ -1225,16 +1224,16 @@ func TestRPCGetBlockOrHeader(t *testing.T) {
|
|||
"extraData": "0x",
|
||||
"gasLimit": "0x47e7c4",
|
||||
"gasUsed": "0x5208",
|
||||
"hash": "0x97f540a3577c0f645c5dada5da86f38350e8f847e71f21124f917835003e2607",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
|
||||
"hash": "0x872ee27d64627520cf93483c9b43d6710a33814ad56b42cb6a3f318a67ae3d4b",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000808000000000000000000000000000000000000000000000000000000000800000000000000000000100000020000000000000000000000000000000000802000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000800000000000000000000000800000108000000000000000000000000000000000000000000000000020000000000000000000100000",
|
||||
"miner": "0x0000000000000000000000000000000000000000",
|
||||
"mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
|
||||
"nonce": "0x0000000000000000",
|
||||
"number": "0xa",
|
||||
"parentHash": "0xda97ed946e0d502fb898b0ac881bd44da3c7fee5eaf184431e1ec3d361dad17e",
|
||||
"receiptsRoot": "0x056b23fbba480696b65fe5a59b8f2148a1299103c4f57df839233af2cf4ca2d2",
|
||||
"parentHash": "0xf72973d179c425bcc46a56d1f90fc9ae036e09895bc732d238ecc776ad513671",
|
||||
"receiptsRoot": "0xaa293d21b2dd99a4fafcba16c6ad824b09ec42a927c68456bc8209a76bc3e433",
|
||||
"sha3Uncles": "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
|
||||
"stateRoot": "0xbb62872e4023fa8a8b17b9cc37031f4817d9595779748d01cba408b495707a91",
|
||||
"stateRoot": "0x1776127ce43163b6a16fc9d03b1f90f097768d3175c98ff38ccaf6e22b51dc31",
|
||||
"timestamp": "0x64",
|
||||
"totalDifficulty": "0x1",
|
||||
"transactionsRoot": "0xb0893d21a4a44dc26a962a6e91abae66df87fb61ac9c60e936aee89c76331445"
|
||||
|
|
@ -1275,16 +1274,16 @@ func TestRPCGetBlockOrHeader(t *testing.T) {
|
|||
"extraData": "0x",
|
||||
"gasLimit": "0x47e7c4",
|
||||
"gasUsed": "0x5208",
|
||||
"hash": "0x0da274b315de8e4d5bf8717218ec43540464ef36378cb896469bb731e1d3f3cb",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
|
||||
"hash": "0xc2050a588d6c8a355ad62275fa97132b7becc03f7626ddd2b17d49a0ae62beb7",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000808000000000000000000000000000000000000000000000000000000000800000000000000000000100000020000000000000000000000000000000000802000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000800000000000000000000000800000108000000000000000000000000000000000000000000000000020000000000000000000100000",
|
||||
"miner": "0x0000000000000000000000000000000000000000",
|
||||
"mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
|
||||
"nonce": "0x0000000000000000",
|
||||
"number": "0x1",
|
||||
"parentHash": "0xbdc7d83b8f876938810462fe8d053263a482e44201e3883d4ae204ff4de7eff5",
|
||||
"receiptsRoot": "0x056b23fbba480696b65fe5a59b8f2148a1299103c4f57df839233af2cf4ca2d2",
|
||||
"receiptsRoot": "0x3794d9c550fc8ed2060bff730acc48524aaa4b87b272c43e034b100d3da4f1b8",
|
||||
"sha3Uncles": "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
|
||||
"stateRoot": "0x92c5c55a698963f5b06e3aee415630f5c48b0760e537af94917ce9c4f42a2e22",
|
||||
"stateRoot": "0x00337febf454e9e7c16ac80678d5408a674e3b7404ecccaaffceec6cf2d803fa",
|
||||
"timestamp": "0xa",
|
||||
"totalDifficulty": "0x1",
|
||||
"transactionsRoot": "0xca0ebcce920d2cdfbf9e1dbe90ed3441a1a576f344bd80e60508da814916f4e7"
|
||||
|
|
@ -1300,16 +1299,16 @@ func TestRPCGetBlockOrHeader(t *testing.T) {
|
|||
"extraData": "0x",
|
||||
"gasLimit": "0x47e7c4",
|
||||
"gasUsed": "0x5208",
|
||||
"hash": "0xda97ed946e0d502fb898b0ac881bd44da3c7fee5eaf184431e1ec3d361dad17e",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
|
||||
"hash": "0xf72973d179c425bcc46a56d1f90fc9ae036e09895bc732d238ecc776ad513671",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000808000000000000000000000000000000000000000000000000000000000800000000000000000000100000020000000000000000000000000000000000802000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000800000000000000000000000800000108000000000000000000000000000000000000000000000000020000000000000000000100000",
|
||||
"miner": "0x0000000000000000000000000000000000000000",
|
||||
"mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
|
||||
"nonce": "0x0000000000000000",
|
||||
"number": "0x9",
|
||||
"parentHash": "0x5abd19c39d9f1c6e52998e135ea14e1fbc5db3fa2a108f4538e238ca5c2e68d7",
|
||||
"receiptsRoot": "0x056b23fbba480696b65fe5a59b8f2148a1299103c4f57df839233af2cf4ca2d2",
|
||||
"parentHash": "0x6f572ecb5694ea18c1ba005c40708a66d495e682d6780ee74d3fd3d5ea8bc4be",
|
||||
"receiptsRoot": "0xfd13763f8f5b1115449da3a892d7208f551b15bceda5509b1d6aa35d65a9a2ed",
|
||||
"sha3Uncles": "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
|
||||
"stateRoot": "0xbd4aa2c2873df709151075250a8c01c9a14d2b0e2f715dbdd16e0ef8030c2cf0",
|
||||
"stateRoot": "0x93818d689d9a3d71eddc80c3687bcbb1f45c8204d52614e1377921d389c62249",
|
||||
"timestamp": "0x5a",
|
||||
"totalDifficulty": "0x1",
|
||||
"transactionsRoot": "0x0767ed8359337dc6a8fdc77fe52db611bed1be87aac73c4556b1bf1dd3d190a5"
|
||||
|
|
@ -1355,17 +1354,17 @@ func TestRPCGetBlockOrHeader(t *testing.T) {
|
|||
"extraData": "0x",
|
||||
"gasLimit": "0x47e7c4",
|
||||
"gasUsed": "0x5208",
|
||||
"hash": "0x97f540a3577c0f645c5dada5da86f38350e8f847e71f21124f917835003e2607",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
|
||||
"hash": "0x872ee27d64627520cf93483c9b43d6710a33814ad56b42cb6a3f318a67ae3d4b",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000808000000000000000000000000000000000000000000000000000000000800000000000000000000100000020000000000000000000000000000000000802000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000800000000000000000000000800000108000000000000000000000000000000000000000000000000020000000000000000000100000",
|
||||
"miner": "0x0000000000000000000000000000000000000000",
|
||||
"mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
|
||||
"nonce": "0x0000000000000000",
|
||||
"number": "0xa",
|
||||
"parentHash": "0xda97ed946e0d502fb898b0ac881bd44da3c7fee5eaf184431e1ec3d361dad17e",
|
||||
"receiptsRoot": "0x056b23fbba480696b65fe5a59b8f2148a1299103c4f57df839233af2cf4ca2d2",
|
||||
"parentHash": "0xf72973d179c425bcc46a56d1f90fc9ae036e09895bc732d238ecc776ad513671",
|
||||
"receiptsRoot": "0xaa293d21b2dd99a4fafcba16c6ad824b09ec42a927c68456bc8209a76bc3e433",
|
||||
"sha3Uncles": "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
|
||||
"size": "0x26a",
|
||||
"stateRoot": "0xbb62872e4023fa8a8b17b9cc37031f4817d9595779748d01cba408b495707a91",
|
||||
"stateRoot": "0x1776127ce43163b6a16fc9d03b1f90f097768d3175c98ff38ccaf6e22b51dc31",
|
||||
"timestamp": "0x64",
|
||||
"totalDifficulty": "0x1",
|
||||
"transactions": [
|
||||
|
|
@ -1411,17 +1410,17 @@ func TestRPCGetBlockOrHeader(t *testing.T) {
|
|||
"extraData": "0x",
|
||||
"gasLimit": "0x47e7c4",
|
||||
"gasUsed": "0x5208",
|
||||
"hash": "0x0da274b315de8e4d5bf8717218ec43540464ef36378cb896469bb731e1d3f3cb",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
|
||||
"hash": "0xc2050a588d6c8a355ad62275fa97132b7becc03f7626ddd2b17d49a0ae62beb7",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000808000000000000000000000000000000000000000000000000000000000800000000000000000000100000020000000000000000000000000000000000802000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000800000000000000000000000800000108000000000000000000000000000000000000000000000000020000000000000000000100000",
|
||||
"miner": "0x0000000000000000000000000000000000000000",
|
||||
"mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
|
||||
"nonce": "0x0000000000000000",
|
||||
"number": "0x1",
|
||||
"parentHash": "0xbdc7d83b8f876938810462fe8d053263a482e44201e3883d4ae204ff4de7eff5",
|
||||
"receiptsRoot": "0x056b23fbba480696b65fe5a59b8f2148a1299103c4f57df839233af2cf4ca2d2",
|
||||
"receiptsRoot": "0x3794d9c550fc8ed2060bff730acc48524aaa4b87b272c43e034b100d3da4f1b8",
|
||||
"sha3Uncles": "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
|
||||
"size": "0x26a",
|
||||
"stateRoot": "0x92c5c55a698963f5b06e3aee415630f5c48b0760e537af94917ce9c4f42a2e22",
|
||||
"stateRoot": "0x00337febf454e9e7c16ac80678d5408a674e3b7404ecccaaffceec6cf2d803fa",
|
||||
"timestamp": "0xa",
|
||||
"totalDifficulty": "0x1",
|
||||
"transactions": [
|
||||
|
|
@ -1441,22 +1440,22 @@ func TestRPCGetBlockOrHeader(t *testing.T) {
|
|||
"extraData": "0x",
|
||||
"gasLimit": "0x47e7c4",
|
||||
"gasUsed": "0x5208",
|
||||
"hash": "0xda97ed946e0d502fb898b0ac881bd44da3c7fee5eaf184431e1ec3d361dad17e",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
|
||||
"hash": "0xf72973d179c425bcc46a56d1f90fc9ae036e09895bc732d238ecc776ad513671",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000808000000000000000000000000000000000000000000000000000000000800000000000000000000100000020000000000000000000000000000000000802000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000800000000000000000000000800000108000000000000000000000000000000000000000000000000020000000000000000000100000",
|
||||
"miner": "0x0000000000000000000000000000000000000000",
|
||||
"mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
|
||||
"nonce": "0x0000000000000000",
|
||||
"number": "0x9",
|
||||
"parentHash": "0x5abd19c39d9f1c6e52998e135ea14e1fbc5db3fa2a108f4538e238ca5c2e68d7",
|
||||
"receiptsRoot": "0x056b23fbba480696b65fe5a59b8f2148a1299103c4f57df839233af2cf4ca2d2",
|
||||
"parentHash": "0x6f572ecb5694ea18c1ba005c40708a66d495e682d6780ee74d3fd3d5ea8bc4be",
|
||||
"receiptsRoot": "0xfd13763f8f5b1115449da3a892d7208f551b15bceda5509b1d6aa35d65a9a2ed",
|
||||
"sha3Uncles": "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
|
||||
"size": "0x26a",
|
||||
"stateRoot": "0xbd4aa2c2873df709151075250a8c01c9a14d2b0e2f715dbdd16e0ef8030c2cf0",
|
||||
"stateRoot": "0x93818d689d9a3d71eddc80c3687bcbb1f45c8204d52614e1377921d389c62249",
|
||||
"timestamp": "0x5a",
|
||||
"totalDifficulty": "0x1",
|
||||
"transactions": [
|
||||
{
|
||||
"blockHash": "0xda97ed946e0d502fb898b0ac881bd44da3c7fee5eaf184431e1ec3d361dad17e",
|
||||
"blockHash": "0xf72973d179c425bcc46a56d1f90fc9ae036e09895bc732d238ecc776ad513671",
|
||||
"blockNumber": "0x9",
|
||||
"from": "0x703c4b2bd70c169f5717101caee543299fc946c7",
|
||||
"gas": "0x5208",
|
||||
|
|
@ -1585,16 +1584,16 @@ func TestRPCGetBlockOrHeader(t *testing.T) {
|
|||
"extraData": "0x",
|
||||
"gasLimit": "0x47e7c4",
|
||||
"gasUsed": "0x5208",
|
||||
"hash": "0x97f540a3577c0f645c5dada5da86f38350e8f847e71f21124f917835003e2607",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
|
||||
"hash": "0x872ee27d64627520cf93483c9b43d6710a33814ad56b42cb6a3f318a67ae3d4b",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000808000000000000000000000000000000000000000000000000000000000800000000000000000000100000020000000000000000000000000000000000802000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000800000000000000000000000800000108000000000000000000000000000000000000000000000000020000000000000000000100000",
|
||||
"miner": "0x0000000000000000000000000000000000000000",
|
||||
"mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
|
||||
"nonce": "0x0000000000000000",
|
||||
"number": "0xa",
|
||||
"parentHash": "0xda97ed946e0d502fb898b0ac881bd44da3c7fee5eaf184431e1ec3d361dad17e",
|
||||
"receiptsRoot": "0x056b23fbba480696b65fe5a59b8f2148a1299103c4f57df839233af2cf4ca2d2",
|
||||
"parentHash": "0xf72973d179c425bcc46a56d1f90fc9ae036e09895bc732d238ecc776ad513671",
|
||||
"receiptsRoot": "0xaa293d21b2dd99a4fafcba16c6ad824b09ec42a927c68456bc8209a76bc3e433",
|
||||
"sha3Uncles": "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
|
||||
"stateRoot": "0xbb62872e4023fa8a8b17b9cc37031f4817d9595779748d01cba408b495707a91",
|
||||
"stateRoot": "0x1776127ce43163b6a16fc9d03b1f90f097768d3175c98ff38ccaf6e22b51dc31",
|
||||
"timestamp": "0x64",
|
||||
"totalDifficulty": "0x1",
|
||||
"transactionsRoot": "0xb0893d21a4a44dc26a962a6e91abae66df87fb61ac9c60e936aee89c76331445"
|
||||
|
|
@ -1635,16 +1634,16 @@ func TestRPCGetBlockOrHeader(t *testing.T) {
|
|||
"extraData": "0x",
|
||||
"gasLimit": "0x47e7c4",
|
||||
"gasUsed": "0x5208",
|
||||
"hash": "0x0da274b315de8e4d5bf8717218ec43540464ef36378cb896469bb731e1d3f3cb",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
|
||||
"hash": "0xc2050a588d6c8a355ad62275fa97132b7becc03f7626ddd2b17d49a0ae62beb7",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000808000000000000000000000000000000000000000000000000000000000800000000000000000000100000020000000000000000000000000000000000802000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000800000000000000000000000800000108000000000000000000000000000000000000000000000000020000000000000000000100000",
|
||||
"miner": "0x0000000000000000000000000000000000000000",
|
||||
"mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
|
||||
"nonce": "0x0000000000000000",
|
||||
"number": "0x1",
|
||||
"parentHash": "0xbdc7d83b8f876938810462fe8d053263a482e44201e3883d4ae204ff4de7eff5",
|
||||
"receiptsRoot": "0x056b23fbba480696b65fe5a59b8f2148a1299103c4f57df839233af2cf4ca2d2",
|
||||
"receiptsRoot": "0x3794d9c550fc8ed2060bff730acc48524aaa4b87b272c43e034b100d3da4f1b8",
|
||||
"sha3Uncles": "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
|
||||
"stateRoot": "0x92c5c55a698963f5b06e3aee415630f5c48b0760e537af94917ce9c4f42a2e22",
|
||||
"stateRoot": "0x00337febf454e9e7c16ac80678d5408a674e3b7404ecccaaffceec6cf2d803fa",
|
||||
"timestamp": "0xa",
|
||||
"totalDifficulty": "0x1",
|
||||
"transactionsRoot": "0xca0ebcce920d2cdfbf9e1dbe90ed3441a1a576f344bd80e60508da814916f4e7"
|
||||
|
|
@ -1660,16 +1659,16 @@ func TestRPCGetBlockOrHeader(t *testing.T) {
|
|||
"extraData": "0x",
|
||||
"gasLimit": "0x47e7c4",
|
||||
"gasUsed": "0x5208",
|
||||
"hash": "0xda97ed946e0d502fb898b0ac881bd44da3c7fee5eaf184431e1ec3d361dad17e",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
|
||||
"hash": "0xf72973d179c425bcc46a56d1f90fc9ae036e09895bc732d238ecc776ad513671",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000808000000000000000000000000000000000000000000000000000000000800000000000000000000100000020000000000000000000000000000000000802000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000800000000000000000000000800000108000000000000000000000000000000000000000000000000020000000000000000000100000",
|
||||
"miner": "0x0000000000000000000000000000000000000000",
|
||||
"mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
|
||||
"nonce": "0x0000000000000000",
|
||||
"number": "0x9",
|
||||
"parentHash": "0x5abd19c39d9f1c6e52998e135ea14e1fbc5db3fa2a108f4538e238ca5c2e68d7",
|
||||
"receiptsRoot": "0x056b23fbba480696b65fe5a59b8f2148a1299103c4f57df839233af2cf4ca2d2",
|
||||
"parentHash": "0x6f572ecb5694ea18c1ba005c40708a66d495e682d6780ee74d3fd3d5ea8bc4be",
|
||||
"receiptsRoot": "0xfd13763f8f5b1115449da3a892d7208f551b15bceda5509b1d6aa35d65a9a2ed",
|
||||
"sha3Uncles": "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
|
||||
"stateRoot": "0xbd4aa2c2873df709151075250a8c01c9a14d2b0e2f715dbdd16e0ef8030c2cf0",
|
||||
"stateRoot": "0x93818d689d9a3d71eddc80c3687bcbb1f45c8204d52614e1377921d389c62249",
|
||||
"timestamp": "0x5a",
|
||||
"totalDifficulty": "0x1",
|
||||
"transactionsRoot": "0x0767ed8359337dc6a8fdc77fe52db611bed1be87aac73c4556b1bf1dd3d190a5"
|
||||
|
|
@ -1696,17 +1695,17 @@ func TestRPCGetBlockOrHeader(t *testing.T) {
|
|||
"extraData": "0x",
|
||||
"gasLimit": "0x47e7c4",
|
||||
"gasUsed": "0x5208",
|
||||
"hash": "0x97f540a3577c0f645c5dada5da86f38350e8f847e71f21124f917835003e2607",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
|
||||
"hash": "0x872ee27d64627520cf93483c9b43d6710a33814ad56b42cb6a3f318a67ae3d4b",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000808000000000000000000000000000000000000000000000000000000000800000000000000000000100000020000000000000000000000000000000000802000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000800000000000000000000000800000108000000000000000000000000000000000000000000000000020000000000000000000100000",
|
||||
"miner": "0x0000000000000000000000000000000000000000",
|
||||
"mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
|
||||
"nonce": "0x0000000000000000",
|
||||
"number": "0xa",
|
||||
"parentHash": "0xda97ed946e0d502fb898b0ac881bd44da3c7fee5eaf184431e1ec3d361dad17e",
|
||||
"receiptsRoot": "0x056b23fbba480696b65fe5a59b8f2148a1299103c4f57df839233af2cf4ca2d2",
|
||||
"parentHash": "0xf72973d179c425bcc46a56d1f90fc9ae036e09895bc732d238ecc776ad513671",
|
||||
"receiptsRoot": "0xaa293d21b2dd99a4fafcba16c6ad824b09ec42a927c68456bc8209a76bc3e433",
|
||||
"sha3Uncles": "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
|
||||
"size": "0x26a",
|
||||
"stateRoot": "0xbb62872e4023fa8a8b17b9cc37031f4817d9595779748d01cba408b495707a91",
|
||||
"stateRoot": "0x1776127ce43163b6a16fc9d03b1f90f097768d3175c98ff38ccaf6e22b51dc31",
|
||||
"timestamp": "0x64",
|
||||
"totalDifficulty": "0x1",
|
||||
"transactions": [
|
||||
|
|
@ -1752,17 +1751,17 @@ func TestRPCGetBlockOrHeader(t *testing.T) {
|
|||
"extraData": "0x",
|
||||
"gasLimit": "0x47e7c4",
|
||||
"gasUsed": "0x5208",
|
||||
"hash": "0x0da274b315de8e4d5bf8717218ec43540464ef36378cb896469bb731e1d3f3cb",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
|
||||
"hash": "0xc2050a588d6c8a355ad62275fa97132b7becc03f7626ddd2b17d49a0ae62beb7",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000808000000000000000000000000000000000000000000000000000000000800000000000000000000100000020000000000000000000000000000000000802000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000800000000000000000000000800000108000000000000000000000000000000000000000000000000020000000000000000000100000",
|
||||
"miner": "0x0000000000000000000000000000000000000000",
|
||||
"mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
|
||||
"nonce": "0x0000000000000000",
|
||||
"number": "0x1",
|
||||
"parentHash": "0xbdc7d83b8f876938810462fe8d053263a482e44201e3883d4ae204ff4de7eff5",
|
||||
"receiptsRoot": "0x056b23fbba480696b65fe5a59b8f2148a1299103c4f57df839233af2cf4ca2d2",
|
||||
"receiptsRoot": "0x3794d9c550fc8ed2060bff730acc48524aaa4b87b272c43e034b100d3da4f1b8",
|
||||
"sha3Uncles": "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
|
||||
"size": "0x26a",
|
||||
"stateRoot": "0x92c5c55a698963f5b06e3aee415630f5c48b0760e537af94917ce9c4f42a2e22",
|
||||
"stateRoot": "0x00337febf454e9e7c16ac80678d5408a674e3b7404ecccaaffceec6cf2d803fa",
|
||||
"timestamp": "0xa",
|
||||
"totalDifficulty": "0x1",
|
||||
"transactions": [
|
||||
|
|
@ -1782,22 +1781,22 @@ func TestRPCGetBlockOrHeader(t *testing.T) {
|
|||
"extraData": "0x",
|
||||
"gasLimit": "0x47e7c4",
|
||||
"gasUsed": "0x5208",
|
||||
"hash": "0xda97ed946e0d502fb898b0ac881bd44da3c7fee5eaf184431e1ec3d361dad17e",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
|
||||
"hash": "0xf72973d179c425bcc46a56d1f90fc9ae036e09895bc732d238ecc776ad513671",
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000808000000000000000000000000000000000000000000000000000000000800000000000000000000100000020000000000000000000000000000000000802000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000800000000000000000000000800000108000000000000000000000000000000000000000000000000020000000000000000000100000",
|
||||
"miner": "0x0000000000000000000000000000000000000000",
|
||||
"mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
|
||||
"nonce": "0x0000000000000000",
|
||||
"number": "0x9",
|
||||
"parentHash": "0x5abd19c39d9f1c6e52998e135ea14e1fbc5db3fa2a108f4538e238ca5c2e68d7",
|
||||
"receiptsRoot": "0x056b23fbba480696b65fe5a59b8f2148a1299103c4f57df839233af2cf4ca2d2",
|
||||
"parentHash": "0x6f572ecb5694ea18c1ba005c40708a66d495e682d6780ee74d3fd3d5ea8bc4be",
|
||||
"receiptsRoot": "0xfd13763f8f5b1115449da3a892d7208f551b15bceda5509b1d6aa35d65a9a2ed",
|
||||
"sha3Uncles": "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
|
||||
"size": "0x26a",
|
||||
"stateRoot": "0xbd4aa2c2873df709151075250a8c01c9a14d2b0e2f715dbdd16e0ef8030c2cf0",
|
||||
"stateRoot": "0x93818d689d9a3d71eddc80c3687bcbb1f45c8204d52614e1377921d389c62249",
|
||||
"timestamp": "0x5a",
|
||||
"totalDifficulty": "0x1",
|
||||
"transactions": [
|
||||
{
|
||||
"blockHash": "0xda97ed946e0d502fb898b0ac881bd44da3c7fee5eaf184431e1ec3d361dad17e",
|
||||
"blockHash": "0xf72973d179c425bcc46a56d1f90fc9ae036e09895bc732d238ecc776ad513671",
|
||||
"blockNumber": "0x9",
|
||||
"from": "0x703c4b2bd70c169f5717101caee543299fc946c7",
|
||||
"gas": "0x5208",
|
||||
|
|
@ -1881,8 +1880,6 @@ func TestRPCGetBlockOrHeader(t *testing.T) {
|
|||
|
||||
func TestRPCGetTransactionReceipt(t *testing.T) {
|
||||
t.Parallel()
|
||||
// TODO - Arpit Fix hashes
|
||||
t.Skip()
|
||||
|
||||
// Initialize test accounts
|
||||
var (
|
||||
|
|
@ -1972,15 +1969,32 @@ func TestRPCGetTransactionReceipt(t *testing.T) {
|
|||
{
|
||||
txHash: txHashes[0],
|
||||
want: `{
|
||||
"blockHash": "0x1356e49a24d4504e450b303aa770f4ae13c29b9ffacaea1d7dd4043396229dd9",
|
||||
"blockHash": "0x15175c01ed33eee8fbfd1a053a5781ba64acb0cffd5aabc8df0c6cd795e5b68c",
|
||||
"blockNumber": "0x1",
|
||||
"contractAddress": null,
|
||||
"cumulativeGasUsed": "0x5208",
|
||||
"effectiveGasPrice": "0x342770c0",
|
||||
"from": "0x703c4b2bd70c169f5717101caee543299fc946c7",
|
||||
"gasUsed": "0x5208",
|
||||
"logs": [],
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
|
||||
"logs": [
|
||||
{
|
||||
"address": "0x0000000000000000000000000000000000001010",
|
||||
"topics": [
|
||||
"0xe6497e3ee548a3372136af2fcb0696db31fc6cf20260707645068bd3fe97f3c4",
|
||||
"0x0000000000000000000000000000000000000000000000000000000000001010",
|
||||
"0x000000000000000000000000703c4b2bd70c169f5717101caee543299fc946c7",
|
||||
"0x0000000000000000000000000d3ab14bbad3d99f4203bd7a11acb94882050e7e"
|
||||
],
|
||||
"data": "0x00000000000000000000000000000000000000000000000000000000000003e80000000000000000000000000000000000000000000000000de0a5fd640afa000000000000000000000000000000000000000000000000000de0b6b3a76400000000000000000000000000000000000000000000000000000de0a5fd640af6180000000000000000000000000000000000000000000000000de0b6b3a76403e8",
|
||||
"blockNumber": "0x1",
|
||||
"transactionHash": "0x644a31c354391520d00e95b9affbbb010fc79ac268144ab8e28207f4cf51097e",
|
||||
"transactionIndex": "0x0",
|
||||
"blockHash": "0x15175c01ed33eee8fbfd1a053a5781ba64acb0cffd5aabc8df0c6cd795e5b68c",
|
||||
"logIndex": "0x0",
|
||||
"removed": false
|
||||
}
|
||||
],
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000808000000000000000000000000000000000000000000000000000000000800000000000000000000100000020000000000000000000000000000000000802000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000800000000000000000000000800000108000000000000000000000000000000000000000000000000020000000000000000000100000",
|
||||
"status": "0x1",
|
||||
"to": "0x0d3ab14bbad3d99f4203bd7a11acb94882050e7e",
|
||||
"transactionHash": "0x644a31c354391520d00e95b9affbbb010fc79ac268144ab8e28207f4cf51097e",
|
||||
|
|
@ -1992,7 +2006,7 @@ func TestRPCGetTransactionReceipt(t *testing.T) {
|
|||
{
|
||||
txHash: txHashes[1],
|
||||
want: `{
|
||||
"blockHash": "0x4fc27a4efa7fb8faa04b12b53ec8c8424ab4c21aab1323846365f000e8b4a594",
|
||||
"blockHash": "0x2ee38a63ba02740d7adfe3e71e3a4141796246c03561a0ee62fddb7f686794fa",
|
||||
"blockNumber": "0x2",
|
||||
"contractAddress": "0xae9bea628c4ce503dcfd7e305cab4e29e7476592",
|
||||
"cumulativeGasUsed": "0xcf4e",
|
||||
|
|
@ -2012,7 +2026,7 @@ func TestRPCGetTransactionReceipt(t *testing.T) {
|
|||
{
|
||||
txHash: txHashes[2],
|
||||
want: `{
|
||||
"blockHash": "0x73385c190219326907524b0020ef453ebc450eaa971ebce16f79e2d23e7e8d4d",
|
||||
"blockHash": "0x75cce8ee1112222095374f623fdfbffabbe9f6995065df6245d2884fc89dea21",
|
||||
"blockNumber": "0x3",
|
||||
"contractAddress": null,
|
||||
"cumulativeGasUsed": "0x5e28",
|
||||
|
|
@ -2031,7 +2045,7 @@ func TestRPCGetTransactionReceipt(t *testing.T) {
|
|||
"blockNumber": "0x3",
|
||||
"transactionHash": "0x9dbf43ec9afc8d711932618616471088f66ba4f25fd5c672d97473d02dae967f",
|
||||
"transactionIndex": "0x0",
|
||||
"blockHash": "0x73385c190219326907524b0020ef453ebc450eaa971ebce16f79e2d23e7e8d4d",
|
||||
"blockHash": "0x75cce8ee1112222095374f623fdfbffabbe9f6995065df6245d2884fc89dea21",
|
||||
"logIndex": "0x0",
|
||||
"removed": false
|
||||
}
|
||||
|
|
@ -2048,15 +2062,32 @@ func TestRPCGetTransactionReceipt(t *testing.T) {
|
|||
{
|
||||
txHash: txHashes[3],
|
||||
want: `{
|
||||
"blockHash": "0x77c3f8919590e0e68db4ce74a3da3140ac3e96dd3d078a48db1da4c08b07503d",
|
||||
"blockHash": "0x147086a6eccb1e3a05aa00ab21b7daf63b5f8b2d6b25e9cfbb14663aa0234440",
|
||||
"blockNumber": "0x4",
|
||||
"contractAddress": null,
|
||||
"cumulativeGasUsed": "0x538d",
|
||||
"effectiveGasPrice": "0x2325c3e8",
|
||||
"from": "0x703c4b2bd70c169f5717101caee543299fc946c7",
|
||||
"gasUsed": "0x538d",
|
||||
"logs": [],
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
|
||||
"logs": [
|
||||
{
|
||||
"address": "0x0000000000000000000000000000000000001010",
|
||||
"topics": [
|
||||
"0x4dfe1bbbcf077ddc3e01291eea2d5c70c2b422b415d95645b9adcfd678cb1d63",
|
||||
"0x0000000000000000000000000000000000000000000000000000000000001010",
|
||||
"0x000000000000000000000000703c4b2bd70c169f5717101caee543299fc946c7",
|
||||
"0x0000000000000000000000000000000000000000000000000000000000000000"
|
||||
],
|
||||
"data": "0x0000000000000000000000000000000000000000000000000000000000a32f640000000000000000000000000000000000000000000000000de0723c6f3cc6ca00000000000000000000000000000000000000000000000053444835ec5800000000000000000000000000000000000000000000000000000de0723c6e99976600000000000000000000000000000000000000000000000053444835ecfb2f64",
|
||||
"blockNumber": "0x4",
|
||||
"transactionHash": "0x672e3e39adf23b5656989b7a36e54d54004b1866f53871113bc52e137edb9faf",
|
||||
"transactionIndex": "0x0",
|
||||
"blockHash": "0x147086a6eccb1e3a05aa00ab21b7daf63b5f8b2d6b25e9cfbb14663aa0234440",
|
||||
"logIndex": "0x0",
|
||||
"removed": false
|
||||
}
|
||||
],
|
||||
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000800000000000000000000100000020000000000000020000000000000000000800000000000000000080000000000000000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000004000000000000000000001800000000000000000000000000000100000000020000000000000000000000000000000000000000020000000000000000000100000",
|
||||
"status": "0x0",
|
||||
"to": "0x0000000000000000000000000000000000031ec7",
|
||||
"transactionHash": "0x672e3e39adf23b5656989b7a36e54d54004b1866f53871113bc52e137edb9faf",
|
||||
|
|
@ -2068,7 +2099,7 @@ func TestRPCGetTransactionReceipt(t *testing.T) {
|
|||
{
|
||||
txHash: txHashes[4],
|
||||
want: `{
|
||||
"blockHash": "0x08e23d8e3711a21fbb8becd7de22fda8fb0a49fba14e1be763d00f99063627e1",
|
||||
"blockHash": "0x870b06306bdf507c3fcd8ddda890f7dd95c7b55d3246d61661be03dcf7c58648",
|
||||
"blockNumber": "0x5",
|
||||
"contractAddress": "0xfdaa97661a584d977b4d3abb5370766ff5b86a18",
|
||||
"cumulativeGasUsed": "0xe01a",
|
||||
|
|
|
|||
|
|
@ -143,33 +143,6 @@ func testGenerateBlockAndImport(t *testing.T, isClique bool, isBor bool) {
|
|||
}
|
||||
}
|
||||
|
||||
// func (b *testWorkerBackend) newRandomUncle() (*types.Block, error) {
|
||||
// var parent *types.Block
|
||||
|
||||
// cur := b.chain.CurrentBlock()
|
||||
|
||||
// if cur.Number.Uint64() == 0 {
|
||||
// parent = b.chain.Genesis()
|
||||
// } else {
|
||||
// parent = b.chain.GetBlockByHash(b.chain.CurrentBlock().ParentHash)
|
||||
// }
|
||||
|
||||
// var err error
|
||||
|
||||
// blocks, _ := core.GenerateChain(b.chain.Config(), parent, b.chain.Engine(), b.DB, 1, func(i int, gen *core.BlockGen) {
|
||||
// var addr = make([]byte, common.AddressLength)
|
||||
|
||||
// _, err = rand.Read(addr)
|
||||
// if err != nil {
|
||||
// return
|
||||
// }
|
||||
|
||||
// gen.SetCoinbase(common.BytesToAddress(addr))
|
||||
// })
|
||||
|
||||
// return blocks[0], err
|
||||
// }
|
||||
|
||||
const (
|
||||
// testCode is the testing contract binary code which will initialises some
|
||||
// variables in constructor
|
||||
|
|
@ -715,8 +688,6 @@ func testGetSealingWork(t *testing.T, chainConfig *params.ChainConfig, engine co
|
|||
// nolint : paralleltest
|
||||
// TestCommitInterruptExperimentBor tests the commit interrupt experiment for bor consensus by inducing an artificial delay at transaction level.
|
||||
func TestCommitInterruptExperimentBor(t *testing.T) {
|
||||
// TODO - Arpit, Failing
|
||||
t.Skip()
|
||||
// with 1 sec block time and 200 millisec tx delay we should get 5 txs per block
|
||||
testCommitInterruptExperimentBor(t, 200, 5, 0)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue