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

Add tested_by functionality #54

Merged
merged 5 commits into from
Feb 26, 2020
Merged

Add tested_by functionality #54

merged 5 commits into from
Feb 26, 2020

Conversation

baheath
Copy link
Collaborator

@baheath baheath commented Feb 25, 2020

Adds an optional tested_by documentation element to function documentation. This support is off by default and can be enabled with a command line argument or in the config file, as either an optional or required element. The element value is required to be an array of strings, or one of the supported tags (__OPTIONAL__, __MISSING__), depending on enablement category.

Also adds support for outputting the emitted/reconciled documentation as JSON so it can be consumed by other tools.

@baheath baheath closed this Feb 25, 2020
@baheath baheath reopened this Feb 25, 2020
@baheath baheath closed this Feb 25, 2020
@baheath baheath reopened this Feb 25, 2020
@baheath baheath closed this Feb 25, 2020
@baheath baheath reopened this Feb 25, 2020
@baheath baheath closed this Feb 25, 2020
@baheath baheath reopened this Feb 25, 2020
@baheath
Copy link
Collaborator Author

baheath commented Feb 25, 2020

Sorry about all the closing and reopening. Finally got the CLA check to pass.

Copy link
Contributor

@fosterbrereton fosterbrereton left a comment

Choose a reason for hiding this comment

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

LGTM! Thanks, Brandon!

@jaredwy
Copy link
Contributor

jaredwy commented Feb 25, 2020

I am curious why yaml now has to know about json output?
Are there operations only happening in the yaml output that we could push to operate on the json structures so that YAML becomes thinner

@baheath
Copy link
Collaborator Author

baheath commented Feb 25, 2020

I am curious why yaml now has to know about json?

@jaredwy The goal of this is to be able to tag a particular API with the tests for it. That all works fine within the yaml. But then we also want to be able to parse out the test info to be able to generate coverage reports, etc. Ideally I wanted to just have hyde do:

  1. Parse yaml
  2. Convert to json
  3. Output the json

However, the way hyde is currently architected, several things are intertwined:

  1. Needs to parse the headers (c++) in order to parse the yaml files
  2. All the logic for reading the yaml and converting to json is within the do_merge/reconcile methods of the yaml emitter classes

So, I decided to add an out parameter to the emit methods to capture the result of that parsing/converting logic.

I am certainly open to other options.

@fosterbrereton fosterbrereton merged commit 71e659e into master Feb 26, 2020
@fosterbrereton fosterbrereton deleted the bheath/tested-by branch February 26, 2020 19:08
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

Successfully merging this pull request may close these issues.

None yet

4 participants