Adam Bouqdib 11 vuotta sitten
vanhempi
commit
1b087a6c19
9 muutettua tiedostoa jossa 29 lisäystä ja 14 poistoa
  1. 1 6
      .travis.yml
  2. 9 3
      Gruntfile.js
  3. 14 0
      libs/.jshintrc
  4. 0 0
      libs/jquery-loader.js
  5. 0 0
      libs/jquery/jquery.js
  6. 0 0
      libs/qunit/qunit.css
  7. 0 0
      libs/qunit/qunit.js
  8. 2 2
      package.json
  9. 3 3
      test/smoove.html

+ 1 - 6
.travis.yml

@@ -1,8 +1,3 @@
 language: node_js
 node_js:
-  - "0.8"
-before_install: 
-  - npm install -g npm
-  - npm install -g grunt-cli
-install: npm install
-before_script: grunt build
+  - "0.8"

+ 9 - 3
Gruntfile.js

@@ -35,8 +35,14 @@ module.exports = function(grunt) {
       },
     },
     qunit: {
-      files: ['test/**/*.html']
-    },
+  all: {
+    options: {
+      urls: ['1.9.0', '2.0.0b1'].map(function(version) {
+        return 'http://0.0.0.0:<%= connect.server.options.port %>/test/plugin.html?jquery=' + version;
+      })
+    }
+  }
+},
     jshint: {
       options: {
         jshintrc: true
@@ -85,6 +91,6 @@ module.exports = function(grunt) {
 
   // Default task.
   grunt.registerTask('default', ['jshint', 'qunit', 'clean', 'concat', 'uglify']);
-  
+  grunt.registerTask('test', ['connect', 'jshint', 'qunit']);
 
 };

+ 14 - 0
libs/.jshintrc

@@ -0,0 +1,14 @@
+{
+  "curly": true,
+  "eqeqeq": true,
+  "immed": true,
+  "latedef": true,
+  "newcap": true,
+  "noarg": true,
+  "sub": true,
+  "undef": true,
+  "unused": true,
+  "boss": true,
+  "eqnull": true,
+  "node": true
+}

+ 0 - 0
test/libs/jquery-loader.js → libs/jquery-loader.js


+ 0 - 0
test/libs/jquery/jquery.js → libs/jquery/jquery.js


+ 0 - 0
test/libs/qunit/qunit.css → libs/qunit/qunit.css


+ 0 - 0
test/libs/qunit/qunit.js → libs/qunit/qunit.js


+ 2 - 2
package.json

@@ -27,7 +27,7 @@
   "author": "Adam Bouqdib <[email protected]> (http://abemedia.co.uk/)",
   "license": "GPL-2.0",
   "scripts": {
-    "test": "grunt qunit"
+    "test": "grunt test"
   },
   "devDependencies": {
     "grunt-contrib-jshint": "~0.10.0",
@@ -36,7 +36,7 @@
     "grunt-contrib-uglify": "~0.2.0",
     "grunt-contrib-watch": "~0.4.0",
     "grunt-contrib-clean": "~0.4.0",
-    "grunt": "~0.4.5",
     "grunt-contrib-connect": "^0.8.0"
+    "grunt": "~0.4.5",
   }
 }

+ 3 - 3
test/smoove.html

@@ -4,10 +4,10 @@
   <meta charset="utf-8">
   <title>jQuery Smoove - Gorgeous CSS3 Scroll Effects Test Suite</title>
   <!-- Load local jQuery. This can be overridden with a ?jquery=___ param. -->
-  <script src="libs/jquery-loader.js"></script>
+  <script src="../libs/jquery-loader.js"></script>
   <!-- Load local QUnit. -->
-  <link rel="stylesheet" href="libs/qunit/qunit.css" media="screen">
-  <script src="libs/qunit/qunit.js"></script>
+  <link rel="stylesheet" href="../libs/qunit/qunit.css" media="screen">
+  <script src="../libs/qunit/qunit.js"></script>
   <!-- Load local lib and tests. -->
   <script src="../src/jquery.smoove.js"></script>
   <script src="smoove_test.js"></script>