1. jest-watch-typeahead
Jest plugin for filtering by filename or test name
jest-watch-typeahead
Package: jest-watch-typeahead
Created by: jest-community
Last modified: Tue, 24 Jan 2023 11:36:01 GMT
Version: 2.2.2
License: MIT
Downloads: 19,479,829
Repository: https://github.com/jest-community/jest-watch-typeahead

Install

npm install jest-watch-typeahead
yarn add jest-watch-typeahead

Build Status npm version

jest-watch-typeahead

Filter your tests by file name or test name

watch

Usage

Install

Install jest(it needs Jest 27+) and jest-watch-typeahead

 yarn add --dev jest jest-watch-typeahead

# or with NPM

npm install --save-dev jest jest-watch-typeahead

Add it to your Jest config

In your package.json

 {
  "jest": {
    "watchPlugins": [
      "jest-watch-typeahead/filename",
      "jest-watch-typeahead/testname"
    ]
  }
}

Or in jest.config.js

 module.exports = {
  watchPlugins: [
    'jest-watch-typeahead/filename',
    'jest-watch-typeahead/testname',
  ],
};

Configuring your key and prompt name

 module.exports = {
  watchPlugins: [
    [
      'jest-watch-typeahead/filename',
      {
        key: 'k',
        prompt: 'do something with my custom prompt',
      },
    ],
  ],
};

Run Jest in watch mode

 yarn jest --watch

RELATED POST

Enhancing Vue.js Development: Harnessing the Potential of Vue-Loader

Enhancing Vue.js Development: Harnessing the Potential of Vue-Loader

Simplify Data Validation in Vue.js: A Step-by-Step Guide to Using Regex

Simplify Data Validation in Vue.js: A Step-by-Step Guide to Using Regex

Troubleshooting Made Easy: Common Issues and Solutions with vue-loader Without vue-cli

Troubleshooting Made Easy: Common Issues and Solutions with vue-loader Without vue-cli

Optimizing Webpack 4 with Vue CLI 3: Disabling the Cache-Loader

Optimizing Webpack 4 with Vue CLI 3: Disabling the Cache-Loader

Step-by-Step Guide: How to Add a Function to Your Vuex Plugin

Step-by-Step Guide: How to Add a Function to Your Vuex Plugin