From 618d724dacee94b702e0ecc970661b45e8f7a35f Mon Sep 17 00:00:00 2001 From: CJentzsch Date: Wed, 4 Mar 2015 15:28:43 +0100 Subject: update state tests --- StateTests/stRefundTest.json | 260 +++++++++++++++++++++++++++------ StateTests/stSolidityTest.json | 63 -------- StateTests/stSystemOperationsTest.json | 155 ++++++++++++++++++++ 3 files changed, 374 insertions(+), 104 deletions(-) (limited to 'StateTests') diff --git a/StateTests/stRefundTest.json b/StateTests/stRefundTest.json index 0b1c16bbc..5fc858640 100644 --- a/StateTests/stRefundTest.json +++ b/StateTests/stRefundTest.json @@ -1,45 +1,4 @@ { - "RefundOverflow" : { - "env" : { - "currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba", - "currentDifficulty" : "45678256", - "currentGasLimit" : "115792089237316195423570985008687907853269984665640564039457584007913129639935", - "currentNumber" : "0", - "currentTimestamp" : 1, - "previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6" - }, - "logs" : [ - ], - "out" : "0x", - "post" : { - "a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : { - "balance" : "400", - "code" : "0x", - "nonce" : "0", - "storage" : { - } - } - }, - "postStateRoot" : "50e4efc6066e4158974b1cd159d914e8eda2978d3395f0027146f4a6bb014924", - "pre" : { - "a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : { - "balance" : "400", - "code" : "0x", - "nonce" : "0", - "storage" : { - } - } - }, - "transaction" : { - "data" : "", - "gasLimit" : "5789604461865809771178549250434395392663499233282028201972879200395656482016", - "gasPrice" : "20", - "nonce" : "0", - "secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8", - "to" : "b94f5374fce5edbc8e2a8697c15331677e6ebf0b", - "value" : "" - } - }, "refund500" : { "env" : { "currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba", @@ -304,6 +263,225 @@ "value" : "0" } }, + "refund_CallA" : { + "env" : { + "currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba", + "currentDifficulty" : "256", + "currentGasLimit" : "1000000", + "currentNumber" : "0", + "currentTimestamp" : 1, + "previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6" + }, + "logs" : [ + ], + "out" : "0x", + "post" : { + "095e7baea6a6c7c4c2dfeb977efac326af552d87" : { + "balance" : "1000000000000000000", + "code" : "0x6000600060006000600073aaae7baea6a6c7c4c2dfeb977efac326af552aaa6101f4f1600055", + "nonce" : "0", + "storage" : { + "0x01" : "0x01" + } + }, + "a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : { + "balance" : "2000", + "code" : "0x", + "nonce" : "0", + "storage" : { + } + }, + "aaae7baea6a6c7c4c2dfeb977efac326af552aaa" : { + "balance" : "1000000000000000000", + "code" : "0x6000600155", + "nonce" : "0", + "storage" : { + "0x01" : "0x01" + } + } + }, + "postStateRoot" : "d9a50deea9e3a61d3338d683568b6d7f4740625dcbe510918bb59b17d43b2387", + "pre" : { + "095e7baea6a6c7c4c2dfeb977efac326af552d87" : { + "balance" : "1000000000000000000", + "code" : "0x6000600060006000600073aaae7baea6a6c7c4c2dfeb977efac326af552aaa6101f4f1600055", + "nonce" : "0", + "storage" : { + "0x01" : "0x01" + } + }, + "a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : { + "balance" : "2000", + "code" : "0x", + "nonce" : "0", + "storage" : { + } + }, + "aaae7baea6a6c7c4c2dfeb977efac326af552aaa" : { + "balance" : "1000000000000000000", + "code" : "0x6000600155", + "nonce" : "0", + "storage" : { + "0x01" : "0x01" + } + } + }, + "transaction" : { + "data" : "", + "gasLimit" : "1500", + "gasPrice" : "1", + "nonce" : "0", + "secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8", + "to" : "095e7baea6a6c7c4c2dfeb977efac326af552d87", + "value" : "10" + } + }, + "refund_CallA2" : { + "env" : { + "currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba", + "currentDifficulty" : "256", + "currentGasLimit" : "1000000", + "currentNumber" : "0", + "currentTimestamp" : 1, + "previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6" + }, + "logs" : [ + ], + "out" : "0x", + "post" : { + "095e7baea6a6c7c4c2dfeb977efac326af552d87" : { + "balance" : "1000000000000000000", + "code" : "0x6000600060006000600073aaae7baea6a6c7c4c2dfeb977efac326af552aaa6032f1600055", + "nonce" : "0", + "storage" : { + "0x01" : "0x01" + } + }, + "a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : { + "balance" : "1000", + "code" : "0x", + "nonce" : "0", + "storage" : { + } + }, + "aaae7baea6a6c7c4c2dfeb977efac326af552aaa" : { + "balance" : "1000000000000000000", + "code" : "0x6000600155", + "nonce" : "0", + "storage" : { + "0x01" : "0x01" + } + } + }, + "postStateRoot" : "2b1a17e7018ac5dd49ae05c6874fd6c1005a241c5eec68763b55a00292c87ba9", + "pre" : { + "095e7baea6a6c7c4c2dfeb977efac326af552d87" : { + "balance" : "1000000000000000000", + "code" : "0x6000600060006000600073aaae7baea6a6c7c4c2dfeb977efac326af552aaa6032f1600055", + "nonce" : "0", + "storage" : { + "0x01" : "0x01" + } + }, + "a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : { + "balance" : "1000", + "code" : "0x", + "nonce" : "0", + "storage" : { + } + }, + "aaae7baea6a6c7c4c2dfeb977efac326af552aaa" : { + "balance" : "1000000000000000000", + "code" : "0x6000600155", + "nonce" : "0", + "storage" : { + "0x01" : "0x01" + } + } + }, + "transaction" : { + "data" : "", + "gasLimit" : "850", + "gasPrice" : "1", + "nonce" : "0", + "secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8", + "to" : "095e7baea6a6c7c4c2dfeb977efac326af552d87", + "value" : "10" + } + }, + "refund_CallA_OOG" : { + "env" : { + "currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba", + "currentDifficulty" : "256", + "currentGasLimit" : "1000000", + "currentNumber" : "0", + "currentTimestamp" : 1, + "previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6" + }, + "logs" : [ + ], + "out" : "0x", + "post" : { + "095e7baea6a6c7c4c2dfeb977efac326af552d87" : { + "balance" : "1000000000000000000", + "code" : "0x6000600060006000600073aaae7baea6a6c7c4c2dfeb977efac326af552aaa6001f1600055", + "nonce" : "0", + "storage" : { + "0x01" : "0x01" + } + }, + "a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : { + "balance" : "1000", + "code" : "0x", + "nonce" : "0", + "storage" : { + } + }, + "aaae7baea6a6c7c4c2dfeb977efac326af552aaa" : { + "balance" : "1000000000000000000", + "code" : "0x6000600155", + "nonce" : "0", + "storage" : { + "0x01" : "0x01" + } + } + }, + "postStateRoot" : "91f35f1a4bb43ca165845e4b2a313421f2d94e68e70261fb0ca6ce4daea7dc85", + "pre" : { + "095e7baea6a6c7c4c2dfeb977efac326af552d87" : { + "balance" : "1000000000000000000", + "code" : "0x6000600060006000600073aaae7baea6a6c7c4c2dfeb977efac326af552aaa6001f1600055", + "nonce" : "0", + "storage" : { + "0x01" : "0x01" + } + }, + "a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : { + "balance" : "1000", + "code" : "0x", + "nonce" : "0", + "storage" : { + } + }, + "aaae7baea6a6c7c4c2dfeb977efac326af552aaa" : { + "balance" : "1000000000000000000", + "code" : "0x6000600155", + "nonce" : "0", + "storage" : { + "0x01" : "0x01" + } + } + }, + "transaction" : { + "data" : "", + "gasLimit" : "850", + "gasPrice" : "1", + "nonce" : "0", + "secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8", + "to" : "095e7baea6a6c7c4c2dfeb977efac326af552d87", + "value" : "10" + } + }, "refund_NoOOG_1" : { "env" : { "currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba", diff --git a/StateTests/stSolidityTest.json b/StateTests/stSolidityTest.json index 714589073..fe90f7cc6 100644 --- a/StateTests/stSolidityTest.json +++ b/StateTests/stSolidityTest.json @@ -223,69 +223,6 @@ "value" : "1" } }, - "QuadraticComplexity" : { - "env" : { - "currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba", - "currentDifficulty" : "45678256", - "currentGasLimit" : "100000000", - "currentNumber" : "0", - "currentTimestamp" : 1, - "previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6" - }, - "logs" : [ - ], - "out" : "0x", - "post" : { - "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba" : { - "balance" : "3500000", - "code" : "0x", - "nonce" : "0", - "storage" : { - } - }, - "a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : { - "balance" : "6500000", - "code" : "0x60003560e060020a9004806361a4770614601557005b601e6004356024565b60006000f35b60008160008190555073b94f5374fce5edbc8e2a8697c15331677e6ebf0b90505b600082131560bf5780600160a060020a03166000600060007f6a7573740000000000000000000000000000000000000000000000000000000081526004017f63616c6c000000000000000000000000000000000000000000000000000000008152602001600060008560155a03f150506001820391506045565b505056", - "nonce" : "1", - "storage" : { - } - }, - "b94f5374fce5edbc8e2a8697c15331677e6ebf0b" : { - "balance" : "100000", - "code" : "0x60206000600037", - "nonce" : "0", - "storage" : { - } - } - }, - "postStateRoot" : "7d5742aed246f2483ad573d595588c4b032fb2bfd596ebe7e746274925bba18e", - "pre" : { - "a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : { - "balance" : "10000000", - "code" : "0x60003560e060020a9004806361a4770614601557005b601e6004356024565b60006000f35b60008160008190555073b94f5374fce5edbc8e2a8697c15331677e6ebf0b90505b600082131560bf5780600160a060020a03166000600060007f6a7573740000000000000000000000000000000000000000000000000000000081526004017f63616c6c000000000000000000000000000000000000000000000000000000008152602001600060008560155a03f150506001820391506045565b505056", - "nonce" : "0", - "storage" : { - } - }, - "b94f5374fce5edbc8e2a8697c15331677e6ebf0b" : { - "balance" : "100000", - "code" : "0x60206000600037", - "nonce" : "0", - "storage" : { - } - } - }, - "transaction" : { - "//" : "run(int256)", - "data" : "0x61a47706000000000000000000000000000000000000000000000000000000000000c350", - "gasLimit" : "3500000", - "gasPrice" : "1", - "nonce" : "0", - "secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8", - "to" : "a94f5374fce5edbc8e2a8697c15331677e6ebf0b", - "value" : "1" - } - }, "RecursiveCreateContracts" : { "env" : { "currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba", diff --git a/StateTests/stSystemOperationsTest.json b/StateTests/stSystemOperationsTest.json index 41c406214..88fdfe4c6 100644 --- a/StateTests/stSystemOperationsTest.json +++ b/StateTests/stSystemOperationsTest.json @@ -448,6 +448,84 @@ "value" : "100000" } }, + "Call10" : { + "env" : { + "currentCoinbase" : "b94f5374fce5edbc8e2a8697c15331677e6ebf0b", + "currentDifficulty" : "45678256", + "currentGasLimit" : "0xffffffffffffffffffffffffffffffff", + "currentNumber" : "0", + "currentTimestamp" : 1, + "previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6" + }, + "logs" : [ + ], + "out" : "0x", + "post" : { + "a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : { + "balance" : "340282366920938463463374607431768027726", + "code" : "0x", + "nonce" : "1", + "storage" : { + } + }, + "aaaf5374fce5edbc8e2a8697c15331677e6ebf0b" : { + "balance" : "7010", + "code" : "0x", + "nonce" : "0", + "storage" : { + } + }, + "b94f5374fce5edbc8e2a8697c15331677e6ebf0b" : { + "balance" : "183719", + "code" : "0x", + "nonce" : "0", + "storage" : { + } + }, + "bbbf5374fce5edbc8e2a8697c15331677e6ebf0b" : { + "balance" : "1000", + "code" : "0x5b600a60805110156042576000600061c3506000600173aaaf5374fce5edbc8e2a8697c15331677e6ebf0b650ffffffffffff16000556001608051016080526000565b608051600155", + "nonce" : "0", + "storage" : { + "0x" : "0x01", + "0x01" : "0x0a" + } + } + }, + "postStateRoot" : "19466b703b0b113fbbf2bb7a64bb86c8b79184d23c92030326c67b7c11cb14f3", + "pre" : { + "a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : { + "balance" : "340282366920938463463374607431768211455", + "code" : "0x", + "nonce" : "0", + "storage" : { + } + }, + "aaaf5374fce5edbc8e2a8697c15331677e6ebf0b" : { + "balance" : "7000", + "code" : "0x", + "nonce" : "0", + "storage" : { + } + }, + "bbbf5374fce5edbc8e2a8697c15331677e6ebf0b" : { + "balance" : "1000", + "code" : "0x5b600a60805110156042576000600061c3506000600173aaaf5374fce5edbc8e2a8697c15331677e6ebf0b650ffffffffffff16000556001608051016080526000565b608051600155", + "nonce" : "0", + "storage" : { + } + } + }, + "transaction" : { + "data" : "", + "gasLimit" : "0xffffffffffffffffffffffffffffff", + "gasPrice" : "1", + "nonce" : "", + "secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8", + "to" : "bbbf5374fce5edbc8e2a8697c15331677e6ebf0b", + "value" : "10" + } + }, "CallRecursiveBomb0" : { "env" : { "currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba", @@ -1892,6 +1970,83 @@ "value" : "100000" } }, + "CreateHashCollision" : { + "env" : { + "currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba", + "currentDifficulty" : "256", + "currentGasLimit" : "10000000", + "currentNumber" : "0", + "currentTimestamp" : 1, + "previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6" + }, + "logs" : [ + ], + "out" : "0x", + "post" : { + "095e7baea6a6c7c4c2dfeb977efac326af552d87" : { + "balance" : "1000000000000099977", + "code" : "0x7c601080600c6000396000f3006000355415600957005b60203560003555600052601d60036017f0600055", + "nonce" : "1", + "storage" : { + "0x" : "0xd2571607e241ecf590ed94b12d87c94babe36db6" + } + }, + "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba" : { + "balance" : "76248", + "code" : "0x", + "nonce" : "0", + "storage" : { + } + }, + "a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : { + "balance" : "999999999999823752", + "code" : "0x", + "nonce" : "1", + "storage" : { + } + }, + "d2571607e241ecf590ed94b12d87c94babe36db6" : { + "balance" : "65", + "code" : "0x6000355415600957005b602035600035", + "nonce" : "0", + "storage" : { + } + } + }, + "postStateRoot" : "9ad1ffb51fe6f7a2dca6fd17ab366990af3f875137c82d2dc64ff6e8b1b9161e", + "pre" : { + "095e7baea6a6c7c4c2dfeb977efac326af552d87" : { + "balance" : "1000000000000000000", + "code" : "0x7c601080600c6000396000f3006000355415600957005b60203560003555600052601d60036017f0600055", + "nonce" : "0", + "storage" : { + } + }, + "a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : { + "balance" : "1000000000000000000", + "code" : "0x", + "nonce" : "0", + "storage" : { + } + }, + "d2571607e241ecf590ed94b12d87c94babe36db6" : { + "balance" : "42", + "code" : "0x60016001016055", + "nonce" : "0", + "storage" : { + } + } + }, + "transaction" : { + "data" : "", + "gasLimit" : "10000000", + "gasPrice" : "1", + "nonce" : "0", + "secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8", + "to" : "095e7baea6a6c7c4c2dfeb977efac326af552d87", + "value" : "100000" + } + }, "PostToReturn1" : { "env" : { "currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba", -- cgit