benpickles / peity

Progressive <svg> pie, donut, bar and line charts

Home Page:http://benpickles.github.io/peity

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

make test error

vko-online opened this issue · comments

Cannot run test suit, phantomjs cannot find file

❯ make test
rm -f test/comparisons/*
rm -f test/images/*
./node_modules/.bin/mocha -R spec -t 30000  ./test/index.js
child_process: customFds option is deprecated, use stdio instead.


  Peity
    1) bar1
    ....

  0 passing (320ms)
  51 failing

  1) Peity bar1:
     Uncaught Error: Command failed: /Users/bwin/Documents/Dev/github/peity/test/bin/screenshot http://localhost:50354/bar1 /Users/bwin/Documents/Dev/github/peity/test/images/bar1.png 32 16
env: phantomjs: No such file or directory

      at ChildProcess.exithandler (child_process.js:751:12)
      at ChildProcess.emit (events.js:110:17)
      at maybeClose (child_process.js:1015:16)
      at Socket.<anonymous> (child_process.js:1183:11)
      at Socket.emit (events.js:107:17)
      at Pipe.close (net.js:485:12)

It's expecting an external phantomjs binary. I think that's what the error message means. Do you have phantomjs installed?

Installed phantomjs binary, make test error (npm test same error)

~/Documents/dev/github/peity master*
❯ phantomjs
[1]    3483 killed     phantomjs

~/Documents/dev/github/peity master*
❯ npm test

> peity@3.2.0 test /Users/bwin/Documents/Dev/github/peity
> make test

rm -f test/comparisons/*
rm -f test/images/*
./node_modules/.bin/mocha -R spec -t 30000  ./test/index.js
child_process: customFds option is deprecated, use stdio instead.

  Peity
    1) bar1
    ...

  0 passing (310ms)
  51 failing

  1) Peity bar1:
     Uncaught Error: Command failed: /Users/bwin/Documents/Dev/github/peity/test/bin/screenshot http://localhost:56828/bar1 /Users/bwin/Documents/Dev/github/peity/test/images/bar1.png 32 16

      at ChildProcess.exithandler (child_process.js:751:12)
      at ChildProcess.emit (events.js:110:17)
      at maybeClose (child_process.js:1015:16)
      at Socket.<anonymous> (child_process.js:1183:11)
      at Socket.emit (events.js:107:17)
      at Pipe.close (net.js:485:12)

I think this was fixed in #92, both Travis and I don't have any problems running the tests.