Gruntfile.js 548 B

1234567891011121314151617181920212223
  1. module.exports = function(grunt) {
  2. grunt.loadNpmTasks('grunt-contrib-jshint');
  3. grunt.loadNpmTasks('grunt-mocha-test');
  4. grunt.initConfig({
  5. pkg: grunt.file.readJSON('package.json'),
  6. jshint: {
  7. options: {
  8. node: true
  9. },
  10. main : ["index.js"]
  11. },
  12. mochaTest: {
  13. options: {
  14. reporter: 'spec'
  15. },
  16. src: ['test/*.test.js']
  17. }
  18. });
  19. grunt.registerTask('default', ['jshint:main', 'mochaTest']);
  20. };