@@ -23,11 +23,11 | |||
|
23 | 23 | |
|
24 | 24 | <% unless @pages.empty? %> |
|
25 | 25 | <% other_formats_links do |f| %> |
|
26 |
<%= f.link_to 'Atom', :url => {:controller => 'activities', :action => ' |
|
|
26 | <%= f.link_to 'Atom', :url => {:controller => 'activities', :action => 'index', :id => @project, :show_wiki_edits => 1, :key => User.current.rss_key} %> | |
|
27 | 27 | <%= f.link_to('HTML', :url => {:action => 'export'}) if User.current.allowed_to?(:export_wiki_pages, @project) %> |
|
28 | 28 | <% end %> |
|
29 | 29 | <% end %> |
|
30 | 30 | |
|
31 | 31 | <% content_for :header_tags do %> |
|
32 |
<%= auto_discovery_link_tag(:atom, :controller => 'activities', :action => ' |
|
|
32 | <%= auto_discovery_link_tag(:atom, :controller => 'activities', :action => 'index', :id => @project, :show_wiki_edits => 1, :format => 'atom', :key => User.current.rss_key) %> | |
|
33 | 33 | <% end %> |
@@ -16,11 +16,11 | |||
|
16 | 16 | |
|
17 | 17 | <% unless @pages.empty? %> |
|
18 | 18 | <% other_formats_links do |f| %> |
|
19 |
<%= f.link_to 'Atom', :url => {:controller => 'activities', :action => ' |
|
|
19 | <%= f.link_to 'Atom', :url => {:controller => 'activities', :action => 'index', :id => @project, :show_wiki_edits => 1, :key => User.current.rss_key} %> | |
|
20 | 20 | <%= f.link_to('HTML', :url => {:action => 'export'}) if User.current.allowed_to?(:export_wiki_pages, @project) %> |
|
21 | 21 | <% end %> |
|
22 | 22 | <% end %> |
|
23 | 23 | |
|
24 | 24 | <% content_for :header_tags do %> |
|
25 |
<%= auto_discovery_link_tag(:atom, :controller => 'activities', :action => ' |
|
|
25 | <%= auto_discovery_link_tag(:atom, :controller => 'activities', :action => 'index', :id => @project, :show_wiki_edits => 1, :format => 'atom', :key => User.current.rss_key) %> | |
|
26 | 26 | <% end %> |
@@ -387,6 +387,11 class WikiControllerTest < ActionController::TestCase | |||
|
387 | 387 | :child => { :tag => 'li', :child => { :tag => 'a', :attributes => { :href => '/projects/ecookbook/wiki/Another_page' }, |
|
388 | 388 | :content => 'Another page' } } |
|
389 | 389 | end |
|
390 | ||
|
391 | def test_index_should_include_atom_link | |
|
392 | get :index, :project_id => 'ecookbook' | |
|
393 | assert_tag 'a', :attributes => { :href => '/projects/ecookbook/activity.atom?show_wiki_edits=1'} | |
|
394 | end | |
|
390 | 395 | |
|
391 | 396 | context "GET :export" do |
|
392 | 397 | context "with an authorized user to export the wiki" do |
@@ -426,6 +431,9 class WikiControllerTest < ActionController::TestCase | |||
|
426 | 431 | should_assign_to :pages_by_date |
|
427 | 432 | should_render_template 'wiki/date_index' |
|
428 | 433 | |
|
434 | should "include atom link" do | |
|
435 | assert_tag 'a', :attributes => { :href => '/projects/ecookbook/activity.atom?show_wiki_edits=1'} | |
|
436 | end | |
|
429 | 437 | end |
|
430 | 438 | |
|
431 | 439 | def test_not_found |
General Comments 0
You need to be logged in to leave comments.
Login now