aboutsummaryrefslogtreecommitdiffstats
path: root/tests/RUNNING_TESTS.md
diff options
context:
space:
mode:
authorMaat <maat-pub@mageia.biz>2020-05-08 21:52:11 +0200
committerMaat <maat-pub@mageia.biz>2020-05-08 21:52:11 +0200
commit8ea437e30605e0f66b5220bf904a61d7c1d11ddd (patch)
treee0db2bb4a012d5b06a633160b19f62f4868ecd28 /tests/RUNNING_TESTS.md
parent36bc1870f21fac04736a1049c1d5b8e127d729f4 (diff)
parent2fdd46b36431ae0f58bb2e78e42553168db9a0ff (diff)
downloadforums-8ea437e30605e0f66b5220bf904a61d7c1d11ddd.tar
forums-8ea437e30605e0f66b5220bf904a61d7c1d11ddd.tar.gz
forums-8ea437e30605e0f66b5220bf904a61d7c1d11ddd.tar.bz2
forums-8ea437e30605e0f66b5220bf904a61d7c1d11ddd.tar.xz
forums-8ea437e30605e0f66b5220bf904a61d7c1d11ddd.zip
Merge remote-tracking branch 'upstream/prep-release-3.2.9'
Diffstat (limited to 'tests/RUNNING_TESTS.md')
-rw-r--r--tests/RUNNING_TESTS.md42
1 files changed, 37 insertions, 5 deletions
diff --git a/tests/RUNNING_TESTS.md b/tests/RUNNING_TESTS.md
index afd7caa709..12ae7fa687 100644
--- a/tests/RUNNING_TESTS.md
+++ b/tests/RUNNING_TESTS.md
@@ -30,7 +30,9 @@ Some of the functionality in phpBB and/or the test suite uses additional
PHP extensions. If these extensions are not loaded, respective tests
will be skipped:
-- apc (APC cache driver)
+- apc (APC cache driver, php5 only)
+- apcu (APCu cache driver - native API, php7+)
+- apcu_bc, apcu (APCu cache driver - APC API, php7+)
- bz2 (compress tests)
- mysql, pdo_mysql (MySQL database driver)
- mysqli, pdo_mysql (MySQLi database driver)
@@ -117,11 +119,20 @@ directory (above phpBB):
$ phpBB/vendor/bin/phpunit
+To generate an xml log file, run:
+
+ $ phpBB/vendor/bin/phpunit --log-junit tests/tmp/log/log.xml
+
+If you are getting a memory exhausted error after running a few tests, you can try running:
+
+ $ phpBB/vendor/bin/phpunit -d memory_limit=2048M
+
Slow tests
--------------
-Certain tests, such as the UTF-8 normalizer or the DNS tests tend to be slow.
-Thus these tests are in the `slow` group, which is excluded by default. If you
+Certain tests, such as the DNS tests tend to be slow.
+Thus these tests are in the `slow` group, which is excluded by default. You can
+enable slow tests by copying the phpunit.xml.all file to phpunit.xml. If you
only want the slow tests, run:
$ phpBB/vendor/bin/phpunit --group slow
@@ -132,14 +143,14 @@ If you want all tests, run:
Functional tests
------------------
+================
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.
phpBB allows you to write such tests.
Running
-=======
+-------
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
@@ -159,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
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. They 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
================