t.ok(common.isLLCall(lowlevelCall.callAst)&&common.isLowLevelCall(lowlevelCall.callAst),'call is llc should work')
// t.notOk(common.isLowLevelCall(localCall), 'is not low level call')
t.ok(common.isLLDelegatecall(lowlevelCall.delegatecallAst)&&common.isLowLevelCall(lowlevelCall.delegatecallAst),'delegatecall is llc should work')
// t.notOk(common.isExternalDirectCall(localCall), 'is not external direct call')
})
// t.notOk(common.isEffect(localCall), 'is not effect')
// t.notOk(common.isInteraction(localCall), 'is not interaction')
test('staticAnalysisCommon: Call of parameter function',function(t){
// })
t.plan(3)
t.ok(common.isLocalCall(parameterFunction),'is not LocalCall')
// test('staticAnalysisCommon.isLowLevelCall', function (t) {
t.equals(common.getFunctionCallType(parameterFunction),'function (uint256,uint256)','Extracts right type')
// t.plan(6)
t.equals(common.getFunctionCallTypeParameterType(parameterFunction),'uint256,uint256','Extracts param right type')
// t.ok(common.isLowLevelSendInst(lowlevelCall.sendAst) && common.isLowLevelCall(lowlevelCall.sendAst), 'send is llc should work')
})
// t.ok(common.isLowLevelCallInst(lowlevelCall.callAst) && common.isLowLevelCall(lowlevelCall.callAst), 'call is llc should work')
// t.notOk(common.isLowLevelCallInst(lowlevelCall.callcodeAst), 'callcode is not call')
test('staticAnalysisCommon: function call with of function with function parameter',function(t){
// t.ok(common.isLowLevelCallcodeInst(lowlevelCall.callcodeAst) && common.isLowLevelCall(lowlevelCall.callcodeAst), 'callcode is llc should work')
t.plan(2)
// t.notOk(common.isLowLevelCallcodeInst(lowlevelCall.callAst), 'call is not callcode')
t.equals(common.getFunctionCallType(parameterFunctionCall),'function (function (uint256) pure returns (uint256)) pure returns (uint256)','Extracts right type')
// t.ok(common.isLowLevelDelegatecallInst(lowlevelCall.delegatecallAst) && common.isLowLevelCall(lowlevelCall.delegatecallAst), 'delegatecall is llc should work')
t.equals(common.getFunctionCallTypeParameterType(parameterFunctionCall),'function (uint256) pure returns (uint256)','Extracts param right type')
// })
})
// test('staticAnalysisCommon: Call of parameter function', function (t) {
// t.equals(common.getFunctionCallType(parameterFunctionCall), 'function (function (uint256,uint256) pure returns (uint256),uint256,uint256) pure returns (uint256)', 'Extracts right type')
t.plan(8)
// t.equals(common.getFunctionCallTypeParameterType(parameterFunctionCall), 'function (uint256,uint256) pure returns (uint256),uint256,uint256', 'Extracts param right type')