Skip to content

CasperJS end to end test integration for meteor using velocity

License

Notifications You must be signed in to change notification settings

logankoester/meteor-casperjs

 
 

Repository files navigation

meteor-casperjs

CasperJS end to end test integration for meteor using velocity.

This is a fork of blazer82/meteor-casperjs (nblazer:casperjs).

Note that PhantomJS 2.0 does not support CoffeeScript tests. See blazer82#9

Installation

meteor add ldk:casperjs

Caution

This package doesn't ship with CasperJS. You need to have a running CasperJS installation on your system!

Usage

Create tests in your tests directory tests/casperjs/[*.js|*.coffee] Sample file:

casper.test.begin "Sample Test", 2, (test) ->
   casper.start casper.cli.get('rootUrl'), ->
      @waitForSelector "body", ->
         test.assert true, "True is true"

   casper.then ->
      test.assertNot false, "False is false"

   casper.run -> test.done()

Integrates with velocity:html-reporter.

Run your tests with meteor run --test.

In your tests, parse the --rootUrl=<URL> option with casper.cli.get('rootUrl') to hit the soft-mirror.

About

CasperJS end to end test integration for meteor using velocity

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • CoffeeScript 81.3%
  • JavaScript 18.7%