BigW Consortium Gitlab

admin_access_spec.rb 766 Bytes
Newer Older
gitlabhq committed
1 2
require 'spec_helper'

3
describe "Admin::Projects", feature: true  do
4 5
  include AccessMatchers

Nihad Abbasov committed
6
  describe "GET /admin/projects" do
Vinnie Okada committed
7
    subject { admin_namespaces_projects_path }
Robert Speicher committed
8

9 10 11
    it { is_expected.to be_allowed_for :admin }
    it { is_expected.to be_denied_for :user }
    it { is_expected.to be_denied_for :visitor }
gitlabhq committed
12 13
  end

Nihad Abbasov committed
14
  describe "GET /admin/users" do
Robert Speicher committed
15 16
    subject { admin_users_path }

17 18 19
    it { is_expected.to be_allowed_for :admin }
    it { is_expected.to be_denied_for :user }
    it { is_expected.to be_denied_for :visitor }
gitlabhq committed
20 21
  end

22
  describe "GET /admin/hooks" do
Robert Speicher committed
23 24
    subject { admin_hooks_path }

25 26 27
    it { is_expected.to be_allowed_for :admin }
    it { is_expected.to be_denied_for :user }
    it { is_expected.to be_denied_for :visitor }
gitlabhq committed
28 29
  end
end