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

admin_access_spec.rb « security « features « spec - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 9b2c873b2aab1626863ddc20cbd9af0e1294bb64 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# frozen_string_literal: true

require 'spec_helper'

describe "Admin::Projects" do
  include AccessMatchers

  describe "GET /admin/projects" do
    subject { admin_projects_path }

    it { is_expected.to be_allowed_for :admin }
    it { is_expected.to be_denied_for :user }
    it { is_expected.to be_denied_for :visitor }
  end

  describe "GET /admin/users" do
    subject { admin_users_path }

    it { is_expected.to be_allowed_for :admin }
    it { is_expected.to be_denied_for :user }
    it { is_expected.to be_denied_for :visitor }
  end

  describe "GET /admin/hooks" do
    subject { admin_hooks_path }

    it { is_expected.to be_allowed_for :admin }
    it { is_expected.to be_denied_for :user }
    it { is_expected.to be_denied_for :visitor }
  end
end