aboutsummaryrefslogtreecommitdiffstats
path: root/test/libsolidity/StandardCompiler.cpp
diff options
context:
space:
mode:
authorchriseth <chris@ethereum.org>2018-01-05 00:08:47 +0800
committerchriseth <chris@ethereum.org>2018-04-12 19:09:38 +0800
commit42c4c78390b6330e8bc4558b4be5d580251abcba (patch)
treecb4fcdee2c40a7623b13ffba16d415129fbe7282 /test/libsolidity/StandardCompiler.cpp
parent167ee2fcbb1000e6387142892c4252f8597a4481 (diff)
downloaddexon-solidity-42c4c78390b6330e8bc4558b4be5d580251abcba.tar.gz
dexon-solidity-42c4c78390b6330e8bc4558b4be5d580251abcba.tar.zst
dexon-solidity-42c4c78390b6330e8bc4558b4be5d580251abcba.zip
Adjust tests.
Diffstat (limited to 'test/libsolidity/StandardCompiler.cpp')
-rw-r--r--test/libsolidity/StandardCompiler.cpp19
1 files changed, 12 insertions, 7 deletions
diff --git a/test/libsolidity/StandardCompiler.cpp b/test/libsolidity/StandardCompiler.cpp
index b285a2a0..74bf01b2 100644
--- a/test/libsolidity/StandardCompiler.cpp
+++ b/test/libsolidity/StandardCompiler.cpp
@@ -261,19 +261,24 @@ BOOST_AUTO_TEST_CASE(basic_compilation)
BOOST_CHECK(contract["evm"]["bytecode"]["object"].isString());
BOOST_CHECK_EQUAL(
dev::test::bytecodeSansMetadata(contract["evm"]["bytecode"]["object"].asString()),
- "60806040523415600e57600080fd5b603580601b6000396000f3006080604052600080fd00"
+ "6080604052348015600f57600080fd5b50603580601d6000396000f3006080604052600080fd00"
);
BOOST_CHECK(contract["evm"]["assembly"].isString());
BOOST_CHECK(contract["evm"]["assembly"].asString().find(
- " /* \"fileA\":0:14 contract A { } */\n mstore(0x40, 0x80)\n jumpi(tag_1, iszero(callvalue))\n"
- " 0x0\n dup1\n revert\ntag_1:\n dataSize(sub_0)\n dup1\n dataOffset(sub_0)\n 0x0\n codecopy\n 0x0\n"
- " return\nstop\n\nsub_0: assembly {\n /* \"fileA\":0:14 contract A { } */\n"
- " mstore(0x40, 0x80)\n 0x0\n dup1\n revert\n\n"
- " auxdata: 0xa165627a7a7230582") == 0);
+ " /* \"fileA\":0:14 contract A { } */\n mstore(0x40, 0x80)\n "
+ "callvalue\n /* \"--CODEGEN--\":8:17 */\n dup1\n "
+ "/* \"--CODEGEN--\":5:7 */\n iszero\n tag_1\n jumpi\n "
+ "/* \"--CODEGEN--\":30:31 */\n 0x0\n /* \"--CODEGEN--\":27:28 */\n "
+ "dup1\n /* \"--CODEGEN--\":20:32 */\n revert\n /* \"--CODEGEN--\":5:7 */\n"
+ "tag_1:\n /* \"fileA\":0:14 contract A { } */\n pop\n dataSize(sub_0)\n dup1\n "
+ "dataOffset(sub_0)\n 0x0\n codecopy\n 0x0\n return\nstop\n\nsub_0: assembly {\n "
+ "/* \"fileA\":0:14 contract A { } */\n mstore(0x40, 0x80)\n 0x0\n "
+ "dup1\n revert\n\n auxdata: 0xa165627a7a72305820"
+ ) == 0);
BOOST_CHECK(contract["evm"]["gasEstimates"].isObject());
BOOST_CHECK_EQUAL(
dev::jsonCompactPrint(contract["evm"]["gasEstimates"]),
- "{\"creation\":{\"codeDepositCost\":\"10600\",\"executionCost\":\"61\",\"totalCost\":\"10661\"}}"
+ "{\"creation\":{\"codeDepositCost\":\"10600\",\"executionCost\":\"66\",\"totalCost\":\"10666\"}}"
);
BOOST_CHECK(contract["metadata"].isString());
BOOST_CHECK(dev::test::isValidMetadata(contract["metadata"].asString()));