mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Use compileContract in contract tests
This commit is contained in:
parent
029e19983c
commit
0346f72342
@ -220,13 +220,8 @@ protected:
|
||||
void deployRegistrar()
|
||||
{
|
||||
if (!s_compiledRegistrar)
|
||||
{
|
||||
m_compiler.reset(false);
|
||||
m_compiler.addSource("", registrarCode);
|
||||
m_compiler.setOptimiserSettings(m_optimize, m_optimizeRuns);
|
||||
BOOST_REQUIRE_MESSAGE(m_compiler.compile(), "Compiling contract failed");
|
||||
s_compiledRegistrar.reset(new bytes(m_compiler.object("GlobalRegistrar").bytecode));
|
||||
}
|
||||
s_compiledRegistrar.reset(new bytes(compileContract(registrarCode, "GlobalRegistrar")));
|
||||
|
||||
sendMessage(*s_compiledRegistrar, true);
|
||||
BOOST_REQUIRE(!m_output.empty());
|
||||
}
|
||||
|
@ -132,13 +132,8 @@ protected:
|
||||
void deployRegistrar()
|
||||
{
|
||||
if (!s_compiledRegistrar)
|
||||
{
|
||||
m_compiler.reset(false);
|
||||
m_compiler.addSource("", registrarCode);
|
||||
m_compiler.setOptimiserSettings(m_optimize, m_optimizeRuns);
|
||||
BOOST_REQUIRE_MESSAGE(m_compiler.compile(), "Compiling contract failed");
|
||||
s_compiledRegistrar.reset(new bytes(m_compiler.object("FixedFeeRegistrar").bytecode));
|
||||
}
|
||||
s_compiledRegistrar.reset(new bytes(compileContract(registrarCode, "FixedFeeRegistrar")));
|
||||
|
||||
sendMessage(*s_compiledRegistrar, true);
|
||||
BOOST_REQUIRE(!m_output.empty());
|
||||
}
|
||||
|
@ -447,13 +447,8 @@ protected:
|
||||
)
|
||||
{
|
||||
if (!s_compiledWallet)
|
||||
{
|
||||
m_compiler.reset(false);
|
||||
m_compiler.addSource("", walletCode);
|
||||
m_compiler.setOptimiserSettings(m_optimize, m_optimizeRuns);
|
||||
BOOST_REQUIRE_MESSAGE(m_compiler.compile(), "Compiling contract failed");
|
||||
s_compiledWallet.reset(new bytes(m_compiler.object("Wallet").bytecode));
|
||||
}
|
||||
s_compiledWallet.reset(new bytes(compileContract(walletCode, "Wallet")));
|
||||
|
||||
bytes args = encodeArgs(u256(0x60), _required, _dailyLimit, u256(_owners.size()), _owners);
|
||||
sendMessage(*s_compiledWallet + args, true, _value);
|
||||
BOOST_REQUIRE(!m_output.empty());
|
||||
|
Loading…
Reference in New Issue
Block a user