Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Update grunt.js with seperate configs for qunit.js and grunt.js, also…

… add tests but disable for now, not passing yet. Add grunt to devDependencies
  • Loading branch information...
commit 5d90742b5c3820900c6065e8003af92c69a09386 1 parent f962600
Jörn Zaefferer authored March 10, 2012

Showing 2 changed files with 40 additions and 21 deletions. Show diff stats Hide diff stats

  1. 56  grunt.js
  2. 5  package.json
56  grunt.js
@@ -6,29 +6,45 @@ config.init({
6 6
     files: ['test/index.html']
7 7
   },
8 8
   lint: {
9  
-    // TODO lint test files: 'test/**/*.js' - needs seperate globals list
10  
-    files: ['grunt.js', 'qunit/*.js']
  9
+    qunit: 'qunit/qunit.js',
  10
+    grunt: 'grunt.js'
  11
+    // TODO need to figure out which warnings to fix and which to disable
  12
+    // tests: 'test/*.js'
11 13
   },
12 14
   jshint: {
13  
-    options: {
14  
-      bitwise: true,
15  
-      curly: true,
16  
-      trailing: true,
17  
-      immed: true,
18  
-      latedef: false,
19  
-      newcap: true,
20  
-      noarg: false,
21  
-      noempty: true,
22  
-      nonew: true,
23  
-      sub: true,
24  
-      undef: true,
25  
-      eqnull: true,
26  
-      browser: true,
27  
-      proto: true
  15
+    qunit: {
  16
+      options: {
  17
+        browser: true,
  18
+        bitwise: true,
  19
+        curly: true,
  20
+        trailing: true,
  21
+        immed: true,
  22
+        latedef: false,
  23
+        newcap: true,
  24
+        noarg: false,
  25
+        noempty: true,
  26
+        nonew: true,
  27
+        sub: true,
  28
+        undef: true,
  29
+        eqnull: true,
  30
+        proto: true
  31
+      },
  32
+      globals: {
  33
+        jQuery: true,
  34
+        exports: true
  35
+      }
28 36
     },
29  
-    globals: {
30  
-      jQuery: true,
31  
-      exports: true
  37
+    tests: {
  38
+      tests: {
  39
+        globals: {
  40
+          module: true,
  41
+          test: true,
  42
+          ok: true,
  43
+          equal: true,
  44
+          deepEqual: true,
  45
+          QUnit: true
  46
+        }
  47
+      }
32 48
     }
33 49
   }
34 50
 });
5  package.json
@@ -25,5 +25,8 @@
25 25
     "unit",
26 26
     "jquery"
27 27
   ],
28  
-  "main": "qunit/qunit.js"
  28
+  "main": "qunit/qunit.js",
  29
+  "devDependencies": {
  30
+    "grunt": "0.2.x"
  31
+  }
29 32
 }

0 notes on commit 5d90742

Please sign in to comment.
Something went wrong with that request. Please try again.