File tree Expand file tree Collapse file tree 3 files changed +55
-0
lines changed Expand file tree Collapse file tree 3 files changed +55
-0
lines changed Original file line number Diff line number Diff line change
1
+ /**
2
+ * @file Type Tests - QuestionEnum
3
+ * @module commitlint-config/types/tests/unit-d/QuestionEnum
4
+ */
5
+
6
+ import type TestSubject from '../question-enum'
7
+
8
+ describe ( 'unit-d:types/QuestionEnum' , ( ) => {
9
+ it ( 'should match [description?: string]' , ( ) => {
10
+ expectTypeOf < TestSubject > ( )
11
+ . toHaveProperty ( 'description' )
12
+ . toEqualTypeOf < string | undefined > ( )
13
+ } )
14
+
15
+ it ( 'should match [emoji?: string]' , ( ) => {
16
+ expectTypeOf < TestSubject > ( )
17
+ . toHaveProperty ( 'emoji' )
18
+ . toEqualTypeOf < string | undefined > ( )
19
+ } )
20
+
21
+ it ( 'should match [title?: string]' , ( ) => {
22
+ expectTypeOf < TestSubject > ( )
23
+ . toHaveProperty ( 'title' )
24
+ . toEqualTypeOf < string | undefined > ( )
25
+ } )
26
+ } )
Original file line number Diff line number Diff line change 4
4
*/
5
5
6
6
export type { default as NoteKeyword } from './note-keyword'
7
+ export type { default as QuestionEnum } from './question-enum'
Original file line number Diff line number Diff line change
1
+ /**
2
+ * @file Type Definitions - QuestionEnum
3
+ * @module commitlint-config/types/QuestionEnum
4
+ */
5
+
6
+ /**
7
+ * Object representing prompt question metadata.
8
+ *
9
+ * @see https://commitlint.js.org/#/reference-prompt?id=questions
10
+ */
11
+ type QuestionEnum = {
12
+ /**
13
+ * Enum description.
14
+ */
15
+ description ?: string
16
+
17
+ /**
18
+ * Emoji to display next to {@linkcode title}.
19
+ */
20
+ emoji ?: string
21
+
22
+ /**
23
+ * Prompt title.
24
+ */
25
+ title ?: string
26
+ }
27
+
28
+ export type { QuestionEnum as default }
You can’t perform that action at this time.
0 commit comments