summaryrefslogtreecommitdiff
path: root/plugins/libkolab/tests/README.md
diff options
context:
space:
mode:
authorThomas Bruederli <bruederli@kolabsys.com>2015-02-03 21:14:06 (GMT)
committerThomas Bruederli <bruederli@kolabsys.com>2015-02-03 21:14:06 (GMT)
commit17e6662a23ac104f17375e08c4f286cb519a1a32 (patch)
tree9afb6db7a42cba53bae278105eeaf6aa34cfb5ad /plugins/libkolab/tests/README.md
parent29645a47367a8e5927bde5ac55370eae191ba9f8 (diff)
downloadroundcubemail-plugins-kolab-17e6662a23ac104f17375e08c4f286cb519a1a32.tar.gz
Add unit/functional tests for kolab_storage_folder error checking methods
Diffstat (limited to 'plugins/libkolab/tests/README.md')
-rw-r--r--plugins/libkolab/tests/README.md43
1 files changed, 43 insertions, 0 deletions
diff --git a/plugins/libkolab/tests/README.md b/plugins/libkolab/tests/README.md
new file mode 100644
index 0000000..942822b
--- /dev/null
+++ b/plugins/libkolab/tests/README.md
@@ -0,0 +1,43 @@
+libkolab plugin tests
+=====================
+
+In order to run the functional tests for libkolab classes, some configuration
+for the Roundcube test instance need to be created. Along with the default
+config for a given Roundcube instance, you should provide a config specifically
+for running tests. To do so, create a config file named `config-test.inc.php`
+in the regular Roundcube config dir. That should provide specific `db_dsnw` and
+`default_host` values for testing purposes as well as the credentials of a
+valid IMAP user account used for running the tests with.
+
+Add these config options used by the libkolab tests:
+
+```
+ // Unit tests settings
+ $config['tests_username'] = 'roundcube.test@example.org';
+ $config['tests_password'] = '<test-account-password>';
+ $config['default_host'] = '<kolab-server>';
+
+ // disable all plugins
+ $config['plugins'] = array();
+```
+
+WARNING
+-------
+Please note that the configured IMAP account as well as the Roundcube database
+configred in `db_dsnw` will be wiped and filled with test data in every test
+run. Under no circumstances you should use credentials of a production database
+or email account!
+
+
+Run the tests
+-------------
+
+The tests are based on PHPUnit and need to be exected from the Roundcube
+test directory in order to load and initialize the Roundcube framework context.
+
+To execute individual tests, call `phpunit` from the tests directory:
+
+```
+ cd <roundcube-dir>/tests/
+ phpunit ../plugins/libkolab/tests/<filename>
+``` \ No newline at end of file