From ea090291bba6bb665b3631cc5a2659e6673a6959 Mon Sep 17 00:00:00 2001 From: Eric Eastwood Date: Wed, 31 May 2017 00:50:53 -0500 Subject: Rename "Slash commands" to "Quick actions" Fix https://gitlab.com/gitlab-org/gitlab-ce/issues/27070 Deprecate "chat commands" in favor of "slash commands" We looked for things like: - `slash commmand` - `slash_command` - `slash-command` - `SlashCommand` --- spec/services/issues/create_service_spec.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'spec/services/issues') diff --git a/spec/services/issues/create_service_spec.rb b/spec/services/issues/create_service_spec.rb index 370bd352200..ae9d2b2855d 100644 --- a/spec/services/issues/create_service_spec.rb +++ b/spec/services/issues/create_service_spec.rb @@ -206,9 +206,9 @@ describe Issues::CreateService, services: true do end end - it_behaves_like 'new issuable record that supports slash commands' + it_behaves_like 'new issuable record that supports quick actions' - context 'Slash commands' do + context 'Quick actions' do context 'with assignee and milestone in params and command' do let(:opts) do { -- cgit v1.2.1 From 0430b7644101fc70ed4be6bf69ccf05b900f4cdf Mon Sep 17 00:00:00 2001 From: Grzegorz Bizon Date: Wed, 21 Jun 2017 13:48:12 +0000 Subject: Enable Style/DotPosition Rubocop :cop: --- spec/services/issues/close_service_spec.rb | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'spec/services/issues') diff --git a/spec/services/issues/close_service_spec.rb b/spec/services/issues/close_service_spec.rb index be0e829880e..d6f4c694069 100644 --- a/spec/services/issues/close_service_spec.rb +++ b/spec/services/issues/close_service_spec.rb @@ -18,26 +18,26 @@ describe Issues::CloseService, services: true do let(:service) { described_class.new(project, user) } it 'checks if the user is authorized to update the issue' do - expect(service).to receive(:can?).with(user, :update_issue, issue). - and_call_original + expect(service).to receive(:can?).with(user, :update_issue, issue) + .and_call_original service.execute(issue) end it 'does not close the issue when the user is not authorized to do so' do - allow(service).to receive(:can?).with(user, :update_issue, issue). - and_return(false) + allow(service).to receive(:can?).with(user, :update_issue, issue) + .and_return(false) expect(service).not_to receive(:close_issue) expect(service.execute(issue)).to eq(issue) end it 'closes the issue when the user is authorized to do so' do - allow(service).to receive(:can?).with(user, :update_issue, issue). - and_return(true) + allow(service).to receive(:can?).with(user, :update_issue, issue) + .and_return(true) - expect(service).to receive(:close_issue). - with(issue, commit: nil, notifications: true, system_note: true) + expect(service).to receive(:close_issue) + .with(issue, commit: nil, notifications: true, system_note: true) service.execute(issue) end -- cgit v1.2.1