From cbafe24a1fef2c13925490453cb97c3831d03169 Mon Sep 17 00:00:00 2001 From: Lin Jen-Shin Date: Mon, 22 May 2017 18:42:14 +0800 Subject: Respect the typo as rubocop said --- spec/migrations/upate_retried_for_ci_builds_spec.rb | 17 +++++++++++++++++ spec/migrations/update_retried_for_ci_builds_spec.rb | 17 ----------------- 2 files changed, 17 insertions(+), 17 deletions(-) create mode 100644 spec/migrations/upate_retried_for_ci_builds_spec.rb delete mode 100644 spec/migrations/update_retried_for_ci_builds_spec.rb diff --git a/spec/migrations/upate_retried_for_ci_builds_spec.rb b/spec/migrations/upate_retried_for_ci_builds_spec.rb new file mode 100644 index 00000000000..5cdb8a3c7da --- /dev/null +++ b/spec/migrations/upate_retried_for_ci_builds_spec.rb @@ -0,0 +1,17 @@ +require 'spec_helper' +require Rails.root.join('db', 'post_migrate', '20170503004427_upate_retried_for_ci_build.rb') + +describe UpateRetriedForCiBuild, truncate: true do + let(:pipeline) { create(:ci_pipeline) } + let!(:build_old) { create(:ci_build, pipeline: pipeline, name: 'test') } + let!(:build_new) { create(:ci_build, pipeline: pipeline, name: 'test') } + + before do + described_class.new.up + end + + it 'updates ci_builds.is_retried' do + expect(build_old.reload).to be_retried + expect(build_new.reload).not_to be_retried + end +end diff --git a/spec/migrations/update_retried_for_ci_builds_spec.rb b/spec/migrations/update_retried_for_ci_builds_spec.rb deleted file mode 100644 index 5cdb8a3c7da..00000000000 --- a/spec/migrations/update_retried_for_ci_builds_spec.rb +++ /dev/null @@ -1,17 +0,0 @@ -require 'spec_helper' -require Rails.root.join('db', 'post_migrate', '20170503004427_upate_retried_for_ci_build.rb') - -describe UpateRetriedForCiBuild, truncate: true do - let(:pipeline) { create(:ci_pipeline) } - let!(:build_old) { create(:ci_build, pipeline: pipeline, name: 'test') } - let!(:build_new) { create(:ci_build, pipeline: pipeline, name: 'test') } - - before do - described_class.new.up - end - - it 'updates ci_builds.is_retried' do - expect(build_old.reload).to be_retried - expect(build_new.reload).not_to be_retried - end -end -- cgit v1.2.1