-
-
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
5d1924a
commit 87fed82
Showing
6 changed files
with
51 additions
and
6 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
/** | ||
* @file Type Tests - InspectOptions | ||
* @module log/interfaces/tests/unit-d/InspectOptions | ||
*/ | ||
|
||
import type TestSubject from '#interfaces/inspect-options' | ||
import type { Nilable } from '@flex-development/tutils' | ||
import type { InspectOptions } from 'node-inspect-extracted' | ||
|
||
describe('unit-d:interfaces/InspectOptions', () => { | ||
it('should extend Omit<BaseInspectOptions, "colors">', () => { | ||
expectTypeOf<TestSubject>().toMatchTypeOf<Omit<InspectOptions, 'colors'>>() | ||
}) | ||
|
||
it('should match [colors?: boolean | null | undefined]', () => { | ||
expectTypeOf<TestSubject>() | ||
.toHaveProperty('colors') | ||
.toEqualTypeOf<Nilable<boolean>>() | ||
}) | ||
}) |
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
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,24 @@ | ||
/** | ||
* @file Interfaces - InspectOptions | ||
* @module log/interfaces/InspectOptions | ||
*/ | ||
|
||
import type * as util from 'node-inspect-extracted' | ||
|
||
/** | ||
* Options for using {@linkcode util.inspect} on a value. | ||
* | ||
* @see {@linkcode util.InspectOptions} | ||
* | ||
* @extends {Omit<util.InspectOptions,'colors'>} | ||
*/ | ||
interface InspectOptions extends Omit<util.InspectOptions, 'colors'> { | ||
/** | ||
* Use color. | ||
* | ||
* @default isColorSupported() | ||
*/ | ||
colors?: boolean | null | undefined | ||
} | ||
|
||
export type { InspectOptions as default } |
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