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

agent_authorization_spec.rb « clusters « entities « api « lib « spec - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 101a8af4ac4d66cf1526dc0e2b1838a08311cc65 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# frozen_string_literal: true

require 'spec_helper'

RSpec.describe API::Entities::Clusters::AgentAuthorization do
  let_it_be(:authorization) { create(:agent_group_authorization) }

  subject { described_class.new(authorization).as_json }

  it 'includes basic fields' do
    expect(subject).to include(
      id: authorization.agent_id,
      config_project: a_hash_including(id: authorization.agent.project_id),
      configuration: authorization.config
    )
  end
end