Skip to content

Commit

Permalink
test: mock supports-color
Browse files Browse the repository at this point in the history
  • Loading branch information
MichaelKreil committed Feb 21, 2024
1 parent 70fc2f4 commit 2de10bc
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion src/lib/progress.test.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,16 @@
/* eslint-disable @typescript-eslint/naming-convention */
/* eslint-disable @typescript-eslint/unbound-method */
import { Progress } from './progress';

import { jest } from '@jest/globals';

jest.unstable_mockModule('supports-color', () => ({
default: { stdout: true },
}));
const { Progress } = await import('./progress');




describe('Progress', () => {
let originalStdoutWrite: typeof process.stdout.write;

Expand Down

0 comments on commit 2de10bc

Please sign in to comment.