BigW Consortium Gitlab

Commit 5e2219db by Pawel Chojnacki

Fix unreversible migration, and small rubocop warnings

parent d3e794e2
......@@ -5,7 +5,11 @@ class AddCreatedAtIndexToDeployments < ActiveRecord::Migration
disable_ddl_transaction!
def change
def up
add_concurrent_index :deployments, :created_at
end
def down
remove_index :deployments, :created_at
end
end
......@@ -20,7 +20,7 @@ describe Projects::DeploymentsController do
create(:deployment, environment: environment, created_at: 7.hours.ago)
create(:deployment, environment: environment)
get :index, environment_params(:after => 8.hours.ago)
get :index, environment_params(after: 8.hours.ago)
expect(response).to be_ok
......@@ -41,7 +41,7 @@ describe Projects::DeploymentsController do
end
end
def environment_params(opts={})
def environment_params(opts = {})
opts.reverse_merge(namespace_id: project.namespace, project_id: project, environment_id: environment.id)
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