summaryrefslogtreecommitdiffstats
path: root/test/functional/custom_field_enumerations_controller_test.rb
diff options
context:
space:
mode:
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>2020-10-28 14:42:26 +0000
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>2020-10-28 14:42:26 +0000
commit723125eedb95a94868618b6b81ecddcfff7aa0fc (patch)
tree99c5c57674605368d1119abaea73558ce60a5ea6 /test/functional/custom_field_enumerations_controller_test.rb
parent540ca83e7ae8f1654294f5ada120e5ca9b21cb49 (diff)
downloadredmine-723125eedb95a94868618b6b81ecddcfff7aa0fc.tar.gz
redmine-723125eedb95a94868618b6b81ecddcfff7aa0fc.zip
fix source indent of CustomFieldEnumerationsControllerTest
git-svn-id: http://svn.redmine.org/redmine/trunk@20220 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/functional/custom_field_enumerations_controller_test.rb')
-rw-r--r--test/functional/custom_field_enumerations_controller_test.rb36
1 files changed, 28 insertions, 8 deletions
diff --git a/test/functional/custom_field_enumerations_controller_test.rb b/test/functional/custom_field_enumerations_controller_test.rb
index 9ead8f4b2..93a1dbc64 100644
--- a/test/functional/custom_field_enumerations_controller_test.rb
+++ b/test/functional/custom_field_enumerations_controller_test.rb
@@ -32,9 +32,12 @@ class CustomFieldEnumerationsControllerTest < Redmine::ControllerTest
end
def test_index
- get :index, :params => {
+ get(
+ :index,
+ :params => {
:custom_field_id => @field.id
}
+ )
assert_response :success
assert_select 'ul#custom_field_enumerations' do
@@ -44,12 +47,15 @@ class CustomFieldEnumerationsControllerTest < Redmine::ControllerTest
def test_create
assert_difference 'CustomFieldEnumeration.count' do
- post :create, :params => {
+ post(
+ :create,
+ :params => {
:custom_field_id => @field.id,
:custom_field_enumeration => {
:name => 'Baz'
}
}
+ )
assert_redirected_to "/custom_fields/#{@field.id}/enumerations"
end
@@ -62,19 +68,24 @@ class CustomFieldEnumerationsControllerTest < Redmine::ControllerTest
def test_create_xhr
assert_difference 'CustomFieldEnumeration.count' do
- post :create, :params => {
+ post(
+ :create,
+ :params => {
:custom_field_id => @field.id,
:custom_field_enumeration => {
:name => 'Baz'
}
},
:xhr => true
+ )
assert_response :success
end
end
def test_update_each
- put :update_each, :params => {
+ put(
+ :update_each,
+ :params => {
:custom_field_id => @field.id,
:custom_field_enumerations => {
@bar.id.to_s => {
@@ -87,9 +98,9 @@ class CustomFieldEnumerationsControllerTest < Redmine::ControllerTest
:name => "Foo",
:active => "0"
}
-
}
}
+ )
assert_response 302
@bar.reload
@@ -105,10 +116,13 @@ class CustomFieldEnumerationsControllerTest < Redmine::ControllerTest
def test_destroy
assert_difference 'CustomFieldEnumeration.count', -1 do
- delete :destroy, :params => {
+ delete(
+ :destroy,
+ :params => {
:custom_field_id => @field.id,
:id => @foo.id
}
+ )
assert_redirected_to "/custom_fields/#{@field.id}/enumerations"
end
@@ -123,10 +137,13 @@ class CustomFieldEnumerationsControllerTest < Redmine::ControllerTest
group.save!
assert_no_difference 'CustomFieldEnumeration.count' do
- delete :destroy, :params => {
+ delete(
+ :destroy,
+ :params => {
:custom_field_id => @field.id,
:id => @foo.id
}
+ )
assert_response :success
assert_select 'select[name=?]', 'reassign_to_id'
@@ -139,11 +156,14 @@ class CustomFieldEnumerationsControllerTest < Redmine::ControllerTest
group.save!
assert_difference 'CustomFieldEnumeration.count', -1 do
- delete :destroy, :params => {
+ delete(
+ :destroy,
+ :params => {
:custom_field_id => @field.id,
:id => @foo.id,
:reassign_to_id => @bar.id
}
+ )
assert_response 302
end