solidity-test-util
v1.0.8
Published
A collection of utility functions for testing ethereum contracts with truffle framework and testrpc
Downloads
56
Readme
Solidity-test-util
A collection of utility functions for testing ethereum contracts with truffle framework and testrpc.
Examples can be found on Github solidity-test-example project
getEventLog
Parameters
ObjectContract events subscriber, see web3 doc
Returns
ArrayEvents
assertThrow
Parameters
Callbackwith contract method call, that should throw exception
Returns
Booleanexception throwed
evmIncreaseTime
Jump testrpc forward in time
Parameters
Numberamount of time to increase in seconds
Returns
Numbertotal time adjustment, in seconds.
prepareValue
Convert BigNumber value to Number using toNumber() method
Parameters
Mixed
Returns
Mixed
prepareArray
Convert BigNumber array values to Number using toNumber() method
Parameters
Array
Returns
Array
prepareObject
Convert BigNumber object values to Number using toNumber() method
Parameters
Object
Returns
Object
