mirror of
https://github.com/opf/openproject.git
synced 2026-06-14 03:30:14 +00:00
mail_handler_spec: add_work_package_attachments instead of edit WP
Some tests used edit_work_packages to allow adding attachments, which can now be done with add_work_package_attachments.
This commit is contained in:
@@ -330,9 +330,8 @@ RSpec.describe MailHandler do
|
||||
end
|
||||
|
||||
shared_context 'with a new work package with attachment' do
|
||||
# The edit_work_packages is currently wrongfully needed as the work package
|
||||
# is created first and only then the attachment is added.
|
||||
let(:permissions) { %i[add_work_packages edit_work_packages] }
|
||||
# The work package is created first and only then the attachment is added.
|
||||
let(:permissions) { %i[add_work_packages add_work_package_attachments] }
|
||||
let!(:user) do
|
||||
create(:user,
|
||||
mail: 'JSmith@somenet.foo',
|
||||
@@ -348,9 +347,8 @@ RSpec.describe MailHandler do
|
||||
end
|
||||
|
||||
shared_context 'with a new work package with attachment in apple format' do
|
||||
# The edit_work_packages is currently wrongfully needed as the work package
|
||||
# is created first and only then the attachment is added.
|
||||
let(:permissions) { %i[add_work_packages edit_work_packages] }
|
||||
# The work package is created first and only then the attachment is added.
|
||||
let(:permissions) { %i[add_work_packages add_work_package_attachments] }
|
||||
let!(:user) do
|
||||
create(:user,
|
||||
mail: 'JSmith@somenet.foo',
|
||||
|
||||
Reference in New Issue
Block a user