Skip to content

Commit 3f1f88b

Browse files
committed
Also lint tests. For this, moving jshint options into Gruntfile...
Updated options as well.
1 parent a5aa50f commit 3f1f88b

File tree

2 files changed

+46
-25
lines changed

2 files changed

+46
-25
lines changed

.jshintrc

Lines changed: 0 additions & 17 deletions
This file was deleted.

Gruntfile.js

Lines changed: 46 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
/*jshint node: true */
2-
31
'use strict';
42

53
module.exports = function (grunt) {
@@ -10,12 +8,52 @@ module.exports = function (grunt) {
108
all: ['test/index.html']
119
},
1210
jshint: {
13-
files: [
14-
'Gruntfile.js',
15-
'jquery.cookie.js'
16-
],
1711
options: {
18-
jshintrc: true
12+
curly: true,
13+
eqeqeq: true,
14+
expr: true,
15+
// maxlen: 130,
16+
newcap: true,
17+
noarg: true,
18+
nonbsp: true,
19+
trailing: true,
20+
undef: true,
21+
unused: true
22+
},
23+
grunt: {
24+
options: {
25+
node: true,
26+
quotmark: 'single'
27+
},
28+
files: {
29+
src: ['Gruntfile.js']
30+
}
31+
},
32+
source: {
33+
options: {
34+
browser: true,
35+
camelcase: true,
36+
jquery: true,
37+
quotmark: 'single',
38+
globals: {
39+
define: true,
40+
require: true
41+
},
42+
},
43+
files: {
44+
src: ['jquery.cookie.js']
45+
}
46+
},
47+
tests: {
48+
options: {
49+
browser: true,
50+
jquery: true,
51+
qunit: true,
52+
'-W053': true
53+
},
54+
files: {
55+
src: ['test/**/*.js']
56+
}
1957
}
2058
},
2159
uglify: {
@@ -34,7 +72,7 @@ module.exports = function (grunt) {
3472
},
3573
files: [
3674
'jquery.cookie.js',
37-
'test/tests.js'
75+
'test/**/*.js'
3876
],
3977
tasks: 'default'
4078
},

0 commit comments

Comments
 (0)