Open hayesmaker opened 8 years ago
so i installed an updated phantomjs, and this core.. now my tests run, but the nice colours in the output I used to have don't show anymore... is that something I have to live with now?
the output is even worse on travis, most of the text is missing.
now since mocha-phantomjs just breaks my build all of a sudden
There was some issue with bitbucket that is owned by a dependant package. It works now. You can go ahead and go back to it if you wish. I want to move the CLI into this library so it's much easier to use first before telling everyone to move off of mocha-phantomjs
... and even then I'd have a simple binary wrapper for it so you can just run mocha-phantomjs
what version of phantomjs are you using?
I'm using "phantomjs": "^2.1.3"
travis seems to npm install
with these warning about phantom.. but I don't think I had them locally.
npm WARN deprecated phantomjs@2.1.3: Package renamed to phantomjs-prebuilt. Please update 'phantomjs' package references to 'phantomjs-prebuilt' phantomjs@2.1.3 install /home/travis/build/hayesmaker/thrust-platform/node_modules/phantomjs node install.js Found PhantomJS at /usr/local/phantomjs/bin/phantomjs ...verifying PhantomJS detected, but wrong version 1.9.8 @ /usr/local/phantomjs/bin/phantomjs.
I guess it's more of a Travis issue with phantomjs: https://github.com/travis-ci/travis-ci/issues/3225 would be great to get better output, but the tests don't fail at least.
I'll explore workarounds to get phantom2 installed on travis from that thread.
I'll explore workarounds to get phantom2 installed on travis from that thread.
Do what this project does and just wget it
Though I think one regression or change is that mocha-phantomjs-core
is defaulting to no color output rather than color - or the bundled mocha can't detect it so it leaves it off. I should see what I can do from the phantom side about that.
Seems that even passing useColors: true
in the json config leaves the output without color (on a local terminal, not referring to travis).
Any hints?
Getting the same issue, no colors. Any way to enable them?
Fixed passing mocha.useColors(true);
to the mocha config in the TestRunner
file. This is in line 148 of mocha-phantomjs-core.js
which is expecting the configuration to be passed. Since the documentation is not clear to set this, the colors are consider by the module as false.
mocha.useColors(config.useColors)
.
Please update documentation or set the line to have the colors enable as default if they are not passed as false explicitly in the config.
@nathanboktae I agree with @jpgcode on this one
Had the same problem, an update of this issue would be fantastic!
Seems that even passing useColors: true in the json config leaves the output without color (on a local terminal, not referring to travis).
I can't reproduce this issue, and I have tests for it too.
Though I acknowledge that the default of colors being on is a regression from mocha-phantomjs
.
i used to run tests like:
mocha-phantomjs
now since mocha-phantomjs just breaks my build all of a sudden https://travis-ci.org/hayesmaker/thrust-platform/builds/121379410
now I'm told to use this module, and output looks horrible. see comments below.