From 075715cf151669058251c78b47c0b94fc913e74a Mon Sep 17 00:00:00 2001 From: Alex Beregszaszi Date: Tue, 18 Jul 2017 14:34:22 +0100 Subject: Do not use obscure CompilerStack methods in tests --- test/libsolidity/SolidityNatspecJSON.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'test/libsolidity/SolidityNatspecJSON.cpp') diff --git a/test/libsolidity/SolidityNatspecJSON.cpp b/test/libsolidity/SolidityNatspecJSON.cpp index 2a7376b9..aa343561 100644 --- a/test/libsolidity/SolidityNatspecJSON.cpp +++ b/test/libsolidity/SolidityNatspecJSON.cpp @@ -45,7 +45,9 @@ public: bool _userDocumentation ) { - ETH_TEST_REQUIRE_NO_THROW(m_compilerStack.parseAndAnalyze("pragma solidity >=0.0;\n" + _code), "Parsing failed"); + m_compilerStack.reset(false); + m_compilerStack.addSource("", "pragma solidity >=0.0;\n" + _code); + ETH_TEST_REQUIRE_NO_THROW(m_compilerStack.parseAndAnalyze(), "Parsing contract failed"); Json::Value generatedDocumentation; if (_userDocumentation) -- cgit v1.2.3