mikeerickson / gulp-phpspec

gulp-phpspec plugin
MIT License
6 stars 2 forks source link

Doesn't return error state to gulp? #3

Closed valorin closed 10 years ago

valorin commented 10 years ago

I'm trying to use the https://atom.io/packages/test-status package in Atom, which automatically runs gulp test when you save a file. It makes to nice instant feedback as to the success/failure of tests.

However, gulp-phpspec doesn't seen to throw an error state to gulp when the tests fail. This means the test-status package doesn't think any tests failed, and the little indicator icon doesn't change colour from green to red... kinda defeating the purpose.

Is this an issue with your package, or something that gulp itself cannot handle?

mikeerickson commented 10 years ago

Not quite sure where issue lies but I can surely look. I use with PHPStorm personally and it works as expected.

Can you please share your spec task so I can compare.

Also, how do you have it configured with atom (I will try it locally)

valorin commented 10 years ago

I'm pretty sure the test-status package just works after being installed, if it finds a gulpfile.js in the project root.

My gulp task looks like this:

// Run phpspec tests
gulp.task('test', function() {
   gulp.src('spec/**/*.php')
       .pipe(phpspec('./vendor/bin/phpspec run', { formatter: "dot", noInteract: true }));
});

I've tried various things like breaking the path (so phpspec fails to runs), and failing tests, etc, but none seem to affect the overall gulp return value.

valorin commented 10 years ago

Was this fixed in the code? I can't see a change which would relate to it...