Skip to content

Add Jest to lookup #684

Closed
Closed
@targos

Description

@targos

Jest is a very popular testing framework (> 4.4M downloads). Node.js releases have broken it more than once, latest being 11.11.0: nodejs/node#25963 (comment).

Support for Yarn was a necessary step to add Jest but unfortunately it is not enough.
Here is the (truncated) output I get with the latest version of CITGM:

$ citgm jest --yarn
info:    starting            | jest                
info:    lookup              | jest                
info:    lookup-notfound     | jest                
info:    lookup-githead      | https://github.com/facebook/jest/archive/b16789230fd45056a7f2fa199bae06c7a1780deb.tar.gz
info:    jest npm:           | Downloading project: https://github.com/facebook/jest/archive/b16789230fd45056a7f2fa199bae06c7a1780deb.tar.gz
info:    jest npm:           | Project downloaded -.tgz
info:    jest yarn:          | yarn install started
info:    jest yarn:          | yarn install successfully completed
info:    jest yarn:          | test suite started  
error:   failure             | The canary is dead: 
error:   failing module(s)   |                     
error:   module name:        | jest                
error:   version:            | 24.1.0              
error:   error:              | The canary is dead: 
error:   error:              | undefinedyarn install v1.13.0                                                                                                                         
error:                       | [1/5] Validating package.json...                                                                                                                      
error:                       | [2/5] Resolving packages...                                                                                                                           
error:                       | [3/5] Fetching packages...                                                                                                                            
error:                       | info [email protected]: The platform "linux" is incompatible with this module.                                                                           
error:                       | info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.                                       
error:                       | [4/5] Linking dependencies...                                                                                                                         
error:                       | [5/5] Building fresh packages...                                                                                                                      
error:                       | $ opencollective postinstall && yarn build                                                                                                            
error:                       |                                                                                                                                                       
error:                       | *** Thank you for using jest! ***                                                                                                                     
error:                       |                                                                                                                                                       
error:                       | Please consider donating to our open collective                                                                                                       
error:                       | to help us maintain this package.                                                                                                                     
error:                       |                                                                                                                                                       
error:                       | https://opencollective.com/jest/donate                                                                                                                
error:                       |                                                                                                                                                       
error:                       | ***                                                                                                                                                   
error:                       |                                                                                                                                                       
error:                       | yarn run v1.13.0                                                                                                                                      
error:                       | $ node ./scripts/build.js                                                                                                                             
error:                       | Building packages                                                                                                                                     
error:                       | babel-jest................................................................ DONE                                                                       
error:                       | babel-plugin-jest-hoist................................................... DONE                                                                       
error:                       | babel-preset-jest......................................................... DONE                                                                       
error:                       | diff-sequences............................................................ DONE                                                                       
error:                       | eslint-config-fb-strict................................................... DONE                                                                       
error:                       | expect.................................................................... DONE                                                                       
error:                       | jest...................................................................... DONE                                                                       
error:                       | jest-changed-files........................................................ DONE                                                                       
error:                       | jest-circus............................................................... DONE                                                                       
error:                       | jest-cli.................................................................. DONE                                                                       
error:                       | jest-config............................................................... DONE                                                                       
error:                       | jest-diff................................................................. DONE                                                                       
error:                       | jest-docblock............................................................. DONE                                                                       
error:                       | jest-each................................................................. DONE                                                                       
error:                       | jest-environment-jsdom.................................................... DONE                                                                       
error:                       | jest-environment-node..................................................... DONE                                                                       
error:                       | jest-get-type............................................................. DONE                                                                       
error:                       | jest-haste-map............................................................ DONE                                                                       
error:                       | jest-jasmine2............................................................. DONE                                                                       
error:                       | jest-leak-detector........................................................ DONE                                                                       
error:                       | jest-matcher-utils........................................................ DONE                                                                       
error:                       | jest-message-util......................................................... DONE                                                                       
error:                       | jest-mock................................................................. DONE                                                                       
error:                       | jest-phabricator.......................................................... DONE                                                                       
error:                       | jest-regex-util........................................................... DONE                                                                       
error:                       | jest-repl................................................................. DONE                                                                       
error:                       | jest-resolve.............................................................. DONE                                                                       
error:                       | jest-resolve-dependencies................................................. DONE                                                                       
error:                       | jest-runner............................................................... DONE                                                                       
error:                       | jest-runtime.............................................................. DONE                                                                       
error:                       | jest-serializer........................................................... DONE                                                                       
error:                       | jest-snapshot............................................................. DONE                                                                       
error:                       | jest-util................................................................. DONE                                                                       
error:                       | jest-validate............................................................. DONE                                                                       
error:                       | jest-watcher.............................................................. DONE                                                                       
error:                       | jest-worker............................................................... DONE                                                                       
error:                       | pretty-format............................................................. DONE                                                                       
error:                       |                                                                                                                                                       
error:                       | Building browser packages                                                                                                                             
error:                       | jest-mock................................................................. DONE                                                                       
error:                       | pretty-format............................................................. DONE                                                                       
error:                       | expect.................................................................... DONE                                                                       
error:                       | Done in 11.11s.                                                                                                                                       
error:                       | Done in 28.16s.                                                                                                                                       
error:                       | yarn run v1.13.0                                                                                                                                      
error:                       | $ yarn typecheck && yarn lint && yarn jest                                                                                                            
error:                       | $ flow check --include-warnings                                                                                                                       
error:                       | Found 0 errors                                                                                                                                        
error:                       | $ eslint . --cache --report-unused-disable-directives --ext js,md                                                                                     
error:                       | $ node ./packages/jest-cli/bin/jest.js                                                                                                                
error:                       | info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.                                                                  
error:                       | info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.                                                                  
error:                       |                                                                                                                                                       
error:                       | FAIL packages/jest-diff/src/__tests__/diff.test.js                                                                                                    
error:                       | ● oneline strings                                                                                                                                     
error:                       |                                                                                                                                                       
error:                       | expect(value).toMatchSnapshot()                                                                                                                       
error:                       |                                                                                                                                                       
error:                       | Received value does not match stored snapshot "oneline strings 1".                                                                                    
error:                       |                                                                                                                                                       
error:                       | - Snapshot                                                                                                                                            
error:                       | + Received                                                                                                                                            
error:                       |                                                                                                                                                       
error:                       | - "<green>- Expected</>                                                                                                                               
error:                       | - <red>+ Received</>                                                                                                                                  
error:                       | + "- Expected                                                                                                                                         
error:                       | + + Received                                                                                                                                          
error:                       |                                                                                                                                                       
error:                       | - <green>- ab</>                                                                                                                                      
error:                       | - <red>+ aa</>"                                                                                                                                       
error:                       | + - ab                                                                                                                                                
error:                       | + + aa"                                                                                                                                               
error:                       |                                                                                                                                                       
error:                       | at Object.toMatchSnapshot (packages/jest-diff/src/__tests__/diff.test.js:88:28)                                                                       
error:                       |                                                                                                                                                       
error:                       | ● oneline strings                                                                                                                                     
error:                       |                                                                                                                                                       
error:                       | expect(value).toMatchSnapshot()                                                                                                                       
error:                       |                                                                                                                                                       
error:                       | Received value does not match stored snapshot "oneline strings 2".                                                                                    
error:                       |                                                                                                                                                       
error:                       | - Snapshot                                                                                                                                            
error:                       | + Received                                                                                                                                            
error:                       |                                                                                                                                                       
error:                       | - "<green>- Expected</>                                                                                                                               
error:                       | - <red>+ Received</>                                                                                                                                  
error:                       | + "- Expected                                                                                                                                         
error:                       | + + Received                                                                                                                                          
error:                       |                                                                                                                                                       
error:                       | - <green>- 123456789</>                                                                                                                               
error:                       | - <red>+ 234567890</>"                                                                                                                                
error:                       | + - 123456789                                                                                                                                         
error:                       | + + 234567890"                                                                                                                                        
error:                       |                                                                                                                                                       
error:                       | at Object.toMatchSnapshot (packages/jest-diff/src/__tests__/diff.test.js:89:42)
...

There's obviously something wrong with colors.

/cc @SimenB

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions