Commit 74b1d27b 74b1d27b10afe2bed3d3f5dfa7a4ec4e2cbe74bc by Laurent Jouanneau

refs #482: supports of --engine=slimerjs

This options allows to use SlimerJS (gecko) instead of PhantomJS (webkit)
1 parent fdf0d2f5
......@@ -148,6 +148,7 @@ casper.on('page.resource.requested', function(requestData, request) {
### Bugfixes & enhancements
- heavy lifting of casperjs bootstrap script
- closed [#482](https://github.com/n1k0/casperjs/issues/482) - support of Gecko (Firefox's engine) with [SlimerJS](http://slimerjs.org): new option --engine=slimerjs (experimental)
- fixed [#387](https://github.com/n1k0/casperjs/issues/387) - Setting viewport isn't quite synchronous
- fixed [#410](https://github.com/n1k0/casperjs/issues/410) - trigger `mousedown` and `mousedown` events on click
- fixed [#433](https://github.com/n1k0/casperjs/issues/433) - `assertField("field", "")` will always pass even though the `field` doesn't exist
......
......@@ -12,7 +12,8 @@
>- ![Build Status](https://travis-ci.org/n1k0/casperjs.png?branch=1.0) `1.0` branch
>- ![Build Status](https://travis-ci.org/n1k0/casperjs.png?branch=master) `master` branch
CasperJS is a navigation scripting & testing utility for [PhantomJS](http://www.phantomjs.org/).
CasperJS is a navigation scripting & testing utility for [PhantomJS](http://www.phantomjs.org/)
and [SlimerJS](http://slimerjs.org/).
It eases the process of defining a full navigation scenario and provides useful
high-level functions, methods & syntaxic sugar for doing common tasks such as:
......
......@@ -31,11 +31,56 @@ SUPPORTED_ENGINES = {
'remote-debugger-autorun',
'script-encoding',
'ssl-protocol',
'ssl-certificates-path',
'web-security',
'webdriver',
'webdriver-logfile',
'webdriver-loglevel'
'webdriver-selenium-grid-hub',
'wd',
'w',
],
'env_varname': 'PHANTOMJS_EXECUTABLE',
'default_exec' : 'phantomjs'
}
},
'slimerjs': {
'native_args': [
'P',
'jsconsole',
'CreateProfile',
'profile',
#phantomjs options
'cookies-file',
'config',
'debug',
'disk-cache',
'ignore-ssl-errors',
'load-images',
'load-plugins',
'local-storage-path',
'local-storage-quota',
'local-to-remote-url-access',
'max-disk-cache-size',
'output-encoding',
'proxy',
'proxy-auth',
'proxy-type',
'remote-debugger-port',
'remote-debugger-autorun',
'script-encoding',
'ssl-protocol',
'ssl-certificates-path',
'web-security',
'webdriver',
'webdriver-logfile',
'webdriver-loglevel'
'webdriver-selenium-grid-hub',
'wd',
'w',
],
'env_varname': 'SLIMERJS_EXECUTABLE',
'default_exec' : 'slimerjs'
},
}
ENGINE = 'phantomjs'
......
......@@ -89,10 +89,12 @@ Execution results:
.. index:: Logging, log levels
The `casperjs` command has two available options:
The `casperjs` command has three available options:
- ``--direct``: to prints out log messages to the console
- ``--log-level=[debug|info|warning|error]`` to set the :ref:`logging level <logging>`
- ``--engine=[phantomjs|slimerjs]`` to select the browser engine you want to use. CasperJS
supports PhantomJS (default) that runs Webkit, and SlimerJS that runs Gecko.
Example:
......@@ -109,7 +111,7 @@ Last but not least, you can still use all PhantomJS standard CLI options as you
.. hint::
To remember what the native phantomjs available cli options are, run the ``phantomjs --help`` command.
SlimerJS supports almost same options as PhantomJS.
.. index:: Raw values
......
......@@ -10,11 +10,15 @@ CasperJS can be installed on most Linuxes, OSX and Windows.
Prerequisites
-------------
.. index:: PhantomJS, Python
.. index:: PhantomJS, Python, SlimerJS
- PhantomJS_ 1.8.1 or greater. Installation instructions can be found `here <http://phantomjs.org/download.html>`_
- Python_ 2.6 or greater
.. versionadded:: 1.1
- Experimental: SlimerJS_ 0.7 or greater to run your tests against Gecko (Firefox) instead of Webkit.
.. note::
.. versionadded:: 1.0
......@@ -167,3 +171,4 @@ Known Bugs & Limitations
.. _PhantomJS: http://phantomjs.org/
.. _Python: http://python.org/
.. _SlimerJS: http://slimerjs.org/
......