summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGrzegorz Bizon <grzesiek.bizon@gmail.com>2017-01-05 22:18:44 +0100
committerGrzegorz Bizon <grzesiek.bizon@gmail.com>2017-01-05 22:18:44 +0100
commit253781dbfcdd728260a6a1040b784c242d7ec114 (patch)
tree8814ece6b9762fd92e232058443ec1de5469f8ed
parentc71a88a7258fe25d77e6e4ef2745fa5a71fef908 (diff)
downloadgitlab-ce-253781dbfcdd728260a6a1040b784c242d7ec114.tar.gz
Fix pipelines feature specs after invalid merge
-rw-r--r--spec/features/projects/pipelines/pipelines_spec.rb25
1 files changed, 10 insertions, 15 deletions
diff --git a/spec/features/projects/pipelines/pipelines_spec.rb b/spec/features/projects/pipelines/pipelines_spec.rb
index a4d776c98ef..3856d5b6b2e 100644
--- a/spec/features/projects/pipelines/pipelines_spec.rb
+++ b/spec/features/projects/pipelines/pipelines_spec.rb
@@ -243,7 +243,7 @@ describe 'Pipelines', :feature, :js do
end
end
- context 'mini pipleine graph' do
+ context 'mini pipeline graph' do
let!(:build) do
create(:ci_build, pipeline: pipeline,
stage: 'build',
@@ -252,6 +252,11 @@ describe 'Pipelines', :feature, :js do
before { visit_project_pipelines }
+ it 'should render a mini pipeline graph' do
+ expect(page).to have_selector('.js-mini-pipeline-graph')
+ expect(page).to have_selector('.js-builds-dropdown-button')
+ end
+
context 'when clicking a graph stage' do
it 'should open a dropdown' do
find('.js-builds-dropdown-button').trigger('click')
@@ -261,8 +266,8 @@ describe 'Pipelines', :feature, :js do
it 'should be possible to retry the failed build' do
find('.js-builds-dropdown-button').trigger('click')
+ find('a.js-ci-action-icon').trigger('click')
- find('a.ci-action-icon-container').trigger('click')
expect(page).not_to have_content('Cancel running')
end
end
@@ -279,15 +284,8 @@ describe 'Pipelines', :feature, :js do
context 'for valid commit' do
before { fill_in('pipeline[ref]', with: 'master') }
- expect(page).to have_selector('.js-mini-pipeline-graph')
- expect(page).to have_selector(".js-builds-dropdown-button[data-stage-endpoint='#{endpoint}']")
- end
-
- context 'when clicking a graph stage' do
- it 'should open a dropdown' do
- find('.js-builds-dropdown-button').trigger('click')
-
- wait_for_ajax
+ context 'with gitlab-ci.yml' do
+ before { stub_ci_pipeline_to_return_yaml_file }
it 'creates a new pipeline' do
expect { click_on 'Create pipeline' }
@@ -298,10 +296,7 @@ describe 'Pipelines', :feature, :js do
context 'without gitlab-ci.yml' do
before { click_on 'Create pipeline' }
- wait_for_ajax
-
- find('a.js-ci-action-icon').trigger('click')
- expect(page).not_to have_content('Cancel running')
+ it { expect(page).to have_content('Missing .gitlab-ci.yml file') }
end
end