Mercurial > hg > soundsoftware-site
annotate test/functional/ldap_auth_sources_controller.rb @ 1474:c4436fec34bf bug_494
Close obsolete branch bug_494
author | Chris Cannam |
---|---|
date | Sat, 10 Nov 2012 13:57:53 +0000 |
parents | cbb26bc654de |
children |
rev | line source |
---|---|
Chris@909 | 1 require File.expand_path('../../test_helper', __FILE__) |
Chris@0 | 2 |
Chris@0 | 3 class LdapAuthSourcesControllerTest < ActionController::TestCase |
Chris@0 | 4 |
Chris@0 | 5 def setup |
Chris@0 | 6 @request.session[:user_id] = 1 |
Chris@0 | 7 end |
Chris@0 | 8 |
Chris@0 | 9 context "get :new" do |
Chris@0 | 10 setup do |
Chris@0 | 11 get :new |
Chris@0 | 12 end |
Chris@0 | 13 |
Chris@0 | 14 should_assign_to :auth_source |
Chris@0 | 15 should_respond_with :success |
Chris@0 | 16 should_render_template :new |
Chris@0 | 17 |
Chris@0 | 18 should "initilize a new AuthSource" do |
Chris@0 | 19 assert_equal AuthSourceLdap, assigns(:auth_source).class |
Chris@0 | 20 assert assigns(:auth_source).new_record? |
Chris@0 | 21 end |
Chris@0 | 22 end |
Chris@0 | 23 end |