dwyl / learn-qunit

:white_check_mark: A quick introduction to JavaScript unit testing with QUnit
52 stars 10 forks source link

Add SauceLabs Tests #8

Open nelsonic opened 9 years ago

nelsonic commented 9 years ago

Replace browser swarm screenshot with SauceLabs! :wink: https://saucelabs.com/javascript/qunit

nelsonic commented 9 years ago
curl -X POST https://saucelabs.com/rest/v1/nelsonic/js-tests -u nelsonic:PASSWORD \
-d platforms='[["Windows 8", "internet explorer", "10"], ["OS X 10.8", "safari", "6"]]' \
-d url="https://qunit.herokuapp.com/test/test.html?coverage=true" \
-d framework=qunit \
-d name=learn-qunit \
nelsonic commented 9 years ago

https://github.com/bernii/yummy-pasta/blob/master/test-qunit/resources/tests.js

nelsonic commented 9 years ago

Got answer to my SauceLabs issue: https://gist.github.com/jraczak/e8f26d7719db15e3e226

curl https://saucelabs.com/rest/v1/[username]/js-tests \
-X POST \
-u [username]:[username] \
-H 'Content-Type: application/json' \
--data '{
    "platforms": [["Windows 8", "internet explorer", "10"]],
    "url": "https://qunit.herokuapp.com/test/test.html?coverage=true",
    "framework": "qunit"}'
nelsonic commented 9 years ago

Got it working with:

curl https://saucelabs.com/rest/v1/nelsonic/js-tests \
-X POST \
-u nelsonic:PASSWORD \
-H 'Content-Type: application/json' \
--data '{
    "platforms": [
      ["Windows 8.1", "internet explorer", "11"],
      ["Windows 8", "internet explorer", "10"],
      ["Windows 7", "internet explorer", "9"],
      ["Windows 7", "internet explorer", "8"],
      ["Windows XP", "internet explorer", "7"],
      ["OS X 10.8", "safari", "6"],
      ["OS X 10.8", "chrome", "37"],
      ["Linux", "chrome", "30"]

    ],
    "url": "https://qunit.herokuapp.com/test/test.html?coverage=true",
    "framework": "qunit"}'