diff options
-rw-r--r-- | SolidityEndToEndTest.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/SolidityEndToEndTest.cpp b/SolidityEndToEndTest.cpp index 1b7f4129..ee9c1f69 100644 --- a/SolidityEndToEndTest.cpp +++ b/SolidityEndToEndTest.cpp @@ -970,8 +970,8 @@ BOOST_AUTO_TEST_CASE(array_accessor) { char const* sourceCode = R"( contract test { - uint[8] data; - uint[] dynamicData; + uint[8] public data; + uint[] public dynamicData; function test() { data[2] = 8; dynamicData.length = 3; @@ -980,6 +980,7 @@ BOOST_AUTO_TEST_CASE(array_accessor) } )"; compileAndRun(sourceCode); + auto res = callContractFunction("data(uint256)", 2) ; BOOST_CHECK(callContractFunction("data(uint256)", 2) == encodeArgs(8)); BOOST_CHECK(callContractFunction("data(uint256)", 8) == encodeArgs()); BOOST_CHECK(callContractFunction("dynamicData(uint256)", 2) == encodeArgs(8)); @@ -990,8 +991,8 @@ BOOST_AUTO_TEST_CASE(accessors_mapping_for_array) { char const* sourceCode = R"( contract test { - mapping(uint => uint[8]) data; - mapping(uint => uint[]) dynamicData; + mapping(uint => uint[8]) public data; + mapping(uint => uint[]) public dynamicData; function test() { data[2][2] = 8; dynamicData[2].length = 3; |