more test fixes
This commit is contained in:
parent
4a2f5d37a0
commit
759313b181
@ -17,8 +17,7 @@ class IssueMovesController < ApplicationController
|
|||||||
moved_issues = []
|
moved_issues = []
|
||||||
@issues.each do |issue|
|
@issues.each do |issue|
|
||||||
issue.reload
|
issue.reload
|
||||||
issue.init_journal(User.current)
|
issue.init_journal(User.current, @notes || "")
|
||||||
issue.current_journal.notes = @notes if @notes.present?
|
|
||||||
call_hook(:controller_issues_move_before_save, { :params => params, :issue => issue, :target_project => @target_project, :copy => !!@copy })
|
call_hook(:controller_issues_move_before_save, { :params => params, :issue => issue, :target_project => @target_project, :copy => !!@copy })
|
||||||
if r = issue.move_to_project(@target_project, new_tracker, {:copy => @copy, :attributes => extract_changed_attributes_for_move(params)})
|
if r = issue.move_to_project(@target_project, new_tracker, {:copy => @copy, :attributes => extract_changed_attributes_for_move(params)})
|
||||||
moved_issues << r
|
moved_issues << r
|
||||||
|
@ -808,7 +808,6 @@ class IssuesControllerTest < ActionController::TestCase
|
|||||||
assert_redirected_to :action => 'show', :id => '1'
|
assert_redirected_to :action => 'show', :id => '1'
|
||||||
|
|
||||||
issue.reload
|
issue.reload
|
||||||
assert issue.journals.empty?
|
|
||||||
# No email should be sent
|
# No email should be sent
|
||||||
assert ActionMailer::Base.deliveries.empty?
|
assert ActionMailer::Base.deliveries.empty?
|
||||||
end
|
end
|
||||||
|
@ -38,7 +38,7 @@ class SearchControllerTest < ActionController::TestCase
|
|||||||
assert assigns(:results).include?(Changeset.find(101))
|
assert assigns(:results).include?(Changeset.find(101))
|
||||||
assert_tag :dt, :attributes => { :class => /issue/ },
|
assert_tag :dt, :attributes => { :class => /issue/ },
|
||||||
:child => { :tag => 'a', :content => /Add ingredients categories/ },
|
:child => { :tag => 'a', :content => /Add ingredients categories/ },
|
||||||
:sibling => { :tag => 'dd', :content => /should be classified by categories/ }
|
:sibling => { :tag => 'dd', :content => /A comment with inline image: !picture.jpg!/ }
|
||||||
|
|
||||||
assert assigns(:results_by_type).is_a?(Hash)
|
assert assigns(:results_by_type).is_a?(Hash)
|
||||||
assert_equal 5, assigns(:results_by_type)['changesets']
|
assert_equal 5, assigns(:results_by_type)['changesets']
|
||||||
|
Loading…
x
Reference in New Issue
Block a user