forked from DavyJonesLocker/client_side_validations
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Gruntfile.js
35 lines (33 loc) · 1.05 KB
/
Gruntfile.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
module.exports = function(grunt) {
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
shell: {
precompile: {
command: 'rake regenerate_javascript',
options: {
stdout: true
}
},
server: {
command: "thin start -p 4567 -R test/javascript/config.ru -d; sleep 5;"
}
},
jshint: {
//all: ['Gruntfile.js', 'vendor/assets/javascripts/rails.validations.js', 'test/javascript/public/test/**/*.js']
all: ['Gruntfile.js', 'test/javascript/public/test/**/*.js']
},
qunit: {
all: {
options: {
urls: ['http://localhost:4567/']
}
}
}
});
grunt.loadNpmTasks('grunt-contrib-jshint');
grunt.loadNpmTasks('grunt-contrib-qunit');
grunt.loadNpmTasks('grunt-shell');
//grunt.registerTask('default', ['shell:precompile','jshint','shell:server','qunit']);
grunt.registerTask('default', ['shell:precompile','shell:server','qunit']);
grunt.event.on('qunit.done', function(){grunt.util.spawn({cmd: "thin", args: ["stop"]});});
};