Skip to content

Commit

Permalink
expose Util for logging
Browse files Browse the repository at this point in the history
  • Loading branch information
cenfun committed Jun 14, 2024
1 parent c8f421e commit 8506746
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
7 changes: 6 additions & 1 deletion lib/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -206,10 +206,11 @@ declare namespace MCR {
files: CoverageFile[];
} | undefined;

export type LoggingType = "off" | "error" | "info" | "debug";
export interface CoverageReportOptions {

/** {string} logging levels: off, error, info, debug */
logging?: string;
logging?: LoggingType;

/** {string} Report name. Defaults to "Coverage Report". */
name?: string;
Expand Down Expand Up @@ -494,6 +495,10 @@ declare namespace MCR {

export function CDPClient(cdpOptions: CDPOptions): Promise<CoverageClient | undefined>;

export const Util: {
initLoggingLevel: (logging: LoggingType) => string;
};

}

/** create coverage report */
Expand Down
1 change: 1 addition & 0 deletions lib/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -279,5 +279,6 @@ MCR.getSnapshot = getSnapshot;
MCR.diffSnapshot = diffSnapshot;
MCR.WSSession = WSSession;
MCR.CDPClient = CDPClient;
MCR.Util = Util;

module.exports = MCR;
1 change: 1 addition & 0 deletions lib/index.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@ export const diffSnapshot = MCR.diffSnapshot;

export const WSSession = MCR.WSSession;
export const CDPClient = MCR.CDPClient;
export const Util = MCR.Util;

0 comments on commit 8506746

Please sign in to comment.