mirror of
https://github.com/TracksApp/tracks.git
synced 2025-12-18 08:10:13 +01:00
Use the keyword args syntax for controller actions
Co-Authored-By: Dan Rice <dnrce@users.noreply.github.com>
This commit is contained in:
parent
755a7a1b80
commit
2f85a42f91
19 changed files with 258 additions and 241 deletions
|
|
@ -69,22 +69,22 @@ class StatsControllerTest < ActionController::TestCase
|
|||
# assert_template nil
|
||||
|
||||
# get week 0-1 for actions visible running
|
||||
get :show_selected_actions_from_chart, :id => 'avrt', :index => 0
|
||||
get :show_selected_actions_from_chart, params: { :id => 'avrt', :index => 0 }
|
||||
assert_response :success
|
||||
assert_template "stats/show_selection_from_chart"
|
||||
|
||||
# get week 0 and further for actions visible running
|
||||
get :show_selected_actions_from_chart, :id => 'avrt_end', :index => 0
|
||||
get :show_selected_actions_from_chart, params: { :id => 'avrt_end', :index => 0 }
|
||||
assert_response :success
|
||||
assert_template "stats/show_selection_from_chart"
|
||||
|
||||
# get week 0-1 for actions running
|
||||
get :show_selected_actions_from_chart, :id => 'art', :index => 0
|
||||
get :show_selected_actions_from_chart, params: { :id => 'art', :index => 0 }
|
||||
assert_response :success
|
||||
assert_template "stats/show_selection_from_chart"
|
||||
|
||||
# get week 0 and further for actions running
|
||||
get :show_selected_actions_from_chart, :id => 'art_end', :index => 0
|
||||
get :show_selected_actions_from_chart, params: { :id => 'art_end', :index => 0 }
|
||||
assert_response :success
|
||||
assert_template "stats/show_selection_from_chart"
|
||||
end
|
||||
|
|
@ -404,7 +404,7 @@ class StatsControllerTest < ActionController::TestCase
|
|||
given_todos_for_stats
|
||||
|
||||
# When I get the chart data
|
||||
get :show_selected_actions_from_chart, {:id => "avrt", :index => 1}
|
||||
get :show_selected_actions_from_chart, params: {:id => "avrt", :index => 1}
|
||||
assert_response :success
|
||||
|
||||
assert_equal false, assigns['further'] # not at end
|
||||
|
|
@ -419,7 +419,7 @@ class StatsControllerTest < ActionController::TestCase
|
|||
given_todos_for_stats
|
||||
|
||||
# When I get the chart data
|
||||
get :show_selected_actions_from_chart, {:id => "avrt_end", :index => 1}
|
||||
get :show_selected_actions_from_chart, params: {:id => "avrt_end", :index => 1}
|
||||
assert_response :success
|
||||
|
||||
assert assigns['further'] # at end
|
||||
|
|
@ -434,7 +434,7 @@ class StatsControllerTest < ActionController::TestCase
|
|||
given_todos_for_stats
|
||||
|
||||
# When I get the chart data
|
||||
get :show_selected_actions_from_chart, {:id => "art", :index => 1}
|
||||
get :show_selected_actions_from_chart, params: {:id => "art", :index => 1}
|
||||
assert_response :success
|
||||
|
||||
assert_equal false, assigns['further'] # not at end
|
||||
|
|
@ -449,7 +449,7 @@ class StatsControllerTest < ActionController::TestCase
|
|||
given_todos_for_stats
|
||||
|
||||
# When I get the chart data
|
||||
get :show_selected_actions_from_chart, {:id => "art_end", :index => 1}
|
||||
get :show_selected_actions_from_chart, params: {:id => "art_end", :index => 1}
|
||||
assert_response :success
|
||||
|
||||
assert assigns['further'] # at end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue