Run Tests on 800+ Browser/OS Platforms with 1 CLI Command
YUI Test Made Awesome on the Sauce Labs Cloud - Quick Tutorial*
If you use YUI, or are considering using it, you’re probably planning to run your YUI tests in a real browser. If you do this, it’s important to run YUI tests on as many real browsers as possible - to make sure your tests pass on all or most of the platforms used to view your application. Unfortunately, this can get complex.
Sure, you can install Chrome, Firefox, and Safari (if you’re on Mac), point each of the browsers to the YUI HTML test file and see if your tests passed or failed. But what about:
- Testing on all the different versions of each browser?
- Internet Explorer (if you’re on Mac) or Safari (if you’re on Windows)?
- Testing the same browsers on the other operating system? (your code could respond differently)
To make sure you’re covering all the relevant browser/OS combinations, you’ll need to install at least a few dozen browsers on 2-3 virtual machines - and run the YUI Test HTML file in all of them.
There is YUI Yeti which helps you automatically launch the tests on your local browsers (note that Yeti is not tested on Windows). But can you really keep up with installing all the new versions of each browser on all those virtual machines? And do you have a strong enough machine to run all your unit tests on numerous real browsers with every build?
Sauce Labs to the rescue - YUI testing made awesome
Here’s where we come in. Sauce can help you run your YUI tests on as many as 500 Browser/OS combinations automatically in our cloud testing platform:
If you have an existing test runner, you can simply send us your YUI tests through a convenient REST API, and continue working as usual, while leveraging the power of the Sauce cloud. See our REST API documentation.
If you’re new to unit testing or use Grunt, our tutorial below will show you a quick setup, after which you’ll run your tests on all those platforms with one CLI command:
$ grunt testwe’ll then show you how to feed the results straight to your CI server.
Let us introduce ourselves
Sauce Labs is all about making automated testing awesome. Our cloud testing platform has run over 90 million browser tests for thousands of organizations including Salesforce.com, Yelp, Firefox, and the BBC. Our battle-tested platform now enables running JS unit tests in many real browsers quickly and easily. We are now using the same proven platform to help you run JS unit tests in real browsers on a large scale.
Keep in mind: Our cloud service isn’t free. We do have a 14-day free trial that gives you access to 90 hours of testing and up to 8 concurrent sessions. Beyond that, our paid plans start at $19 per month.
Now that we know each other a bit better, let’s get started! Read on for our quick tutorial.
About this YUI Test tutorial
If you have an existing test runner, this tutorial is not for you! Visit these links to use Sauce with Yeti, Karma, Mocha Sauce, or Intern, or for any other test runner, head on to our REST API documentation.
If you are new to unit testing or already use Grunt, read on!
OR - if you’re an existing user of YUI Yeti, no need for all that. Just see this blog post for a quick way to point YUI Yeti to the Sauce Cloud.
Does your project use different technologies/languages? No worries, Sauce supports Java, Python, Ruby, and many other programming languages. We’ve gone to great lengths to let you work with whatever languages or frameworks you already use.
We hope you enjoyed our tutorial and are ready to run your YUI Test unit tests on real browsers with the Sauce cloud!
Want more? Just sign up for a free trial of Sauce and get testing!