-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Lexus Drumgold <[email protected]>
- Loading branch information
1 parent
f28274d
commit fa6d75b
Showing
4 changed files
with
50 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
/** | ||
* @file Type Tests - ParentType | ||
* @module docast/types/tests/unit-d/ParentType | ||
*/ | ||
|
||
import type { Type } from '#src/enums' | ||
import type TestSubject from '../type-parent' | ||
|
||
describe('unit-d:types/ParentType', () => { | ||
it('should extract Type.BLOCK_TAG', () => { | ||
expectTypeOf<TestSubject>().extract<Type.BLOCK_TAG>().toBeString() | ||
}) | ||
|
||
it('should extract Type.COMMENT', () => { | ||
expectTypeOf<TestSubject>().extract<Type.COMMENT>().toBeString() | ||
}) | ||
|
||
it('should extract Type.IMPLICIT_DESCRIPTION', () => { | ||
expectTypeOf<TestSubject>() | ||
.extract<Type.IMPLICIT_DESCRIPTION>() | ||
.toBeString() | ||
}) | ||
|
||
it('should extract Type.ROOT', () => { | ||
expectTypeOf<TestSubject>().extract<Type.ROOT>().toBeString() | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,3 +4,4 @@ | |
*/ | ||
|
||
export type { default as Child } from './child' | ||
export type { default as ParentType } from './type-parent' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
/** | ||
* @file Type Definitions - ParentType | ||
* @module docast/types/ParentType | ||
*/ | ||
|
||
import type { Type } from '#src/enums' | ||
|
||
/** | ||
* **Parent** ([**UnistParent**][1]) node types. | ||
* | ||
* [1]: https://github.com/syntax-tree/unist#parent | ||
*/ | ||
type ParentType = | ||
| Type.BLOCK_TAG | ||
| Type.COMMENT | ||
| Type.IMPLICIT_DESCRIPTION | ||
| Type.ROOT | ||
|
||
export type { ParentType as default } |