-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add basic reporter which allow user to use reporter in ci (#2612)
* add basic reporter * extend basic reporter * Update index.md * Update index.md * extend from base reporter * fix lint * override onReRun * only ovverride onWatcherRerun * chore: cleanup * add override back * revert Co-authored-by: Vladimir <sleuths.slews0s@icloud.com>
- Loading branch information
1 parent
5a65675
commit 5df522f
Showing
4 changed files
with
17 additions
and
2 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,12 @@ | ||
import { BaseReporter } from './base' | ||
import type { File } from '#types' | ||
|
||
export class BasicReporter extends BaseReporter { | ||
isTTY = false | ||
|
||
reportSummary(files: File[]) { | ||
// non-tty mode doesn't add a new line | ||
this.ctx.logger.log() | ||
return super.reportSummary(files) | ||
} | ||
} |
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 |
---|---|---|
@@ -1,2 +1,2 @@ | ||
export const isNode = typeof process < 'u' && typeof process.stdout < 'u' && !process.versions?.deno && !globalThis.window | ||
export const isBrowser = typeof window !== 'undefined' | ||
export const isNode: boolean = typeof process < 'u' && typeof process.stdout < 'u' && !process.versions?.deno && !globalThis.window | ||
export const isBrowser: boolean = typeof window !== 'undefined' |