Skip to content

Commit

Permalink
Merge pull request ManageIQ#7087 from skateman/policy-unused-routes
Browse files Browse the repository at this point in the history
Remove unused routes from the miq_policy_controller
  • Loading branch information
mzazrivec authored May 29, 2020
2 parents 4211196 + fb02291 commit 590486b
Show file tree
Hide file tree
Showing 5 changed files with 3 additions and 31 deletions.
2 changes: 1 addition & 1 deletion app/views/miq_policy/_action_list.html.haml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
#action_list_div
= render :partial => 'layouts/gtl', :locals => {:action_url => "action_get_all", :button_div => 'policy_bar'}
= render :partial => 'layouts/gtl', :locals => {:button_div => 'policy_bar'}
2 changes: 1 addition & 1 deletion app/views/miq_policy/_alert_list.html.haml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
#alert_list_div
= render :partial => 'layouts/gtl', :locals => {:action_url => "alert_get_all", :button_div => 'policy_bar'}
= render :partial => 'layouts/gtl', :locals => {:button_div => 'policy_bar'}
2 changes: 1 addition & 1 deletion app/views/miq_policy/_policy_list.html.haml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
#policy_list_div
= render :partial => 'layouts/gtl', :locals => {:action_url => "policy_get_all", :button_div => 'policy_bar'}
= render :partial => 'layouts/gtl', :locals => {:button_div => 'policy_bar'}
4 changes: 0 additions & 4 deletions config/routes.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2257,12 +2257,9 @@
accordion_select
action_edit
action_field_changed
action_get_all
action_tag_pressed
alert_delete
alert_edit
alert_field_changed
alert_get_all
alert_profile_assign
alert_profile_assign_changed
alert_profile_delete
Expand All @@ -2276,7 +2273,6 @@
export_field_changed
import
policy_edit
policy_get_all
policy_field_changed
profile_edit
profile_field_changed
Expand Down
24 changes: 0 additions & 24 deletions spec/routing/miq_policy_routing_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -18,18 +18,6 @@
end
end

describe '#action_get_all' do
it 'routes with POST' do
expect(post("/#{controller_name}/action_get_all")).to route_to("#{controller_name}#action_get_all")
end
end

describe '#action_tag_pressed' do
it 'routes with POST' do
expect(post("/#{controller_name}/action_tag_pressed")).to route_to("#{controller_name}#action_tag_pressed")
end
end

describe '#alert_edit' do
it 'routes with POST' do
expect(post("/#{controller_name}/alert_edit")).to route_to("#{controller_name}#alert_edit")
Expand All @@ -42,12 +30,6 @@
end
end

describe '#alert_get_all' do
it 'routes with POST' do
expect(post("/#{controller_name}/alert_get_all")).to route_to("#{controller_name}#alert_get_all")
end
end

describe '#alert_profile_assign' do
it 'routes with POST' do
expect(post("/#{controller_name}/alert_profile_assign")).to route_to("#{controller_name}#alert_profile_assign")
Expand Down Expand Up @@ -172,12 +154,6 @@
end
end

describe '#policy_get_all' do
it 'routes with POST' do
expect(post("/#{controller_name}/policy_get_all")).to route_to("#{controller_name}#policy_get_all")
end
end

describe '#profile_edit' do
it 'routes with POST' do
expect(post("/#{controller_name}/profile_edit")).to route_to("#{controller_name}#profile_edit")
Expand Down

0 comments on commit 590486b

Please # to comment.