summaryrefslogtreecommitdiffstats
path: root/test/functional
diff options
context:
space:
mode:
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>2013-05-10 04:37:21 +0000
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>2013-05-10 04:37:21 +0000
commita3766c528194b585d1882bc68c740f1c592c207b (patch)
tree41a3da19eaae152af686672c2d45556fd0e8286b /test/functional
parentaf2053fe13aeb5fdf9b1126962516d2c170f673c (diff)
downloadredmine-a3766c528194b585d1882bc68c740f1c592c207b.tar.gz
redmine-a3766c528194b585d1882bc68c740f1c592c207b.zip
use with_settings at test_get_new_with_default_start_date_is_creation_date of IssuesControllerTest
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@11819 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/functional')
-rw-r--r--test/functional/issues_controller_test.rb16
1 files changed, 8 insertions, 8 deletions
diff --git a/test/functional/issues_controller_test.rb b/test/functional/issues_controller_test.rb
index 5e2af2132..fd6726347 100644
--- a/test/functional/issues_controller_test.rb
+++ b/test/functional/issues_controller_test.rb
@@ -1573,14 +1573,14 @@ class IssuesControllerTest < ActionController::TestCase
end
def test_get_new_with_default_start_date_is_creation_date
- Setting.default_issue_start_date_to_creation_date = 1
-
- @request.session[:user_id] = 2
- get :new, :project_id => 1, :tracker_id => 1
- assert_response :success
- assert_template 'new'
-
- assert_select 'input[name=?][value=?]', 'issue[start_date]', Date.today.to_s
+ with_settings :default_issue_start_date_to_creation_date => 1 do
+ @request.session[:user_id] = 2
+ get :new, :project_id => 1, :tracker_id => 1
+ assert_response :success
+ assert_template 'new'
+ assert_select 'input[name=?][value=?]', 'issue[start_date]',
+ Date.today.to_s
+ end
end
def test_get_new_form_should_allow_attachment_upload