/vitest-slow-test-reporter

Slow test reporter for vitest

Primary LanguageTypeScriptMIT LicenseMIT

vitest-slow-test-reporter

Vitest reporter for identifying slow tests

NPM version NPM downloads Build Status License semantic-release

Usage

Pre-Setup

  1. If you do not already have it installed, install vitest

Setup

  1. Install vitest-slow-test-reporter: npm i --save-dev vitest-slow-test-reporter or yarn add -D vitest-slow-test-reporter

  2. Use vitest-slow-test-reporter by calling vitest with reporter flag:

    npx vitest --reporter=vitest-slow-test-reporter

    or add vitest-slow-test-reporter to your config in vitest.config.js:

    import { defineConfig } from 'vitest/config';
    import { VitestSlowTestReporter } from 'vitest-slow-test-reporter'
    
    export default defineConfig({
      test: {
        reporters: [new VitestSlowTestReporter()],
      },
    });