From 989b44ac3b363f23e1530030e569e0d0646aaef2 Mon Sep 17 00:00:00 2001 From: Toshi MARUYAMA Date: Wed, 6 Nov 2019 12:04:52 +0000 Subject: cleanup: rubocop: fix Layout/AlignArguments in test/functional/workflows_controller_test.rb git-svn-id: http://svn.redmine.org/redmine/trunk@18928 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- test/functional/workflows_controller_test.rb | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) (limited to 'test') diff --git a/test/functional/workflows_controller_test.rb b/test/functional/workflows_controller_test.rb index 42c5ae4a3..51b3ec5d0 100644 --- a/test/functional/workflows_controller_test.rb +++ b/test/functional/workflows_controller_test.rb @@ -50,9 +50,10 @@ class WorkflowsControllerTest < Redmine::ControllerTest # used status only statuses = IssueStatus.where(:id => [2, 3, 5]).sorted.pluck(:name) - assert_equal ["New issue"] + statuses, + assert_equal( + ["New issue"] + statuses, css_select('table.workflows.transitions-always tbody tr td:first').map(&:text).map(&:strip) - + ) # allowed transitions assert_select 'input[type=checkbox][name=?][value="1"][checked=checked]', 'transitions[3][5][always]' # not allowed @@ -76,8 +77,10 @@ class WorkflowsControllerTest < Redmine::ControllerTest # statuses 1 and 5 not displayed statuses = IssueStatus.where(:id => [2, 3]).sorted.pluck(:name) - assert_equal ["New issue"] + statuses, + assert_equal( + ["New issue"] + statuses, css_select('table.workflows.transitions-always tbody tr td:first').map(&:text).map(&:strip) + ) end def test_get_edit_should_include_allowed_statuses_for_new_issues @@ -109,9 +112,10 @@ class WorkflowsControllerTest < Redmine::ControllerTest assert_response :success statuses = IssueStatus.all.sorted.pluck(:name) - assert_equal ["New issue"] + statuses, + assert_equal( + ["New issue"] + statuses, css_select('table.workflows.transitions-always tbody tr td:first').map(&:text).map(&:strip) - + ) assert_select 'input[type=checkbox][name=?]', 'transitions[0][1][always]' end @@ -321,8 +325,10 @@ class WorkflowsControllerTest < Redmine::ControllerTest assert_response :success statuses = IssueStatus.all.sorted.pluck(:name) - assert_equal statuses, + assert_equal( + statuses, css_select('table.workflows.fields_permissions thead tr:nth-child(2) td:not(:first-child)').map(&:text).map(&:strip) + ) end def test_get_permissions_should_set_css_class -- cgit v1.2.3