1.0.0 • Published 4 years ago
ava-to-json v1.0.0
ava2json
ava2json~AvaTest
Properties
Name | Type | Description |
---|---|---|
title | String | The AVA test title wrapped inside of the test function |
description | String | The feature description (if any) added above the test as a JSDoc comment |
code | String | The code found wrapped in the test function. |
flag | String | Either 'skip' , 'only' , 'todo' or null for none; |
ava2json~parseAva(avaString, options)
Param | Type | Default | Description |
---|---|---|---|
avaString | String | The source of the AVA test file | |
options | Object | ||
options.unIndent | Number | 2 | Positive integer in which the code will be un-indented |
options.testName | String | test | The name of the test function to look-up into the code |
Returns: Array.<AvaTest> - The tests found in the source code
Parses given AVA test source code
ava2json~parseFile(file, options)
Param | Type | Description |
---|---|---|
file | String | Path to the AVA file |
options | Object | Same options as in parseAva |
Parses given AVA file
ava2json~parseFileSync(file, options)
Param | Type | Description |
---|---|---|
file | String | Path to the AVA file |
options | Object | Same options as in parseAva |
Parses given AVA file synchronously
A module for converting AVA tests syntax into JSON
License
© 2020-present Martin Rafael Gonzalez tin@devtin.io
1.0.0
4 years ago