feat(gallery): add attachments from commentaires from experts

This commit is contained in:
Eric Leroy-Terquem 2024-10-10 10:20:47 +02:00
parent ad98bafeca
commit 2e2d2afecb
No known key found for this signature in database
GPG key ID: 53D8FAECEF207605
3 changed files with 20 additions and 2 deletions

View file

@ -100,6 +100,14 @@ RSpec.describe Attachment::GalleryItemComponent, type: :component do
expect(subject).to have_text('Messagerie (instructeur)')
end
end
context 'from an expert' do
let(:expert) { create(:expert) }
before { commentaire.update!(expert:) }
it "displays the right tag" do
expect(subject).to have_text('Messagerie (expert)')
end
end
end
context "when attachment is from an avis" do