Skip to content
This repository has been archived by the owner on Nov 13, 2022. It is now read-only.

viddo/jest-symlinks-probing

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Verifies that symbolic links aren't included in test run. Usage installs the fork viddo/jest that includes a fix to follow symlinks for crawling files to test.

Usage

  1. install yarn (since that's what jest endorse over npm)
  2. Install dependencies by running yarn run install, or ./install.sh directly
  3. Execute tests by yarn test (current, default behavior) and yarn test-follow-symlinks (new flag/behavior, to include symlinked test files).

Example output:

yarn test
yarn test v0.27.5
$ jest
No tests found
In /Users/nicklas/src/jest-symlinks-probing
  3 files checked.
  testMatch: **/__tests__/**/*.js?(x),**/?(*.)(spec|test).js?(x) - 1 match
  testPathIgnorePatterns: other - 2 matches
Pattern:  - 0 matches
Done in 0.56s.
 ~/src/jest-symlinks-probing  ⑂ master    yarn run test-follow-symlinks

Test run which includes the new followSymlinks flag to include test files that are symlinked:

yarn test-follow-symlinks
$ yarn run v0.27.5
$ jest --followSymlinks
watchman can not be used with followSymlinks, watchman will be disabled
 PASS  src/linked.test.js
  real
    ✓ test (5ms)

Test Suites: 1 passed, 1 total
Tests:       1 passed, 1 total
Snapshots:   0 total
Time:        0.7s, estimated 1s
Ran all test suites.
Done in 1.33s.

Development

  1. yarn install
  2. Use development build of viddo/jest fork by following official facebook/jest contributor instructions, see "How to try a development build of Jest in another project"
  3. yarn link jest-cli

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published