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

Added some basic tests #7

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open

Conversation

Zardoz89
Copy link

@Zardoz89 Zardoz89 commented Mar 7, 2021

Added some basic tests, using Spock 2 + JUnit 5.

Also, moved the code that parses FTLDoc comments to a separate class, so can be unite tested properly.

This is the first step to add support for optional and type info on @param, using the JSDoc syntax (ie @param {String|Number} arg etc...)

def params = output.get("@param") as SimpleSequence
def param = params.get(0) as SimpleHash
param.get("name").toString() == "arg"
param.get("description").toString() == "Long description that continues on another line\n"
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks like a bug. It should trim preceding spaces to a single space.

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