issue.reset_custom_values!
end
if options[:copy]
+ issue.author = User.current
issue.custom_field_values = self.custom_field_values.inject({}) {|h,v| h[v.custom_field_id] = v.value; h}
issue.status = if options[:attributes] && options[:attributes][:status_id]
IssueStatus.find_by_id(options[:attributes][:status_id])
assert_equal date, @copy.due_date
end
+
+ should "set current user as author" do
+ User.current = User.find(9)
+ @copy = @issue.move_to_project(Project.find(3), Tracker.find(2), {:copy => true, :attributes => {}})
+
+ assert_equal User.current, @copy.author
+ end
end
end