bpruitt-goddard / vscode-mermaid-syntax-highlight

Markdown syntax support for the Mermaid charting language
MIT License
92 stars 36 forks source link

Add Testing #72

Closed bpruitt-goddard closed 2 years ago

bpruitt-goddard commented 2 years ago

Add unit tests to the grammar using the vscode-tmgrammar-test library. These tests currently cover:

Once added, these can be integrated into a CI pipeline.

Output:

✗ npm test

> mermaid-markdown-syntax-highlighting@1.3.1 test
> vscode-tmgrammar-test 'tests/**/*.test.mermaid'

✓ tests/ado-markdown.test.mermaid run successfuly.
✓ tests/diagrams/class.test.mermaid run successfuly.
✓ tests/diagrams/er.test.mermaid run successfuly.
✓ tests/diagrams/gantt.test.mermaid run successfuly.
✓ tests/diagrams/graph.test.mermaid run successfuly.
✓ tests/diagrams/pie.test.mermaid run successfuly.
✓ tests/diagrams/sequence.test.mermaid run successfuly.
✓ tests/diagrams/state.test.mermaid run successfuly.
✓ tests/markdown.test.mermaid run successfuly.