isFunctionTy and tests