O'Reilly logo

Ext JS Application Development Blueprints by Colin Ramsay

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Testing with robots

Now that we've covered a method of testing the fine detail of our code, let's look at a completely different way of running functional checks across the entire application. For this, we'll need a new tool: CasperJS. It allows you to drive a "headless browser"—one without any user interface—navigate around an application, and run evaluations on what we find. The first step is installation, which varies depending on the platform. Instructions for the same can be found at http://docs.casperjs.org/en/latest/installation.html.

When complete, we'll have a CasperJS command available to run.

With Jasmine, we were using the behavior-driven method of testing with expectations to verify the code. In CasperJS, we go back to using the assertion ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required