mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-08 04:18:52 +00:00
[ticket/15516] Add instructions for running UI tests
PHPBB3-15516
This commit is contained in:
parent
7f6ececf95
commit
3469545e3a
1 changed files with 23 additions and 2 deletions
|
@ -143,14 +143,14 @@ If you want all tests, run:
|
||||||
|
|
||||||
|
|
||||||
Functional tests
|
Functional tests
|
||||||
-----------------
|
================
|
||||||
|
|
||||||
Functional tests test software the way a user would. They simulate a user
|
Functional tests test software the way a user would. They simulate a user
|
||||||
browsing the website, but they do these steps in an automated way.
|
browsing the website, but they do these steps in an automated way.
|
||||||
phpBB allows you to write such tests.
|
phpBB allows you to write such tests.
|
||||||
|
|
||||||
Running
|
Running
|
||||||
=======
|
-------
|
||||||
|
|
||||||
Running the tests requires your phpBB3 repository to be accessible through a
|
Running the tests requires your phpBB3 repository to be accessible through a
|
||||||
local web server. You will need to supply the URL to the webserver in
|
local web server. You will need to supply the URL to the webserver in
|
||||||
|
@ -170,6 +170,27 @@ If you only want the functional tests, run:
|
||||||
This will change your board's config.php file, but it makes a backup at
|
This will change your board's config.php file, but it makes a backup at
|
||||||
config_dev.php, so you can restore it after the test run is complete.
|
config_dev.php, so you can restore it after the test run is complete.
|
||||||
|
|
||||||
|
UI tests
|
||||||
|
========
|
||||||
|
|
||||||
|
UI tests are functional tests that also support running JavaScript in a
|
||||||
|
headless browser. These should be used when functionality that is only
|
||||||
|
executed using JS needs to be tested. The require a running
|
||||||
|
[PhantomJS WebDriver instance](http://phantomjs.org/). The executable can
|
||||||
|
either be downloaded from [PhantomJS](http://phantomjs.org/download.html)
|
||||||
|
or alternatively be installed with npm:
|
||||||
|
|
||||||
|
$ npm install -g phantomjs-prebuilt
|
||||||
|
|
||||||
|
You might have to run the command as superuser / administrator on some
|
||||||
|
systems. Afterwards, a new WebDriver instance can be started via command
|
||||||
|
line:
|
||||||
|
|
||||||
|
$ phantomjs --webdriver=127.0.0.1:8910
|
||||||
|
|
||||||
|
Port 8910 is the default port that will be used by UI tests to connect
|
||||||
|
to the WebDriver instance.
|
||||||
|
|
||||||
More Information
|
More Information
|
||||||
================
|
================
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue