2009-10-18 00:37:23 +04:00
|
|
|
Installing gems for testing
|
|
|
|
===========================
|
|
|
|
|
2012-02-19 18:30:46 +04:00
|
|
|
Remove your .bundle/config if you've already installed Redmine without
|
2012-06-12 23:14:06 +04:00
|
|
|
the test dependencies. Then, run `bundle install`.
|
2009-10-18 00:37:23 +04:00
|
|
|
|
2008-03-12 23:28:49 +03:00
|
|
|
Running Tests
|
|
|
|
=============
|
|
|
|
|
2009-01-12 07:44:01 +03:00
|
|
|
Run `rake --tasks test` to see available tests.
|
2012-06-12 23:14:06 +04:00
|
|
|
Run `rake test` to run the entire test suite (note that this will drop
|
|
|
|
and recreate your test database)
|
|
|
|
|
|
|
|
You can run `ruby test/unit/issue_test.rb` for running a single test case.
|
2008-03-12 23:28:49 +03:00
|
|
|
|
2011-09-05 14:33:59 +04:00
|
|
|
Before running tests, you need to configure both development
|
2009-11-08 16:15:59 +03:00
|
|
|
and test databases.
|
2008-03-12 23:28:49 +03:00
|
|
|
|
2009-01-12 07:44:01 +03:00
|
|
|
Creating test repositories
|
2012-06-12 23:14:06 +04:00
|
|
|
==========================
|
2009-01-12 07:44:01 +03:00
|
|
|
|
|
|
|
Redmine supports a wide array of different version control systems.
|
|
|
|
To test the support, a test repository needs to be created for each of those.
|
2008-03-12 23:28:49 +03:00
|
|
|
|
2009-01-12 07:44:01 +03:00
|
|
|
Run `rake --tasks test:scm:setup` for a list of available test-repositories or
|
2012-06-12 23:14:06 +04:00
|
|
|
run `rake test:scm:setup:all` to set up all of them. The repositories are
|
|
|
|
unpacked into {redmine_root}/tmp/test.
|
|
|
|
|
|
|
|
If the test repositories are not present, the tests that need them will be
|
|
|
|
skipped.
|
2008-09-30 04:02:46 +04:00
|
|
|
|
2010-02-16 19:40:50 +03:00
|
|
|
Creating a test ldap database
|
|
|
|
=============================
|
|
|
|
|
|
|
|
Redmine supports using LDAP for user authentications. To test LDAP
|
|
|
|
with Redmine, load the LDAP export from test/fixtures/ldap/test-ldap.ldif
|
2012-06-12 23:14:06 +04:00
|
|
|
into a testing LDAP server. Make sure that the LDAP server can be accessed
|
2010-02-16 19:40:50 +03:00
|
|
|
at 127.0.0.1 on port 389.
|
|
|
|
|
2012-06-12 23:14:06 +04:00
|
|
|
Setting up the test LDAP server is beyond the scope of this documentation.
|
2010-02-16 19:40:50 +03:00
|
|
|
The OpenLDAP project provides a simple LDAP implementation that should work
|
|
|
|
good as a test server.
|
2012-06-12 23:14:06 +04:00
|
|
|
|
|
|
|
If the LDAP is not available, the tests that need it will be skipped.
|