Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Windows issues #75

Closed
sprat opened this issue Jan 20, 2016 · 7 comments
Closed

Windows issues #75

sprat opened this issue Jan 20, 2016 · 7 comments

Comments

@sprat
Copy link

sprat commented Jan 20, 2016

I try to use tape-run but can't because I have many issues on my Windows box:

  1. electron is not supported on my (old) Windows box. So I need to switch to another browser
  2. real browsers detection fail too due to bugs in browser-launcher which is not maintained anymore!

Can I suggest moving to browser-launcher2 instead of browser-launcher, so that bugs are fixed?

@juliangruber
Copy link
Owner

i used to use browser-launcher2 but switched back to browser-launcher because that was working better for most cases. i'm happy to merge something in if it works well, but currently don't have time to work on this on my own.

out of curiosity, what windows version are you running?

@sprat
Copy link
Author

sprat commented Jan 21, 2016

I use Vista. I would upgrade if I could, but the update is so expensive...

But anyway, if you look at the windows browser detection code, it's really fragile. Do you remember the issue you had with browser-launcher2?

@juliangruber
Copy link
Owner

i just looked through the history and it seems like this never actually used browser-launcher2. i'd be happy to accept a pull request to move to that.

@sprat
Copy link
Author

sprat commented Jan 23, 2016

I'm trying to do that but I am annoyed because I can't even run the tests. First, there is the makefile: I've replaced it by regular npm scripts. Then, many tests fail: all the tests using electron fail on my machine, that's not really surprising, but also phantomjs, spawn, and stream ones! Don't know if I'll have time to fix that too. Note that I installed phantomjs globally, so phantomjs tests should probably work...

For the record, here are the errors I get:

test/close.js ......................................... 0/2 3s
  window.close()
  not ok exit
    +++ found                                                          
    --- wanted                                                         
    -0                                                                 
    +3221225785                                                        
    compare: ===
    at:
      line: 13
      column: 7
      file: test/close.js
      type: Stream
    source: |
      t.equal(code, 0, 'exit');
    stack: |
      Stream.<anonymous> (test/close.js:13:7)
      Electron.<anonymous> (index.js:98:15)
      Electron._exit (node_modules/electron-stream/index.js:96:8)

  window.close()
  not ok test unfinished: window.close()
    at:
      line: 4
      column: 1
      file: test/close.js
    plan: 2
    count: 1
    source: |
      test('window.close()', function (t) {

test/empty.js ......................................... 1/1 738ms
test/error.js ......................................... 1/1 983ms
test/phantom.js ....................................... 0/3 30s
  phantomjs
  not ok Error: spawn phantomjs ENOENT
    at:
      line: 856
      column: 11
      file: util.js
      function: exports._errnoException
    code: ENOENT
    errno: ENOENT
    syscall: spawn phantomjs
    path: phantomjs
    spawnargs:
      - "C:\\Users\\Sylvain\\AppData\\Local\\Temp\\phantomjs-stream:1bc1bf06"
    test: phantomjs
    message: 'Error: spawn phantomjs ENOENT'
    stack: |
      exports._errnoException (util.js:856:11)

  phantomjs
  not ok missing test
  not ok missing plan
    results:
      ok: false
      count: 1
      pass: 0
      fail: 1
      failures:
        - ok: false
          id: 1
          time: 68.458
          name: phantomjs
          diag:
            at:
              line: 5
              column: 1
              file: test/phantom.js
            results:
              plan:
                start: 1
                end: 2
              count: 2
              pass: 0
              ok: false
              fail: 2
              time: 68.458
            source: |
              test('phantomjs', function (t) {

test/spawn.js ......................................... 0/1 569ms
  spawn
  not ok Error: spawn UNKNOWN
    at:
      line: 856
      column: 11
      file: util.js
      function: exports._errnoException
    code: UNKNOWN
    errno: UNKNOWN
    syscall: spawn
    test: spawn
    message: 'Error: spawn UNKNOWN'
    stack: |
      exports._errnoException (util.js:856:11)
      exports.spawn (child_process.js:362:9)
      test/spawn.js:5:12
      Test.test (node_modules/tap/lib/test.js:445:17)
      Object.<anonymous> (test/spawn.js:4:1)

test/stream.js ........................................ 0/1 1s
  stream
  not ok test unfinished: stream
    at:
      line: 4
      column: 1
      file: test/stream.js
    source: |
      test('stream', function (t) {

total ................................................. 2/9


  2 passing (37s)
  7 failing

@juliangruber
Copy link
Owner

You could set up a Linux Vm for running this project, so you have a good starting point.

This error spawn phantomjs ENOENT shows that maybe on Windows we should spawn phantom.exe or something.

@sprat
Copy link
Author

sprat commented Jan 26, 2016

First thing you should probably do in every dependent library: use cross-spawn instead of child_process.spawn. See nodejs/node-v0.x-archive#5841

@rtsao
Copy link
Collaborator

rtsao commented Jan 29, 2016

This might fix at least the phantom test issue for you: #79

@sprat sprat closed this as completed Mar 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants