Commit 3c2bcf25 authored by Grzegorz Bizon's avatar Grzegorz Bizon

Fix feature specs for pages deployment

parent f9065910
...@@ -35,7 +35,10 @@ class Spinach::Features::ProjectPages < Spinach::FeatureSteps ...@@ -35,7 +35,10 @@ class Spinach::Features::ProjectPages < Spinach::FeatureSteps
end end
step 'pages are deployed' do step 'pages are deployed' do
pipeline = @project.pipelines.create(ref: 'HEAD', sha: @project.commit('HEAD').sha) pipeline = @project.pipelines.create(ref: 'HEAD',
sha: @project.commit('HEAD').sha,
source: :push)
build = build(:ci_build, build = build(:ci_build,
project: @project, project: @project,
pipeline: pipeline, pipeline: pipeline,
...@@ -43,6 +46,7 @@ class Spinach::Features::ProjectPages < Spinach::FeatureSteps ...@@ -43,6 +46,7 @@ class Spinach::Features::ProjectPages < Spinach::FeatureSteps
artifacts_file: fixture_file_upload(Rails.root + 'spec/fixtures/pages.zip'), artifacts_file: fixture_file_upload(Rails.root + 'spec/fixtures/pages.zip'),
artifacts_metadata: fixture_file_upload(Rails.root + 'spec/fixtures/pages.zip.meta') artifacts_metadata: fixture_file_upload(Rails.root + 'spec/fixtures/pages.zip.meta')
) )
result = ::Projects::UpdatePagesService.new(@project, build).execute result = ::Projects::UpdatePagesService.new(@project, build).execute
expect(result[:status]).to eq(:success) expect(result[:status]).to eq(:success)
end end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment