Sha256: 01e3d2a00fa435f1b1f68d50d1afcd68dacb6cbc5c9b96f3baab3f60f9cec2f8
Contents?: true
Size: 1.43 KB
Versions: 10
Compression:
Stored size: 1.43 KB
Contents
require 'rails_helper' describe Dradis::Plugins::Projects::Export::V2::Template do let(:project) { create(:project) } let(:user) { create(:user) } let(:export) do described_class.new( default_user_id: user.id, plugin: Dradis::Plugins::Projects, project_id: project.id ).export end context 'exporting a project' do before do node = create(:node, project: project) issue = create(:issue, text: 'Issue 1', node: project.issue_library) end context 'with comments in an issue' do before do create(:comment, content: 'A comment on an issue', commentable: issue) end it 'exports comments in the issue' do expect(export).to include('A comment on an issue') end end context 'with comments in a note' do before do note = create(:note, text: 'Note 1', node: node) create(:comment, content: 'A comment on a note', commentable: note) end it 'exports comments in the note' do expect(export).to include('A comment on a note') end end context 'with comments in an evidence' do before do evidence = create(:evidence, text: 'Test evidence', node: node, issue: issue) create(:comment, content: 'A comment on an evidence', commentable: evidence) end it 'exports comments in the evidence' do expect(export).to include('A comment on an evidence') end end end end
Version data entries
10 entries across 10 versions & 1 rubygems