Welcome to mirror list, hosted at ThFree Co, Russian Federation.

destroy_service_spec.rb « keys « services « spec - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 28ac72ddd42be5caa456055d0b0e442218a445da (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
require 'spec_helper'

describe Keys::DestroyService do
  let(:user) { create(:user) }

  subject { described_class.new(user) }

  it 'destroys a key' do
    key = create(:key)

    expect { subject.execute(key) }.to change(Key, :count).by(-1)
  end
end