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

destroy_service_spec.rb « gpg_keys « services « spec - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: b9aa3e351c9cc587ebc6948fab843002d8785025 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
# frozen_string_literal: true

require 'spec_helper'

RSpec.describe GpgKeys::DestroyService do
  let(:user) { create(:user) }

  subject { described_class.new(user) }

  it 'destroys the GPG key' do
    gpg_key = create(:gpg_key)

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