summaryrefslogtreecommitdiffstats
path: root/test/test_helper.rb
diff options
context:
space:
mode:
authorEric Davis <edavis@littlestreamsoftware.com>2010-02-16 16:40:50 +0000
committerEric Davis <edavis@littlestreamsoftware.com>2010-02-16 16:40:50 +0000
commit7b6b147761a689aa07d83068e77348a3d3f84cfa (patch)
treee7a8166d2adc4bdf5924672f81b4b6a508e17ffd /test/test_helper.rb
parent49bfee053593604ad2a3eb487ac1e5b9fef5dd8c (diff)
downloadredmine-7b6b147761a689aa07d83068e77348a3d3f84cfa.tar.gz
redmine-7b6b147761a689aa07d83068e77348a3d3f84cfa.zip
Added some tests for the LDAP authentication.
Includes an export of an LDAP database to use in testing. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@3438 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/test_helper.rb')
-rw-r--r--test/test_helper.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/test/test_helper.rb b/test/test_helper.rb
index 8e7927ab3..484678efc 100644
--- a/test/test_helper.rb
+++ b/test/test_helper.rb
@@ -76,6 +76,11 @@ class ActiveSupport::TestCase
saved_settings.each {|k, v| Setting[k] = v}
end
+ def self.ldap_configured?
+ @test_ldap = Net::LDAP.new(:host => '127.0.0.1', :port => 389)
+ return @test_ldap.bind
+ end
+
# Shoulda macros
def self.should_render_404
should_respond_with :not_found