Fix pipelines spec
This commit is contained in:
parent
5ac2c5839a
commit
4ce2ca4d36
|
@ -1,9 +1,9 @@
|
||||||
.tabs-holder
|
.tabs-holder
|
||||||
%ul.nav-links.no-top.no-bottom
|
%ul.nav-links.no-top.no-bottom
|
||||||
%li.active
|
%li.active
|
||||||
= link_to "Pipeline", "#js-tab-pipeline", data: { target: '#js-tab-pipeline', action: 'pipeline', toggle: 'tab' }
|
= link_to "Pipeline", "#js-tab-pipeline", data: { target: '#js-tab-pipeline', action: 'pipeline', toggle: 'tab' }, class: 'pipeline-tab'
|
||||||
%li
|
%li
|
||||||
= link_to "#js-tab-builds", data: { target: '#js-tab-builds', action: 'build', toggle: 'tab' } do
|
= link_to "#js-tab-builds", data: { target: '#js-tab-builds', action: 'build', toggle: 'tab' }, class: 'builds-tab' do
|
||||||
Builds
|
Builds
|
||||||
%span.badge= pipeline.statuses.count
|
%span.badge= pipeline.statuses.count
|
||||||
|
|
||||||
|
|
|
@ -64,7 +64,7 @@ describe 'Cherry-pick Commits' do
|
||||||
|
|
||||||
context "I cherry-pick a commit from a different branch", js: true do
|
context "I cherry-pick a commit from a different branch", js: true do
|
||||||
it do
|
it do
|
||||||
find('.commit-action-buttons a.dropdown-toggle').click
|
find('.header-action-buttons a.dropdown-toggle').click
|
||||||
find(:css, "a[href='#modal-cherry-pick-commit']").click
|
find(:css, "a[href='#modal-cherry-pick-commit']").click
|
||||||
|
|
||||||
page.within('#modal-cherry-pick-commit') do
|
page.within('#modal-cherry-pick-commit') do
|
||||||
|
|
|
@ -146,7 +146,8 @@ describe "Pipelines" do
|
||||||
end
|
end
|
||||||
|
|
||||||
describe 'GET /:project/pipelines/:id' do
|
describe 'GET /:project/pipelines/:id' do
|
||||||
let(:pipeline) { create(:ci_pipeline, project: project, ref: 'master') }
|
let(:project) { create(:project) }
|
||||||
|
let(:pipeline) { create(:ci_pipeline, project: project, ref: 'master', sha: project.commit.id) }
|
||||||
|
|
||||||
before do
|
before do
|
||||||
@success = create(:ci_build, :success, pipeline: pipeline, stage: 'build', name: 'build')
|
@success = create(:ci_build, :success, pipeline: pipeline, stage: 'build', name: 'build')
|
||||||
|
@ -156,10 +157,7 @@ describe "Pipelines" do
|
||||||
@external = create(:generic_commit_status, status: 'success', pipeline: pipeline, name: 'jenkins', stage: 'external')
|
@external = create(:generic_commit_status, status: 'success', pipeline: pipeline, name: 'jenkins', stage: 'external')
|
||||||
end
|
end
|
||||||
|
|
||||||
before do
|
before { visit namespace_project_pipeline_path(project.namespace, project, pipeline) }
|
||||||
visit namespace_project_pipeline_path(project.namespace, project, pipeline)
|
|
||||||
find('.builds-tab').click
|
|
||||||
end
|
|
||||||
|
|
||||||
it 'shows a list of builds' do
|
it 'shows a list of builds' do
|
||||||
expect(page).to have_content('Test')
|
expect(page).to have_content('Test')
|
||||||
|
|
Loading…
Reference in New Issue