-
Notifications
You must be signed in to change notification settings - Fork 70
fix: correctly specify types for "mochaOpts" and "patternsOnReject" #1033
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -128,23 +128,16 @@ export interface ExpectOptsConfig { | |
| interval: number; | ||
| } | ||
|
|
||
| export interface MochaOpts { | ||
| /** milliseconds to wait before considering a test slow. */ | ||
| slow?: number; | ||
|
|
||
| /** timeout in milliseconds or time string like '1s'. */ | ||
| timeout?: number; | ||
|
|
||
| /** string or regexp to filter tests with. */ | ||
| grep?: string | RegExp; | ||
| export interface MochaOpts extends Omit<Mocha.MochaOptions, "ui"> { | ||
| ui?: string | ((suite: Mocha.Suite) => void); | ||
|
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Currently ui field inside mocha specified incorrectly. It says that I can use only: |
||
| } | ||
|
|
||
| export interface SystemConfig { | ||
| debug: boolean; | ||
| mochaOpts: MochaOpts; | ||
| expectOpts: ExpectOptsConfig; | ||
| ctx: { [name: string]: unknown }; | ||
| patternsOnReject: Array<string>; | ||
| patternsOnReject: Array<string | RegExp>; | ||
|
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It can be specified as RegExp. Like this: Under the hood we wrap all items from |
||
| workers: number; | ||
| testsPerWorker: number; | ||
| diffColor: string; | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All these options specified inside
Mocha.MochaOptions, so I just use it. Moreover it has a lot of other options that user can use.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok