Skip to content

Commit 5a8d859

Browse files
test: write test case for -v flag
1 parent 4f69e30 commit 5a8d859

4 files changed

Lines changed: 11 additions & 1 deletion

File tree

e2e/index.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,5 @@ const matchSnapshot = async (t, arg) => {
1717
};
1818

1919
test('shows help with -h flag', matchSnapshot, '-h');
20-
test('shows help with --help flag', matchSnapshot, '--help');
20+
test('shows help with --help flag', matchSnapshot, '--help');
21+
test('shows help with -v flag', matchSnapshot, '-v');
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,15 @@ Generated by [AVA](https://ava.li).
4848
Development:␊
4949
https://github.com/docsifyjs/docsify-cli/blob/master/CONTRIBUTING.md`
5050

51+
## shows help with -v flag
52+
53+
> Snapshot 1
54+
55+
`␊
56+
docsify-cli version:␊
57+
4.4.0␊
58+
`
59+
5160
## shows up help message without any args
5261

5362
> Snapshot 1

e2e/index.js.snap

536 Bytes
Binary file not shown.

e2e/snapshots/index.js.snap

-487 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)