ember-cli-addon-tests icon indicating copy to clipboard operation
ember-cli-addon-tests copied to clipboard

Fails to run on Windows 10

Open JakeDetels opened this issue 8 years ago • 1 comments

On Windows 10, I'm unable to use ember-cli-addon-tests together with a freshly made ember-addon and using the example test listed at https://github.com/tomdale/ember-cli-addon-tests#example.

Steps to reproduce

  1. ember addon em-addon-1
  2. cd my-addon
  3. npm i --save-dev chai rsvp request ember-cli-addon-tests
  4. create test file at my-app/test/foo-test.js containing the full example test found at https://github.com/tomdale/ember-cli-addon-tests#example
  5. run mocha

Below is the complete output after running the above. After the output is some details about my environment.

c:\www\test\em-addon-1 (master) ([email protected])                                                                                                        
λ npm test                                                                                                                                                
                                                                                                                                                          
> [email protected] test c:\www\test\em-addon-1                                                                                                            
> mocha                                                                                                                                                   
                                                                                                                                                          
  serve assets acceptance                                                                                                                                 
    1) "before all" hook                                                                                                                                  
    2) "after all" hook                                                                                                                                   
                                                                                                                                                          
                                                                                                                                                          
  0 passing (5m)                                                                                                                                          
  2 failing                                                                                                                                               
                                                                                                                                                          
  1) serve assets acceptance "before all" hook:                                                                                                           
     Error: timeout of 300000ms exceeded. Ensure the done() callback is being called in this test.                                                        
                                                                                                                                                          
                                                                                                                                                          
  2) serve assets acceptance "after all" hook:                                                                                                            
     Error: You must call `startServer()` before calling `stopServer()`.                                                                                  
      at AddonTestApp.App.stopServer (node_modules\ember-cli-addon-tests\lib\models\app.js:46:11)                                                         
      at Context.<anonymous> (test\foo-test.js:22:16)                                                                                                     
                                                                                                                                                          
                                                                                                                                                                                                                                                                                                 
c:\www\test\em-addon-1\node_modules\temp\node_modules\rimraf\rimraf.js:218                                                                                
      throw er                                                                                                                                            
      ^                                                                                                                                                   
                                                                                                                                                          
Error: EBUSY: resource busy or locked, unlink 'C:\Users\jake\AppData\Local\Temp\d-117430-17912-1407256.62nzmpldi\pristine\dummy'                       
    at Error (native)                                                                                                                                     
    at Object.fs.unlinkSync (fs.js:1103:18)                                                                                                               
    at rimrafSync (c:\www\test\em-addon-1\node_modules\temp\node_modules\rimraf\rimraf.js:211:13)                                                         
    at c:\www\test\em-addon-1\node_modules\temp\node_modules\rimraf\rimraf.js:245:5                                                                       
    at Array.forEach (native)                                                                                                                             
    at rmkidsSync (c:\www\test\em-addon-1\node_modules\temp\node_modules\rimraf\rimraf.js:244:26)                                                         
    at rmdirSync (c:\www\test\em-addon-1\node_modules\temp\node_modules\rimraf\rimraf.js:237:7)                                                           
    at fixWinEPERMSync (c:\www\test\em-addon-1\node_modules\temp\node_modules\rimraf\rimraf.js:150:5)                                                     
    at rimrafSync (c:\www\test\em-addon-1\node_modules\temp\node_modules\rimraf\rimraf.js:216:26)                                                         
    at c:\www\test\em-addon-1\node_modules\temp\node_modules\rimraf\rimraf.js:245:5                                                                       
    at Array.forEach (native)                                                                                                                             
    at rmkidsSync (c:\www\test\em-addon-1\node_modules\temp\node_modules\rimraf\rimraf.js:244:26)                                                         
    at rmdirSync (c:\www\test\em-addon-1\node_modules\temp\node_modules\rimraf\rimraf.js:237:7)                                                           
    at fixWinEPERMSync (c:\www\test\em-addon-1\node_modules\temp\node_modules\rimraf\rimraf.js:150:5)                                                     
    at rimrafSync (c:\www\test\em-addon-1\node_modules\temp\node_modules\rimraf\rimraf.js:216:26)                                                         
    at cleanupDirsSync (c:\www\test\em-addon-1\node_modules\temp\lib\temp.js:143:5)                                                                       
    at process.cleanupSync (c:\www\test\em-addon-1\node_modules\temp\lib\temp.js:196:19)                                                                  
    at emitOne (events.js:96:13)                                                                                                                          
    at process.emit (events.js:188:7)                                                                                                                     
    at process.exit (internal/process.js:164:15)                                                                                                          
    at done (C:\Users\jake\AppData\Roaming\npm\node_modules\mocha\bin\_mocha:472:15)                                                                   
    at afterWrite (_stream_writable.js:388:3)                                                                                                             
    at _combinedTickCallback (internal/process/next_tick.js:86:20)                                                                                        
    at process._tickCallback (internal/process/next_tick.js:104:9)                                                                                        
npm ERR! Test failed.  See above for more details.                                                                                                        

Environment Info ember-cli: 2.12.2 node: 6.10.2 os: win32 x64 (Windows 10 Pro) mocha: 3.1.0 RAM: 12 GB

using ConEmu for my Windows console, running as an administrator.

JakeDetels avatar May 30 '17 15:05 JakeDetels

Try increasing the timeout to an insanely high number. This project works for me on Win 10 using cmd.exe.

kellyselden avatar Aug 06 '17 02:08 kellyselden