From ab3cfd520dc02a62dea2a8d73a4060fc1cbc865a Mon Sep 17 00:00:00 2001 From: Kamil Trzcinski Date: Tue, 9 Aug 2016 21:24:12 +0200 Subject: Fix all tests --- features/steps/shared/builds.rb | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'features/steps') diff --git a/features/steps/shared/builds.rb b/features/steps/shared/builds.rb index 4d6b258f577..c7f61da05fa 100644 --- a/features/steps/shared/builds.rb +++ b/features/steps/shared/builds.rb @@ -10,20 +10,22 @@ module SharedBuilds end step 'project has a recent build' do - @pipeline = create(:ci_pipeline, project: @project, sha: @project.commit.sha, ref: 'master') + @pipeline = create(:ci_empty_pipeline, project: @project, sha: @project.commit.sha, ref: 'master') @build = create(:ci_build_with_coverage, pipeline: @pipeline) + @pipeline.reload_status! end step 'recent build is successful' do - @build.update(status: 'success') + @build.success end step 'recent build failed' do - @build.update(status: 'failed') + @build.drop end step 'project has another build that is running' do create(:ci_build, pipeline: @pipeline, name: 'second build', status: 'running') + @pipeline.reload_status! end step 'I visit recent build details page' do -- cgit v1.2.1