mirror of https://github.com/status-im/web3.js.git
fixed coverage issue
This commit is contained in:
parent
d51e9a2f30
commit
0e3b29c7c2
|
@ -213,7 +213,7 @@ var fromDecimal = function (value) {
|
|||
* @return {String}
|
||||
*/
|
||||
var toHex = function (val) {
|
||||
/*jshint maxcomplexity:7 */
|
||||
/*jshint maxcomplexity: 8 */
|
||||
|
||||
if (isBoolean(val))
|
||||
return fromDecimal(+val);
|
||||
|
|
|
@ -14,6 +14,7 @@ var tests = [
|
|||
{ value: '-0x1', expected: '-0x1'},
|
||||
{ value: '-15', expected: '-0xf'},
|
||||
{ value: '-0xf', expected: '-0xf'},
|
||||
{ value: '0x657468657265756d', expected: '0x657468657265756d'},
|
||||
{ value: '0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd', expected: '0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd'},
|
||||
{ value: '-0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff', expected: '-0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff'},
|
||||
{ value: '-0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd', expected: '-0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd'},
|
||||
|
|
Loading…
Reference in New Issue