Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Auto mock does not ignore comments #23

Open
tomek-r opened this issue Nov 22, 2021 · 0 comments
Open

Auto mock does not ignore comments #23

tomek-r opened this issue Nov 22, 2021 · 0 comments

Comments

@tomek-r
Copy link
Contributor

tomek-r commented Nov 22, 2021

This is a Bug Report

Description

  • What went wrong?
    Auto mock generates wrong mocks when comments are placed before function definition.

Similar or dependent issues:

  • No

Additional Data

Example code/file:

' Calls given function with given number of arguments in a specific context. Compare apply in JavaScript.
' @example
' function adder(arg1, arg2, arg3, arg4) as Integer
'   return m.base + arg1 + arg2 + arg3 + arg4
' end function
' funcionCall(adder, [1, 2, 3, 4], { base: 1 })
' @param {Function|Invalid} func
' @param {Dynamic[]} [args=[]]
' @param {Object} [context=Invalid]
' @returns {Dynamic}
function functionCall(func as Dynamic, args = [] as Object, context = Invalid as Object) as Dynamic

The aut mock will generate function adder(arg1, arg2, arg3, arg4) as Integer instead of function functionCall(func as Dynamic, args = [] as Object, context = Invalid as Object) as Dynamic

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant