diff --git a/.gitignore b/.gitignore index 0b5ca38..1b874b4 100644 --- a/.gitignore +++ b/.gitignore @@ -9,6 +9,8 @@ iris-example/.settings/org.eclipse.jdt.core.prefs *.prefs + node_modules/* examples/todo-list/packed/* -/nbproject/private/ \ No newline at end of file +/nbproject/private/ +sauce_connect.log* \ No newline at end of file diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000..9b17583 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,15 @@ +language: node_js +install: +- npm install grunt-cli -g +- npm install vargs +- npm install +env: + global: + - secure: kpfQjirYiO26KzynOZ4Q/z9F7LTY4VKWMwVwYj8FZvXm/bjF/E+kvGCigtvo/8OqEGAO7QNeSf45LfHu1aZwBVpMdKK5kInFAKCK5durQp3cwsaws1thi0NYRbEt5npfXgvps3Mttdk85UmTVfAyHc5Den+THXQVulaFpzDb17M= + - secure: i3dBm8jpxqSZ95HjaPXXGGOX97oZbnGMCvEndXrMOn2iUUp773EIDsuTt8vupAF5QivcO2ZLMZccvaktU3ioIEunvFgcynsaPwmd4QCzBvCXQBJj7rQcJqGRDMnJJMSR2PkaccYoYujsaQYunrK1KmB17mIniQJpivqS+wQud10= +cache: + directories: + - node_modules +after_script: +- grunt test-saucelabs + diff --git a/Gruntfile.js b/Gruntfile.js index f55f9da..5469b43 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -1,6 +1,106 @@ /*global module:false*/ module.exports = function(grunt) { + var browsers = [ + { + browserName: "chrome", + platform: "Linux" + }, + { + browserName: "firefox", + platform: "Linux" + }, + { + browserName: "opera", + platform: "Linux" + }, + { + browserName: "android", + platform: "Linux" + }, + { + browserName: "chrome", + platform: "Windows 8" + }, + { + browserName: "firefox", + platform: "Windows 8" + }, + { + browserName: "internet explorer", + platform: "Windows 8" + }, + { + browserName: "chrome", + platform: "Windows 7" + }, + { + browserName: "firefox", + platform: "Windows 7" + }, + { + browserName: "internet explorer", + platform: "Windows 7", + version: "9" + }, + { + browserName: "internet explorer", + platform: "Windows 7", + version: "8" + }, + { + browserName: "opera", + platform: "Windows 7" + }, + { + browserName: "safari", + platform: "Windows 7" + }, + { + browserName: "chrome", + platform: "Windows XP" + }, + { + browserName: "firefox", + platform: "Windows XP" + }, + { + browserName: "internet explorer", + platform: "Windows XP", + version: "7" + }, + { + browserName: "internet explorer", + platform: "Windows XP", + version: "6" + }, + { + browserName: "chrome", + platform: "OS X 10.6" + }, + { + browserName: "firefox", + platform: "OS X 10.6" + }, + { + browserName: "safari", + platform: "OS X 10.6" + }, + { + browserName: "iphone", + platform: "OS X 10.6" + }, + { + browserName: "iphone", + platform: "OS X 10.8" + }, + { + browserName: "iphone", + platform: "OS X 10.9" + } + + ]; + var banner = '/*! <%= pkg.name %> - v<%= pkg.version %> - <%= grunt.template.today("yyyy-mm-dd") %>' + ' (<%= pkg.homepage %>) licensed <%= _.pluck(pkg.licenses, "type").join(", ") %> */\n'; @@ -63,6 +163,19 @@ module.exports = function(grunt) { $: true } } + }, + 'saucelabs-qunit': { + all: { + options: { + urls: ["http://localhost:8080/test/iris.html"], + tunnelTimeout: 5, + build: process.env.TRAVIS_JOB_ID, + concurrency: 3, + browsers: browsers, + testname: "qunit tests from saucelabs", + tags: ["master"] + } + } } }); @@ -92,10 +205,11 @@ module.exports = function(grunt) { grunt.registerTask('test', ['jshint', 'server', 'watch']); - grunt.loadNpmTasks('grunt-contrib-jshint'); - grunt.loadNpmTasks('grunt-contrib-uglify'); - grunt.loadNpmTasks('grunt-contrib-watch'); - grunt.loadNpmTasks('grunt-contrib-qunit'); - grunt.loadNpmTasks('grunt-contrib-concat'); + grunt.registerTask('test-saucelabs', ['jshint', 'server', 'concat', 'uglify', 'bower', 'saucelabs-qunit']); + + // Loading dependencies + for (var key in grunt.file.readJSON("package.json").devDependencies) { + if (key !== "grunt" && key.indexOf("grunt") === 0) grunt.loadNpmTasks(key); + } }; diff --git a/README.md b/README.md index 11a3eb8..c1b87a9 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,7 @@ +[![Build Status](https://travis-ci.org/IGZJavierPerez/iris.png?branch=master)](https://travis-ci.org/IGZJavierPerez/iris) + +[![Selenium Test Status](https://saucelabs.com/browser-matrix/surtich.svg?auth=861baeb3ee8833c887f16f59cbc41d1e)](https://saucelabs.com/u/surtich) + ![Iris](https://raw.github.com/thegameofcode/iris/gh-pages/images/iris-logo-white.png) Iris is not only another framework. diff --git a/package.json b/package.json index a1d5b05..744eca3 100644 --- a/package.json +++ b/package.json @@ -13,6 +13,7 @@ "grunt-contrib-watch": "~0.3.1", "grunt-contrib-jshint": "~0.4.3", "grunt-contrib-concat": "~0.2.0", - "grunt-contrib-qunit": "~0.2.1" + "grunt-contrib-qunit": "~0.2.1", + "grunt-saucelabs": "git://github.com/axemclion/grunt-saucelabs.git" } } diff --git a/test/iris.html b/test/iris.html index 6540003..b20f3f5 100644 --- a/test/iris.html +++ b/test/iris.html @@ -47,5 +47,19 @@
awesome test markup +