<%= link_to l(:label_settings), :controller => 'settings' %>
</p>
-<% menu_items_for(:admin_menu) do |item, caption, url, selected| -%>
- <%= content_tag 'p',
- link_to(h(caption), item.url, item.html_options),
+<% menu_items_for(:admin_menu) do |item| -%>
+ <%= content_tag 'p',
+ link_to(h(item.caption), item.url, item.html_options),
:class => ["icon22", "icon22-#{item.name}"].join(' ') %>
<% end -%>
assert_template 'info'
end
+ def test_admin_menu_plugin_extension
+ Redmine::MenuManager.map :admin_menu do |menu|
+ menu.push :test_admin_menu_plugin_extension, '/foo/bar', :caption => 'Test'
+ end
+
+ get :index
+ assert_response :success
+ assert_tag :a, :attributes => { :href => '/foo/bar' },
+ :content => 'Test'
+
+ Redmine::MenuManager.map :admin_menu do |menu|
+ menu.delete :test_admin_menu_plugin_extension
+ end
+ end
+
private
def delete_configuration_data