Files
openlayers/test
Tom Payne a0b1d74bb5 Merge pull request #337 from Turbo87/polyline
Added ol.parser.polyline module
2013-03-11 13:55:04 -07:00
..
2012-06-18 18:15:51 +02:00
2013-02-18 14:44:35 +01:00
2013-01-31 10:18:21 +01:00

Included in this directory

  • ol.html - the web page used to run the test suite.

  • spec - includes the OpenLayers test/spec files.

  • jasmine-1.2.0 - includes the Jasmine Testing Framework. https://github.com/pivotal/jasmine

  • jasmine-extensions.js - includes OpenLayers-specific extensions to Jasmine.

  • phantom-jasmine - a PhantomJS script and a console reporter to for headless testing. Comes from https://github.com/jcarver989/phantom-jasmine.

Run the test suite with PhantomJS

With PhantomJS installed, and assuming phantomjs is in the PATH:

$ phantomjs phantom-jasmine/run_jasmine_test.coffee ol.html

(Works with PhantomJS 1.6.1, untested with other versions.)

This command can also be run by doing ./build.py test at the root of ol3.

Make sure that the polvr web server is running (./build.py serve), otherwise you will most likely see something like 0 specs, 0 failures in 0.001s..

Tip for TDD'ers: to make PhantomJS run the test suite continuously each time a spec file is changed you can use nosier (http://pypi.python.org/pypi/nosier) and do nosier -p test -p src "./build.py test".