aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--TestHelper.cpp7
-rw-r--r--TestHelper.h1
-rw-r--r--libsolidity/solidityExecutionFramework.h2
3 files changed, 6 insertions, 4 deletions
diff --git a/TestHelper.cpp b/TestHelper.cpp
index 476d1ecf..793e0565 100644
--- a/TestHelper.cpp
+++ b/TestHelper.cpp
@@ -328,7 +328,7 @@ void ImportTest::exportTest(bytes const& _output, State const& _statePost)
{
// export output
- m_TestObject["out"] = _output.size() > 4096 ? "#" + toString(_output.size()) : toHex(_output, 2, HexPrefix::Add);
+ m_TestObject["out"] = (_output.size() > 4096 && !Options::get().fulloutput) ? "#" + toString(_output.size()) : toHex(_output, 2, HexPrefix::Add);
// export logs
m_TestObject["logs"] = exportLog(_statePost.pending().size() ? _statePost.log(0) : LogEntries());
@@ -588,7 +588,7 @@ void userDefinedTest(std::function<void(json_spirit::mValue&, bool)> doTests)
oSingleTest[pos->first] = pos->second;
json_spirit::mValue v_singleTest(oSingleTest);
- doTests(v_singleTest, false);
+ doTests(v_singleTest, test::Options::get().fillTests);
}
catch (Exception const& _e)
{
@@ -760,6 +760,8 @@ Options::Options()
else
singleTestName = std::move(name1);
}
+ else if (arg == "--fulloutput")
+ fulloutput = true;
}
}
@@ -769,7 +771,6 @@ Options const& Options::get()
return instance;
}
-
LastHashes lastHashes(u256 _currentBlockNumber)
{
LastHashes ret;
diff --git a/TestHelper.h b/TestHelper.h
index fc6c77fa..8f0c73bf 100644
--- a/TestHelper.h
+++ b/TestHelper.h
@@ -184,6 +184,7 @@ public:
bool stats = false; ///< Execution time stats
std::string statsOutFile; ///< Stats output file. "out" for standard output
bool checkState = false;///< Throw error when checking test states
+ bool fulloutput = false;///< Replace large output to just it's length
/// Test selection
/// @{
diff --git a/libsolidity/solidityExecutionFramework.h b/libsolidity/solidityExecutionFramework.h
index c29257dd..1e11ae90 100644
--- a/libsolidity/solidityExecutionFramework.h
+++ b/libsolidity/solidityExecutionFramework.h
@@ -170,7 +170,7 @@ protected:
else
{
BOOST_REQUIRE(m_state.addressHasCode(m_contractAddress));
- BOOST_REQUIRE(!executive.call(m_contractAddress, m_contractAddress, m_sender, _value, m_gasPrice, &_data, m_gas, m_sender));
+ BOOST_REQUIRE(!executive.call(m_contractAddress, m_sender, _value, m_gasPrice, &_data, m_gas));
}
BOOST_REQUIRE(executive.go());
m_state.noteSending(m_sender);