2019-07-25 01:24:42 -04:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2019-08-29 03:56:52 -04:00
|
|
|
require 'spec_helper'
|
2018-09-04 12:48:57 -04:00
|
|
|
|
2018-11-28 14:15:37 -05:00
|
|
|
describe 'New issue breadcrumb' do
|
2018-09-04 12:48:57 -04:00
|
|
|
let(:project) { create(:project) }
|
2018-11-28 14:15:37 -05:00
|
|
|
let(:user) { project.creator }
|
2018-09-04 12:48:57 -04:00
|
|
|
|
|
|
|
before do
|
|
|
|
sign_in(user)
|
2018-11-28 14:15:37 -05:00
|
|
|
visit(new_project_issue_path(project))
|
2018-09-04 12:48:57 -04:00
|
|
|
end
|
|
|
|
|
2018-11-28 14:15:37 -05:00
|
|
|
it 'displays link to project issues and new issue' do
|
2018-09-04 12:48:57 -04:00
|
|
|
page.within '.breadcrumbs' do
|
|
|
|
expect(find_link('Issues')[:href]).to end_with(project_issues_path(project))
|
|
|
|
expect(find_link('New')[:href]).to end_with(new_project_issue_path(project))
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|