Advertisement
Guest User

Untitled

a guest
Jul 20th, 2017
53
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.73 KB | None | 0 0
  1. var gulp = require('gulp');
  2. var phpspec = require('gulp-phpspec');
  3. var run = require('gulp-run');
  4. var plumber = require('gulp-plumber');
  5. var notify = require('gulp-notify');
  6.  
  7. gulp.task('test', function() {
  8. gulp.src('spec/**/*.php')
  9. .pipe(phpspec('', { 'verbose': 'v', clear: true, notify: true }))
  10. .on('error', notify.onError({
  11. title: "Crap",
  12. message: "Your tests failed, Jeffrey!",
  13. icon: __dirname + '/fail.png'
  14. }))
  15. .pipe(notify({
  16. title: "Success",
  17. message: "All tests have returned green!"
  18. }));
  19. });
  20.  
  21. gulp.task('watch', function() {
  22. gulp.watch(['spec/**/*.php', 'src/**/*.php'], ['test']);
  23. });
  24.  
  25. gulp.task('default', ['test', 'watch']);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement