summaryrefslogtreecommitdiff
path: root/spec/graphql/mutations/security/ci_configuration/base_security_analyzer_spec.rb
blob: c081f9f0cd205fc75cd9a6cc038855edd771d3b9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
# frozen_string_literal: true

require 'spec_helper'

RSpec.describe Mutations::Security::CiConfiguration::BaseSecurityAnalyzer do
  include GraphqlHelpers

  it 'raises a NotImplementedError error if the resolve method is called on the base class' do
    user = create(:user)
    mutation = described_class.new(context: { current_user: user }, object: nil, field: nil)
    project = create(:project, :public, :repository)
    project.add_developer(user)

    expect { mutation.resolve(project_path: project.full_path) }.to raise_error(NotImplementedError)
  end
end