Moves the LDAP test server to a fixture.

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@3490 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang
2010-02-26 08:42:40 +00:00
parent 7ae53845ac
commit 899f06612a
3 changed files with 18 additions and 24 deletions
+3 -11
View File
@@ -18,7 +18,8 @@
require File.dirname(__FILE__) + '/../test_helper'
class AuthSourceLdapTest < ActiveSupport::TestCase
fixtures :auth_sources
def setup
end
@@ -37,16 +38,7 @@ class AuthSourceLdapTest < ActiveSupport::TestCase
if ldap_configured?
context '#authenticate' do
setup do
@auth = AuthSourceLdap.generate!(:name => 'on the fly',
:host => '127.0.0.1',
:port => 389,
:base_dn => 'OU=Person,DC=redmine,DC=org',
:attr_login => 'uid',
:attr_firstname => 'givenName',
:attr_lastname => 'sn',
:attr_mail => 'mail',
:onthefly_register => true)
@auth = AuthSourceLdap.find(1)
end
context 'with a valid LDAP user' do