Skip to content

Commit 0b06590

Browse files
authored
graphql: consistent rule for Long outputs and args (#746)
1 parent 9c4e6fd commit 0b06590

21 files changed

+130
-76
lines changed

simulators/ethereum/graphql/testcases/01_eth_blockNumber.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55
"responses": [{
66
"data" : {
77
"block" : {
8-
"number" : 32
8+
"number" : "0x20"
99
}
1010
}
1111
}],
1212
"statusCode": 200
13-
}
13+
}

simulators/ethereum/graphql/testcases/02_eth_call_Block8.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@
44
"responses":[{
55
"data" : {
66
"block" : {
7-
"number" : 8,
7+
"number" : "0x8",
88
"call" : {
99
"data" : "0x0000000000000000000000000000000000000000000000000000000000000000",
10-
"status" : 1
10+
"status" : "0x1"
1111
}
1212
}
1313
}
1414
}],
1515
"statusCode": 200
16-
}
16+
}

simulators/ethereum/graphql/testcases/03_eth_call_BlockLatest.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@
44
"responses":[{
55
"data" : {
66
"block" : {
7-
"number" : 32,
7+
"number" : "0x20",
88
"call" : {
99
"data" : "0x0000000000000000000000000000000000000000000000000000000000000001",
10-
"status" : 1
10+
"status" : "0x1"
1111
}
1212
}
1313
}
1414
}],
1515
"statusCode": 200
16-
}
16+
}

simulators/ethereum/graphql/testcases/04_eth_estimateGas_contractDeploy.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@
33
"responses":[{
44
"data" : {
55
"block" : {
6-
"estimateGas" : 111953
6+
"estimateGas" : "0x1b551"
77
}
88
}
99
}],
1010
"statusCode": 200
11-
}
11+
}

simulators/ethereum/graphql/testcases/05_eth_estimateGas_noParams.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@
33
"responses":[{
44
"data" : {
55
"block" : {
6-
"estimateGas" : 21000
6+
"estimateGas" : "0x5208"
77
}
88
}
99
}],
1010
"statusCode": 200
11-
}
11+
}

simulators/ethereum/graphql/testcases/06_eth_estimateGas_transfer.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@
33
"responses":[{
44
"data" : {
55
"block" : {
6-
"estimateGas" : 21000
6+
"estimateGas" : "0x5208"
77
}
88
}
99
}],
1010
"statusCode": 200
11-
}
11+
}

simulators/ethereum/graphql/testcases/14_eth_getBlock_byHash.json

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -7,28 +7,28 @@
77
"responses": [{
88
"data" : {
99
"block" : {
10-
"number" : 30,
10+
"number" : "0x1e",
1111
"transactions" : [ {
1212
"hash" : "0x9cc6c7e602c56aa30c554bb691377f8703d778cec8845f4b88c0f72516b304f4"
1313
} ],
14-
"timestamp" : 1444660022,
14+
"timestamp" : "0x561bc336",
1515
"difficulty" : "0x20740",
1616
"totalDifficulty" : "0x3e6cc0",
17-
"gasUsed" : 23585,
18-
"gasLimit" : 3141592,
17+
"gasUsed" : "0x5c21",
18+
"gasLimit" : "0x2fefd8",
1919
"hash" : "0xc8df1f061abb4d0c107b2b1a794ade8780b3120e681f723fe55a7be586d95ba6",
2020
"nonce" : "0x5c321bd9e9f040f1",
21-
"ommerCount" : 0,
21+
"ommerCount" : "0x0",
2222
"logsBloom" : "0x00000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000080000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000400000000000000000200000000000000000002000000000000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000800000000040000000000000000000000000000000000000000010000000000000000000000000",
2323
"mixHash" : "0x6ce1c4afb4f85fefd1b0ed966b20cd248f08d9a5b0df773f75c6c2f5cc237b7c",
2424
"ommerHash" : "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
2525
"extraData" : "0x",
2626
"stateRoot" : "0xdb46d6bb168130fe2cb60b4b24346137b5741f11283e0d7edace65c5f5466b2e",
2727
"receiptsRoot" : "0x88b3b304b058b39791c26fdb94a05cc16ce67cf8f84f7348cb3c60c0ff342d0d",
28-
"transactionCount" : 1,
28+
"transactionCount" : "0x1",
2929
"transactionsRoot" : "0x5a8d5d966b48e1331ae19eb459eb28882cdc7654e615d37774b79204e875dc01"
3030
}
3131
}
3232
}],
3333
"statusCode": 200
34-
}
34+
}

simulators/ethereum/graphql/testcases/16_eth_getBlock_byNumber.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,21 +10,21 @@
1010
"transactions" : [ {
1111
"hash" : "0x9cc6c7e602c56aa30c554bb691377f8703d778cec8845f4b88c0f72516b304f4"
1212
} ],
13-
"timestamp" : 1444660022,
13+
"timestamp" : "0x561bc336",
1414
"difficulty" : "0x20740",
1515
"totalDifficulty" : "0x3e6cc0",
16-
"gasUsed" : 23585,
17-
"gasLimit" : 3141592,
16+
"gasUsed" : "0x5c21",
17+
"gasLimit" : "0x2fefd8",
1818
"hash" : "0xc8df1f061abb4d0c107b2b1a794ade8780b3120e681f723fe55a7be586d95ba6",
1919
"nonce" : "0x5c321bd9e9f040f1",
20-
"ommerCount" : 0,
20+
"ommerCount" : "0x0",
2121
"logsBloom" : "0x00000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000080000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000400000000000000000200000000000000000002000000000000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000800000000040000000000000000000000000000000000000000010000000000000000000000000",
2222
"mixHash" : "0x6ce1c4afb4f85fefd1b0ed966b20cd248f08d9a5b0df773f75c6c2f5cc237b7c",
2323
"ommerHash" : "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
2424
"extraData" : "0x",
2525
"stateRoot" : "0xdb46d6bb168130fe2cb60b4b24346137b5741f11283e0d7edace65c5f5466b2e",
2626
"receiptsRoot" : "0x88b3b304b058b39791c26fdb94a05cc16ce67cf8f84f7348cb3c60c0ff342d0d",
27-
"transactionCount" : 1,
27+
"transactionCount" : "0x1",
2828
"transactionsRoot" : "0x5a8d5d966b48e1331ae19eb459eb28882cdc7654e615d37774b79204e875dc01",
2929
"ommers" : [ ],
3030
"ommerAt" : null,
@@ -41,4 +41,4 @@
4141
}
4242
}],
4343
"statusCode": 200
44-
}
44+
}

simulators/ethereum/graphql/testcases/19_eth_getBlockTransactionCount_byHash.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"responses": [{
88
"data" : {
99
"block" : {
10-
"transactionCount" : 1
10+
"transactionCount" : "0x1"
1111
}
1212
}
1313
}],

simulators/ethereum/graphql/testcases/20_eth_getBlockTransactionCount_byNumber.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,24 +10,24 @@
1010
"transactions" : [ {
1111
"hash" : "0x9cc6c7e602c56aa30c554bb691377f8703d778cec8845f4b88c0f72516b304f4"
1212
} ],
13-
"timestamp" : 1444660022,
13+
"timestamp" : "0x561bc336",
1414
"difficulty" : "0x20740",
1515
"totalDifficulty" : "0x3e6cc0",
16-
"gasUsed" : 23585,
17-
"gasLimit" : 3141592,
16+
"gasUsed" : "0x5c21",
17+
"gasLimit" : "0x2fefd8",
1818
"hash" : "0xc8df1f061abb4d0c107b2b1a794ade8780b3120e681f723fe55a7be586d95ba6",
1919
"nonce" : "0x5c321bd9e9f040f1",
20-
"ommerCount" : 0,
20+
"ommerCount" : "0x0",
2121
"logsBloom" : "0x00000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000080000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000400000000000000000200000000000000000002000000000000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000800000000040000000000000000000000000000000000000000010000000000000000000000000",
2222
"mixHash" : "0x6ce1c4afb4f85fefd1b0ed966b20cd248f08d9a5b0df773f75c6c2f5cc237b7c",
2323
"ommerHash" : "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
2424
"extraData" : "0x",
2525
"stateRoot" : "0xdb46d6bb168130fe2cb60b4b24346137b5741f11283e0d7edace65c5f5466b2e",
2626
"receiptsRoot" : "0x88b3b304b058b39791c26fdb94a05cc16ce67cf8f84f7348cb3c60c0ff342d0d",
27-
"transactionCount" : 1,
27+
"transactionCount" : "0x1",
2828
"transactionsRoot" : "0x5a8d5d966b48e1331ae19eb459eb28882cdc7654e615d37774b79204e875dc01"
2929
}
3030
}
3131
}],
3232
"statusCode": 200
33-
}
33+
}

0 commit comments

Comments
 (0)