This files and folders contains the source files for the Kataw's own test suite
-
Snapshots
-
Performance
The Kataw test runner API is very simple and takes a few arguments. If no arguments, the tests will run as normal and report if any errors.
ts-node test/run.tsThe second argument allows you to specify various options:
| Option | Description |
|---|---|
-f "path" |
Only test this file / dir |
-u parser |
Regenerate computed test case blocks for the parser |
-u printer |
Regenerate computed test case blocks for the printer |
-u all |
Regenerate computed test case blocks for both parser and printer |
-g |
Auto-update tests with the results |
-G |
Same as -g except it skips existing files |
Use one of the existing .md files, and insert the code after Input, and update the snapshort
Use one of the existing autogen.md files. Insert the code after ### Cases like this
>
> false
>Then insert the tests after template
### Templates
#### in array
[ # ]In this example the autogenerated folder name will be in array and the test case [ false ]