diff options
author | djudjuu <julfaber@gmail.com> | 2017-06-07 21:52:44 +0800 |
---|---|---|
committer | djudjuu <julfaber@gmail.com> | 2017-06-07 21:52:44 +0800 |
commit | 83f0e00900a51c03cc7d8c088bbac0c4814a9e49 (patch) | |
tree | 27f077cdd4b72ca2a9c824516e60f24853dee3d9 /test | |
parent | ebdebc7c12d152bcf9c96274ecf7dea2e46e2541 (diff) | |
download | dexon-solidity-83f0e00900a51c03cc7d8c088bbac0c4814a9e49.tar dexon-solidity-83f0e00900a51c03cc7d8c088bbac0c4814a9e49.tar.gz dexon-solidity-83f0e00900a51c03cc7d8c088bbac0c4814a9e49.tar.bz2 dexon-solidity-83f0e00900a51c03cc7d8c088bbac0c4814a9e49.tar.lz dexon-solidity-83f0e00900a51c03cc7d8c088bbac0c4814a9e49.tar.xz dexon-solidity-83f0e00900a51c03cc7d8c088bbac0c4814a9e49.tar.zst dexon-solidity-83f0e00900a51c03cc7d8c088bbac0c4814a9e49.zip |
tests for non-legacy mode
Diffstat (limited to 'test')
-rw-r--r-- | test/libsolidity/ASTJSON.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/test/libsolidity/ASTJSON.cpp b/test/libsolidity/ASTJSON.cpp index 4476f1ed..e9e00b13 100644 --- a/test/libsolidity/ASTJSON.cpp +++ b/test/libsolidity/ASTJSON.cpp @@ -247,6 +247,14 @@ BOOST_AUTO_TEST_CASE(documentation) Json::Value astJsonB = ASTJsonConverter(true, sourceIndices).toJson(c.ast("b")); Json::Value documentationB = astJsonB["children"][0]["attributes"]["documentation"]; BOOST_CHECK_EQUAL(documentationB, "This contract is empty and has a line-breaking comment."); + //same tests for non-legacy mode + astJsonA = ASTJsonConverter(false, sourceIndices).toJson(c.ast("a")); + documentationA = astJsonA["nodes"][0]["documentation"]; + BOOST_CHECK_EQUAL(documentationA, "This contract is empty"); + astJsonB = ASTJsonConverter(false, sourceIndices).toJson(c.ast("b")); + documentationB = astJsonB["nodes"][0]["documentation"]; + BOOST_CHECK_EQUAL(documentationB, "This contract is empty and has a line-breaking comment."); + } |