@ -19,22 +19,27 @@ module.exports = {
. click ( '.instance:nth-of-type(2) > div > button' )
. click ( '#runTabView .instance div[class^="title"]' )
. click ( '#runTabView .instance div[class^="title"]' )
. testFunction ( 'f - transact (not payable)' ,
'0x38bb944fa4709ed9e163d6c670259f97284b4defd916d512a2fcc3f35bb53e03' ,
` [vm] \n from:0xca3...a733c \n to:TestContract.f() 0x692...77b3a \n value:0 wei \n data:0x261...21ff0 \n logs:0 \n hash:0x38b...53e03 ` , null ,
` {
"0" : "uint256: 8"
} ` )
. clickFunction ( 'f - transact (not payable)' )
. testFunction ( '0x38bb944fa4709ed9e163d6c670259f97284b4defd916d512a2fcc3f35bb53e03' ,
{
status : '0x1 Transaction mined and execution succeed' ,
'transaction hash' : '0x38bb944fa4709ed9e163d6c670259f97284b4defd916d512a2fcc3f35bb53e03' ,
'decoded output' : { "0" : "uint256: 8" }
} )
. pause ( 500 )
. checkTerminalFilter ( '0x12332162e2e31397dc1e07ed0a1cf08f728e9b4487c6f9ed79d2f39410c92782' , '' )
. testFunction ( 'g - transact (not payable)' ,
'0xab4f794ca0b531f27fc6eace623666b440facbf20e77615a057d728c67b500f0' ,
` [vm] \n from:0xca3...a733c \n to:TestContract.g() 0x692...77b3a \n value:0 wei \n data:0xe21...79b8e \n logs:0 \n hash:0xab4...500f0 ` , null , ` {
"0" : "uint256: 345" ,
"1" : "string: comment_comment_" ,
"2" : "bool: true" ,
"3" : "uint256: 4"
} ` )
. clickFunction ( 'g - transact (not payable)' )
. testFunction ( '0xab4f794ca0b531f27fc6eace623666b440facbf20e77615a057d728c67b500f0' ,
{
status : '0x1 Transaction mined and execution succeed' ,
'transaction hash' : '0xab4f794ca0b531f27fc6eace623666b440facbf20e77615a057d728c67b500f0' ,
'decoded output' : {
"0" : "uint256: 345" ,
"1" : "string: comment_comment_" ,
"2" : "bool: true" ,
"3" : "uint256: 4"
}
} )
. click ( 'i[class^="clearinstance"]' )
} ,
@ -44,35 +49,46 @@ module.exports = {
. click ( '#runTabView button[class^="instanceButton"]' )
. waitForElementPresent ( '.instance:nth-of-type(2)' )
. click ( '.instance:nth-of-type(2) > div > button' )
. testFunction ( 'retunValues1 - transact (not payable)' ,
'0x09c6716a67f0f8c7a0ca2b3ddf59c25982da856a95aefd640b767f9b9feee39d' ,
` [vm] \n from:0xca3...a733c \n to:testReturnValues.retunValues1() 0x5e7...26e9f \n value:0 wei \n data:0x9ed...59eb7 \n logs:0 \n hash:0x09c...ee39d ` ,
null ,
` {
"0" : "bool: _b true" ,
"1" : "uint256: _u 345" ,
"2" : "int256: _i -345" ,
"3" : "address: _a 0xCA35b7d915458EF540aDe6068dFe2F44E8fa733c"
} ` )
. testFunction ( 'retunValues2 - transact (not payable)' ,
'0xe884953e0695399d60914af3e1ea2dad59fe41f3c0c20665c130fa40dd0fb6bf' ,
` [vm] \n from:0xca3...a733c \n to:testReturnValues.retunValues2() 0x5e7...26e9f \n value:0 wei \n data:0xf57...4036c \n logs:0 \n hash:0xe88...fb6bf ` , null , ` {
"0" : "bytes1: _b 0x12" ,
"1" : "bytes2: _b2 0x1223" ,
"2" : "bytes3: _b3 0x000000" ,
"3" : "bytes: _blit 0x123498" ,
"4" : "bytes5: _b5 0x0432450000" ,
"5" : "bytes6: _b6 0x234553253200" ,
"6" : "string: _str this is a long string _ this is a long string _ this is a long string _ this is a long string _ this is a long string _ this is a long string _ this is a long string _ this is a long string _ this is a long string _ this is a long string _ this is a long string _ this is a long string _ this is a long string _ this is a long string _ this is a long string" ,
"7" : "bytes7: _b7 0x03252353253253" ,
"8" : "bytes22: _b22 0x32523523532532532523532500000000000000000000" ,
"9" : "bytes32: _b32 0x0325235325325235325235325235320000000000000000000000000000000000"
} ` ).pause(500).testFunction('retunValues3 - transact (not payable)',
'0xb4108649d5e65a4a0776d6ac98c2c356540a7e99d641705a82352a845d467eb5' ,
'[vm]\nfrom:0xca3...a733c\nto:testReturnValues.retunValues3() 0x5e7...26e9f\nvalue:0 wei\ndata:0x033...e0a7d\nlogs:0\nhash:0xb41...67eb5' , null , ` {
"0" : "uint8: _en 2" ,
"1" : "int256[5][]: _a1 1,-45,-78,56,60,-1,42,334,-45455,-446,1,10,-5435,45,-7"
} ` ).click('i[class^="clearinstance"]')
. clickFunction ( 'retunValues1 - transact (not payable)' )
. testFunction ( '0x09c6716a67f0f8c7a0ca2b3ddf59c25982da856a95aefd640b767f9b9feee39d' ,
{
status : '0x1 Transaction mined and execution succeed' ,
'transaction hash' : '0x09c6716a67f0f8c7a0ca2b3ddf59c25982da856a95aefd640b767f9b9feee39d' ,
'decoded output' : {
"0" : "bool: _b true" ,
"1" : "uint256: _u 345" ,
"2" : "int256: _i -345" ,
"3" : "address: _a 0xCA35b7d915458EF540aDe6068dFe2F44E8fa733c"
}
} )
. clickFunction ( 'retunValues2 - transact (not payable)' , )
. testFunction ( '0xe884953e0695399d60914af3e1ea2dad59fe41f3c0c20665c130fa40dd0fb6bf' ,
{
status : '0x1 Transaction mined and execution succeed' ,
'transaction hash' : '0xe884953e0695399d60914af3e1ea2dad59fe41f3c0c20665c130fa40dd0fb6bf' ,
'decoded output' : {
"0" : "bytes1: _b 0x12" ,
"1" : "bytes2: _b2 0x1223" ,
"2" : "bytes3: _b3 0x000000" ,
"3" : "bytes: _blit 0x123498" ,
"4" : "bytes5: _b5 0x0432450000" ,
"5" : "bytes6: _b6 0x234553253200" ,
"6" : "string: _str this is a long string _ this is a long string _ this is a long string _ this is a long string _ this is a long string _ this is a long string _ this is a long string _ this is a long string _ this is a long string _ this is a long string _ this is a long string _ this is a long string _ this is a long string _ this is a long string _ this is a long string" ,
"7" : "bytes7: _b7 0x03252353253253" ,
"8" : "bytes22: _b22 0x32523523532532532523532500000000000000000000" ,
"9" : "bytes32: _b32 0x0325235325325235325235325235320000000000000000000000000000000000"
}
} ) . pause ( 500 )
. clickFunction ( 'retunValues3 - transact (not payable)' )
. testFunction ( '0xb4108649d5e65a4a0776d6ac98c2c356540a7e99d641705a82352a845d467eb5' ,
{
status : '0x1 Transaction mined and execution succeed' ,
'transaction hash' : '0xb4108649d5e65a4a0776d6ac98c2c356540a7e99d641705a82352a845d467eb5' ,
'decoded output' : {
"0" : "uint8: _en 2" ,
"1" : "int256[5][]: _a1 1,-45,-78,56,60,-1,42,334,-45455,-446,1,10,-5435,45,-7"
}
} ) . click ( 'i[class^="clearinstance"]' )
} ,
'Test Complex Input Values' : function ( browser ) {
@ -81,49 +97,53 @@ module.exports = {
. click ( '#runTabView button[class^="instanceButton"]' )
. waitForElementPresent ( '.instance:nth-of-type(2)' )
. click ( '.instance:nth-of-type(2) > div > button' )
. testFunction ( 'inputValue1 - transact (not payable)' ,
'0xe9678b5486674a0425301a1d7e925c22cfb9f7f7ec6242697d742009f7ef5b97' ,
` [vm] \n from:0xca3...a733c \n to:test.inputValue1(uint256,int256,string) 0x8c1...401f5 \n value:0 wei \n data:0xd69...00000 \n logs:0 \n hash:0xe96...f5b97 ` ,
{ types : 'uint256 _u, int256 _i, string _str' , values : '"2343242", "-4324324", "string _ string _ string _ string _ string _ string _ string _ string _ string _ string _"' } ,
` {
"0" : "uint256: _uret 2343242" ,
"1" : "int256: _iret -4324324" ,
"2" : "string: _strret string _ string _ string _ string _ string _ string _ string _ string _ string _ string _"
} ` )
. clickFunction ( 'inputValue1 - transact (not payable)' , { types : 'uint256 _u, int256 _i, string _str' , values : '"2343242", "-4324324", "string _ string _ string _ string _ string _ string _ string _ string _ string _ string _"' } )
. testFunction ( '0xe9678b5486674a0425301a1d7e925c22cfb9f7f7ec6242697d742009f7ef5b97' ,
{
status : '0x1 Transaction mined and execution succeed' ,
'transaction hash' : '0xe9678b5486674a0425301a1d7e925c22cfb9f7f7ec6242697d742009f7ef5b97' ,
'decoded output' : {
"0" : "uint256: _uret 2343242" ,
"1" : "int256: _iret -4324324" ,
"2" : "string: _strret string _ string _ string _ string _ string _ string _ string _ string _ string _ string _"
}
} )
. pause ( 500 )
. testFunction ( 'inputValue2 - transact (not payable)' ,
'0x21724b08c3699bda8375803f8dc842194aea370f2aac284e55144b452dca321f' ,
` [vm] \n from:0xca3...a733c \n to:test.inputValue2(uint256[3],bytes8[4]) 0x8c1...401f5 \n value:0 wei \n data:0x1b7...00000 \n logs:1 \n hash:0x217...a321f ` ,
{ types : 'uint256[3] _n, bytes8[4] _b8' , values : '[1,2,3], ["0x1234000000000000", "0x1234000000000000","0x1234000000000000","0x1234000000000000"]' } ,
` {
"0" : "uint256[3]: _nret 1,2,3" ,
"1" : "bytes8[4]: _b8ret 0x1234000000000000,0x1234000000000000,0x1234000000000000,0x1234000000000000"
} ` , ` [
{
"from" : "0x8c1ed7e19abaa9f23c476da86dc1577f1ef401f5" ,
"topic" : "0xd30981760edbf605bda8689e945f622877f230c9a77cbfbd448aa4b7d8ac6e7f" ,
"event" : "event1" ,
"args" : {
"0" : "-123" ,
"1" : "123" ,
"2" : {
"hash" : "0x9c22ff5f21f0b81b113e63f7db6da94fedef11b2119b4088b89664fb9a3cb658" ,
"type" : "Indexed"
} ,
"3" : "0x12340000" ,
"4" : "test _ test _ test _ test test _ test test _ test test _ test test _ test test _ test test _ test " ,
"_i" : "-123" ,
"_u" : "123" ,
"_str" : {
"hash" : "0x9c22ff5f21f0b81b113e63f7db6da94fedef11b2119b4088b89664fb9a3cb658" ,
"type" : "Indexed"
} ,
"_b" : "0x12340000" ,
"_notIndexed" : "test _ test _ test _ test test _ test test _ test test _ test test _ test test _ test test _ test " ,
"length" : 5
}
}
] ` )
. clickFunction ( 'inputValue2 - transact (not payable)' , { types : 'uint256[3] _n, bytes8[4] _b8' , values : '[1,2,3], ["0x1234000000000000", "0x1234000000000000","0x1234000000000000","0x1234000000000000"]' } )
. testFunction ( '0x21724b08c3699bda8375803f8dc842194aea370f2aac284e55144b452dca321f' , {
status : '0x1 Transaction mined and execution succeed' ,
'transaction hash' : '0x21724b08c3699bda8375803f8dc842194aea370f2aac284e55144b452dca321f' ,
'decoded output' : {
"0" : "uint256[3]: _nret 1,2,3" ,
"1" : "bytes8[4]: _b8ret 0x1234000000000000,0x1234000000000000,0x1234000000000000,0x1234000000000000"
} ,
logs : [
{
"from" : "0x8c1ed7e19abaa9f23c476da86dc1577f1ef401f5" ,
"topic" : "0xd30981760edbf605bda8689e945f622877f230c9a77cbfbd448aa4b7d8ac6e7f" ,
"event" : "event1" ,
"args" : {
"0" : "-123" ,
"1" : "123" ,
"2" : {
"hash" : "0x9c22ff5f21f0b81b113e63f7db6da94fedef11b2119b4088b89664fb9a3cb658" ,
"type" : "Indexed"
} ,
"3" : "0x12340000" ,
"4" : "test _ test _ test _ test test _ test test _ test test _ test test _ test test _ test test _ test " ,
"_i" : "-123" ,
"_u" : "123" ,
"_str" : {
"hash" : "0x9c22ff5f21f0b81b113e63f7db6da94fedef11b2119b4088b89664fb9a3cb658" ,
"type" : "Indexed"
} ,
"_b" : "0x12340000" ,
"_notIndexed" : "test _ test _ test _ test test _ test test _ test test _ test test _ test test _ test test _ test " ,
"length" : 5
}
}
]
} )
. click ( 'i[class^="clearinstance"]' )
. end ( )
} ,