diff options
author | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2017-01-04 21:13:28 +0000 |
---|---|---|
committer | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2017-01-04 21:13:28 +0000 |
commit | 84732abd0ad79403c20b978e827e6e3dceae3286 (patch) | |
tree | dfafa71f3cfc6de50c2c4b4d4a6a412696c76f0f /test/functional/activities_controller_test.rb | |
parent | 1c44b16023f5583a496563506ad4c4f7e5ccfbd2 (diff) | |
download | redmine-84732abd0ad79403c20b978e827e6e3dceae3286.tar.gz redmine-84732abd0ad79403c20b978e827e6e3dceae3286.zip |
Missing "next" pagination link when looking at yesterday's activity (#18399).
Patch by Felix Schäfer.
git-svn-id: http://svn.redmine.org/redmine/trunk@16137 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/functional/activities_controller_test.rb')
-rw-r--r-- | test/functional/activities_controller_test.rb | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/test/functional/activities_controller_test.rb b/test/functional/activities_controller_test.rb index 5aacf6228..230e46192 100644 --- a/test/functional/activities_controller_test.rb +++ b/test/functional/activities_controller_test.rb @@ -169,4 +169,22 @@ class ActivitiesControllerTest < Redmine::ControllerTest assert_select 'input[name=show_news][checked=checked]' end end + + def test_index_should_not_show_next_page_link + @request.session[:user_id] = 2 + + get :index + assert_response :success + assert_select '.pagination a', :text => /Previous/ + assert_select '.pagination a', :text => /Next/, :count => 0 + end + + def test_index_up_to_yesterday_should_show_next_page_link + @request.session[:user_id] = 2 + + get :index, :from => (User.find(2).today-1) + assert_response :success + assert_select '.pagination a', :text => /Previous/ + assert_select '.pagination a', :text => /Next/ + end end |