Skip to content

aripalo/CasperJS-e2e-testing

Repository files navigation

CasperJS testing

Examples of using CasperJS for end-to-end testing where we load Google and do a search, then we test if we are on the right results page and did we get enough results.

Prequisites

Requires PhantomJS to be installed. You can check it by typing phantomjs -v in your terminal.

Installation

Run npm install on this project's root folder

Usage

You have 2 different ways of testing:

Also for the sake of example, both CoffeeScript and vanilla JavaScript versions are provided.

Jenkins CI integration

To integrate these end-to-end tests with Jenkins we use XUnit XML files.

For pure CasperJS, use: casperjs test with-pure-casper.coffee --xunit=xunit.xml

For CasperJS with Mocha plugin, use: mocha-casperjs --reporter=xunit with-casper-mocha-chai.coffee > xunit.xml

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published