"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "test/helpers/application_helper_test.rb" between
redmine-4.1.0.tar.gz and redmine-4.1.1.tar.gz

About: Redmine is a flexible project management and bug-tracking web application (using the Ruby on Rails framework). It supports also project wikis and forums, documents management, and multiple version control systems.

application_helper_test.rb  (redmine-4.1.0):application_helper_test.rb  (redmine-4.1.1)
skipping to change at line 312 skipping to change at line 312
user_with_email_login = User.generate!(:login => 'abcd@example.com') user_with_email_login = User.generate!(:login => 'abcd@example.com')
user_with_email_login_2 = User.generate!(:login => 'foo.bar@example.com') user_with_email_login_2 = User.generate!(:login => 'foo.bar@example.com')
u_email_id = user_with_email_login.id u_email_id = user_with_email_login.id
u_email_id_2 = user_with_email_login_2.id u_email_id_2 = user_with_email_login_2.id
issue_link = link_to('#3', issue_link = link_to('#3',
{:controller => 'issues', :action => 'show', :id => 3}, {:controller => 'issues', :action => 'show', :id => 3},
:class => Issue.find(3).css_classes, :class => Issue.find(3).css_classes,
:title => 'Bug: Error 281 when updating a recipe (New)' ) :title => 'Bug: Error 281 when updating a recipe (New)' )
ext_issue_link = link_to( ext_issue_link = link_to(
'Bug #3', 'Bug #3: Error 281 when updating a recipe',
{:controller => 'issues', :action => 'show', :id => 3}, {:controller => 'issues', :action => 'show', :id => 3},
:class => Issue.find(3).css_classes, :class => Issue.find(3).css_classes,
:title => 'Bug: Error 281 when updating a recipe (New)' :title => 'Status: New')
) +
": Error 281 when updating a recipe"
note_link = link_to( note_link = link_to(
'#3-14', '#3-14',
{:controller => 'issues', :action => 'show', {:controller => 'issues', :action => 'show',
:id => 3, :anchor => 'note-14'}, :id => 3, :anchor => 'note-14'},
:class => Issue.find(3).css_classes, :class => Issue.find(3).css_classes,
:title => 'Bug: Error 281 when updating a recipe (New)' ) :title => 'Bug: Error 281 when updating a recipe (New)' )
ext_note_link = link_to( ext_note_link = link_to(
'Bug #3-14', 'Bug #3-14: Error 281 when updating a recipe',
{:controller => 'issues', :action => 'show', {:controller => 'issues', :action => 'show',
:id => 3, :anchor => 'note-14'}, :id => 3, :anchor => 'note-14'},
:class => Issue.find(3).css_classes, :class => Issue.find(3).css_classes,
:title => 'Bug: Error 281 when updating a recipe (New)' :title => 'Status: New')
) +
": Error 281 when updating a recipe"
note_link2 = link_to( note_link2 = link_to(
'#3#note-14', '#3#note-14',
{:controller => 'issues', :action => 'show', {:controller => 'issues', :action => 'show',
:id => 3, :anchor => 'note-14'}, :id => 3, :anchor => 'note-14'},
:class => Issue.find(3).css_classes, :class => Issue.find(3).css_classes,
:title => 'Bug: Error 281 when updating a recipe (New)' ) :title => 'Bug: Error 281 when updating a recipe (New)' )
ext_note_link2 = link_to( ext_note_link2 = link_to(
'Bug #3#note-14', 'Bug #3#note-14: Error 281 when updating a recipe',
{:controller => 'issues', :action => 'show', {:controller => 'issues', :action => 'show',
:id => 3, :anchor => 'note-14'}, :id => 3, :anchor => 'note-14'},
:class => Issue.find(3).css_classes, :class => Issue.find(3).css_classes,
:title => 'Bug: Error 281 when updating a recipe (New)' :title => 'Status: New')
) +
": Error 281 when updating a recipe"
revision_link = link_to( revision_link = link_to(
'r1', 'r1',
{:controller => 'repositories', :action => 'revision', {:controller => 'repositories', :action => 'revision',
:id => 'ecookbook', :repository_id => 10, :rev => 1}, :id => 'ecookbook', :repository_id => 10, :rev => 1},
:class => 'changeset', :class => 'changeset',
:title => 'My very first commit do not escaping #<>&') :title => 'My very first commit do not escaping #<>&')
revision_link2 = link_to( revision_link2 = link_to(
'r2', 'r2',
{:controller => 'repositories', :action => 'revision', {:controller => 'repositories', :action => 'revision',
skipping to change at line 401 skipping to change at line 398
to_test = { to_test = {
# tickets # tickets
'#3, [#3], (#3) and #3.' => "#{issue_link}, [#{issue_link}], (#{issue _link}) and #{issue_link}.", '#3, [#3], (#3) and #3.' => "#{issue_link}, [#{issue_link}], (#{issue _link}) and #{issue_link}.",
# ticket notes # ticket notes
'#3-14' => note_link, '#3-14' => note_link,
'#3#note-14' => note_link2, '#3#note-14' => note_link2,
# should not ignore leading zero # should not ignore leading zero
'#03' => '#03', '#03' => '#03',
# tickets with more info # tickets with more info
'##3, [##3], (##3) and ##3.' => "#{ext_issue_link}, [#{ext_issue_link '##3, [##3], (##3) and ##3.' => "#{ext_issue_link}, [#{ext_issue_link}],
}], (#{ext_issue_link}) and #{ext_issue_link}.", (#{ext_issue_link}) and #{ext_issue_link}.",
'##3-14' => ext_note_link, '##3-14' => ext_note_link,
'##3#note-14' => ext_note_link2, '##3#note-14' => ext_note_link2,
'##03' => '##03', '##03' => '##03',
# changesets # changesets
'r1' => revision_link, 'r1' => revision_link,
'r1.' => "#{revision_link}.", 'r1.' => "#{revision_link}.",
'r1, r2' => "#{revision_link}, #{revision_link2}", 'r1, r2' => "#{revision_link}, #{revision_link2}",
'r1,r2' => "#{revision_link},#{revision_link2}", 'r1,r2' => "#{revision_link},#{revision_link2}",
'commit:691322a8eb01e11fd7' => changeset_link2, 'commit:691322a8eb01e11fd7' => changeset_link2,
# documents # documents
'document#1' => document_link, 'document#1' => document_link,
'document:"Test document"' => document_link, 'document:"Test document"' => document_link,
# versions # versions
skipping to change at line 1865 skipping to change at line 1862
assert !result.html_safe? assert !result.html_safe?
end end
def test_truncate_single_line_non_ascii def test_truncate_single_line_non_ascii
ja = '日本語' ja = '日本語'
result = truncate_single_line_raw("#{ja}\n#{ja}\n#{ja}", 10) result = truncate_single_line_raw("#{ja}\n#{ja}\n#{ja}", 10)
assert_equal "#{ja} #{ja}...", result assert_equal "#{ja} #{ja}...", result
assert !result.html_safe? assert !result.html_safe?
end end
def test_back_url_should_remove_utf8_checkmark_from_referer
stubs(:request).returns(stub(:env => {'HTTP_REFERER' => "/path?utf8=\u2713&f
oo=bar"}))
assert_equal "/path?foo=bar", back_url
end
def test_hours_formatting def test_hours_formatting
set_language_if_valid 'en' set_language_if_valid 'en'
with_settings :timespan_format => 'minutes' do with_settings :timespan_format => 'minutes' do
assert_equal '0:45', format_hours(0.75) assert_equal '0:45', format_hours(0.75)
assert_equal '0:45 h', l_hours_short(0.75) assert_equal '0:45 h', l_hours_short(0.75)
assert_equal '0:45 hour', l_hours(0.75) assert_equal '0:45 hour', l_hours(0.75)
end end
with_settings :timespan_format => 'decimal' do with_settings :timespan_format => 'decimal' do
assert_equal '0.75', format_hours(0.75) assert_equal '0.75', format_hours(0.75)
 End of changes. 8 change blocks. 
23 lines changed or deleted 11 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)