openproject-global_roles 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +15 -0
- data/CHANGELOG.md +22 -0
- data/README.md +89 -0
- data/app/assets/javascripts/global_roles/global_roles.js +91 -0
- data/app/assets/javascripts/global_roles/principal_roles.js +51 -0
- data/app/assets/stylesheets/global_roles/global_roles.css +18 -0
- data/app/controllers/principal_roles_controller.rb +139 -0
- data/app/models/global_role.rb +46 -0
- data/app/models/principal_role.rb +29 -0
- data/app/views/principal_roles/_errors.html.erb +13 -0
- data/app/views/principal_roles/_show_table_row.html.erb +28 -0
- data/app/views/principal_roles/index.html.erb +47 -0
- data/app/views/roles/_form.html.erb +52 -0
- data/app/views/roles/_global_attributes.html.erb +12 -0
- data/app/views/roles/_global_form.html.erb +12 -0
- data/app/views/roles/_member_attributes.html.erb +17 -0
- data/app/views/roles/_member_form.html.erb +39 -0
- data/app/views/roles/_permissions.html.erb +27 -0
- data/app/views/roles/edit.html.erb +20 -0
- data/app/views/roles/index.html.erb +57 -0
- data/app/views/roles/new.html.erb +18 -0
- data/app/views/shared/_global_roles_header.html.erb +16 -0
- data/app/views/users/_available_global_role.html.erb +14 -0
- data/app/views/users/_available_global_roles.html.erb +32 -0
- data/app/views/users/_global_roles.html.erb +33 -0
- data/config/locales/de.yml +11 -0
- data/config/locales/en.yml +11 -0
- data/config/routes.rb +14 -0
- data/db/migrate/001_sti_for_roles.rb +34 -0
- data/doc/COPYRIGHT.rdoc +16 -0
- data/doc/GPL.txt +674 -0
- data/lib/open_project/global_roles.rb +16 -0
- data/lib/open_project/global_roles/engine.rb +89 -0
- data/lib/open_project/global_roles/patches.rb +13 -0
- data/lib/open_project/global_roles/patches/access_control_patch.rb +41 -0
- data/lib/open_project/global_roles/patches/permission_patch.rb +49 -0
- data/lib/open_project/global_roles/patches/principal_patch.rb +24 -0
- data/lib/open_project/global_roles/patches/role_patch.rb +47 -0
- data/lib/open_project/global_roles/patches/roles_controller_patch.rb +62 -0
- data/lib/open_project/global_roles/patches/roles_helper_patch.rb +27 -0
- data/lib/open_project/global_roles/patches/user_patch.rb +24 -0
- data/lib/open_project/global_roles/patches/users_controller_patch.rb +34 -0
- data/lib/open_project/global_roles/patches/users_helper_patch.rb +39 -0
- data/lib/open_project/global_roles/principal_allowance_evaluator/global.rb +24 -0
- data/lib/open_project/global_roles/version.rb +16 -0
- data/lib/openproject-global_roles.rb +12 -0
- data/spec/controllers/principal_roles_controller_spec.rb +163 -0
- data/spec/controllers/roles_controller_spec.rb +315 -0
- data/spec/controllers/users_controller_spec.rb +57 -0
- data/spec/factories/global_role_factory.rb +16 -0
- data/spec/factories/principal_role_factory.rb +17 -0
- data/spec/lib/access_control_spec.rb +56 -0
- data/spec/lib/global_roles/principal_allowance_evaluator/global_spec.rb +84 -0
- data/spec/lib/loader_spec.rb +40 -0
- data/spec/lib/permission_spec.rb +41 -0
- data/spec/models/global_role_spec.rb +175 -0
- data/spec/models/principal_role_spec.rb +48 -0
- data/spec/models/principal_spec.rb +38 -0
- data/spec/models/role_spec.rb +43 -0
- data/spec/models/user_spec.rb +20 -0
- data/spec/plugin_spec_helper.rb +152 -0
- data/spec/spec_helper.rb +15 -0
- metadata +152 -0
@@ -0,0 +1,48 @@
|
|
1
|
+
#-- copyright
|
2
|
+
# OpenProject is a project management system.
|
3
|
+
#
|
4
|
+
# Copyright (C) 2010-2013 the OpenProject Team
|
5
|
+
#
|
6
|
+
# This program is free software; you can redistribute it and/or
|
7
|
+
# modify it under the terms of the GNU General Public License version 3.
|
8
|
+
#
|
9
|
+
# See doc/COPYRIGHT.rdoc for more details.
|
10
|
+
#++
|
11
|
+
|
12
|
+
require File.expand_path(File.dirname(__FILE__) + "/../spec_helper")
|
13
|
+
|
14
|
+
describe PrincipalRole do
|
15
|
+
|
16
|
+
describe "ATTRIBUTES" do
|
17
|
+
before :each do
|
18
|
+
|
19
|
+
end
|
20
|
+
|
21
|
+
it {should belong_to :principal}
|
22
|
+
it {should belong_to :role}
|
23
|
+
end
|
24
|
+
|
25
|
+
describe :valid? do
|
26
|
+
before(:each) do
|
27
|
+
@principal_role = FactoryGirl.build(:principal_role)
|
28
|
+
end
|
29
|
+
|
30
|
+
describe "role not assignable to user" do
|
31
|
+
before :each do
|
32
|
+
@principal_role.role.stub!(:assignable_to?).and_return(false)
|
33
|
+
end
|
34
|
+
|
35
|
+
it { @principal_role.valid?.should be_false }
|
36
|
+
it { @principal_role.valid?
|
37
|
+
@principal_role.errors[:base].should include(I18n.t(:error_can_not_be_assigned))}
|
38
|
+
end
|
39
|
+
|
40
|
+
describe "role assignable to user" do
|
41
|
+
before(:each) do
|
42
|
+
@principal_role.role.stub!(:assignable_to?).and_return(true)
|
43
|
+
end
|
44
|
+
|
45
|
+
it { @principal_role.valid?.should be_true }
|
46
|
+
end
|
47
|
+
end
|
48
|
+
end
|
@@ -0,0 +1,38 @@
|
|
1
|
+
#-- copyright
|
2
|
+
# OpenProject is a project management system.
|
3
|
+
#
|
4
|
+
# Copyright (C) 2010-2013 the OpenProject Team
|
5
|
+
#
|
6
|
+
# This program is free software; you can redistribute it and/or
|
7
|
+
# modify it under the terms of the GNU General Public License version 3.
|
8
|
+
#
|
9
|
+
# See doc/COPYRIGHT.rdoc for more details.
|
10
|
+
#++
|
11
|
+
|
12
|
+
require File.dirname(__FILE__) + '/../spec_helper'
|
13
|
+
|
14
|
+
describe Principal do
|
15
|
+
describe "ATTRIBUTES" do
|
16
|
+
before :each do
|
17
|
+
|
18
|
+
end
|
19
|
+
|
20
|
+
it { should have_many :principal_roles }
|
21
|
+
it { should have_many :global_roles }
|
22
|
+
|
23
|
+
end
|
24
|
+
|
25
|
+
describe "WHEN deleting a principal" do
|
26
|
+
let(:principal) { FactoryGirl.build(:user) }
|
27
|
+
let(:role) { FactoryGirl.build(:global_role) }
|
28
|
+
|
29
|
+
before do
|
30
|
+
FactoryGirl.create(:principal_role, :role => role,
|
31
|
+
:principal => principal)
|
32
|
+
principal.destroy
|
33
|
+
end
|
34
|
+
|
35
|
+
it { Role.find_by_id(role.id).should == role }
|
36
|
+
it { PrincipalRole.find_all_by_principal_id(principal.id).should == [] }
|
37
|
+
end
|
38
|
+
end
|
@@ -0,0 +1,43 @@
|
|
1
|
+
#-- copyright
|
2
|
+
# OpenProject is a project management system.
|
3
|
+
#
|
4
|
+
# Copyright (C) 2010-2013 the OpenProject Team
|
5
|
+
#
|
6
|
+
# This program is free software; you can redistribute it and/or
|
7
|
+
# modify it under the terms of the GNU General Public License version 3.
|
8
|
+
#
|
9
|
+
# See doc/COPYRIGHT.rdoc for more details.
|
10
|
+
#++
|
11
|
+
|
12
|
+
require File.expand_path(File.dirname(__FILE__) + "/../spec_helper")
|
13
|
+
|
14
|
+
describe Role do
|
15
|
+
describe "class methods" do
|
16
|
+
describe :givable do
|
17
|
+
before (:each) do
|
18
|
+
#this should not be necessary once Role (in a membership) and GlobalRole have
|
19
|
+
#a common ancestor class, e.g. Role (a new one)
|
20
|
+
@mem_role1 = Role.create :name => "mem_role", :permissions => []
|
21
|
+
@builtin_role1 = Role.new :name => "builtin_role1", :permissions => []
|
22
|
+
@builtin_role1.builtin = 3
|
23
|
+
@builtin_role1.save
|
24
|
+
@global_role1 = GlobalRole.create :name => "global_role1", :permissions => []
|
25
|
+
end
|
26
|
+
|
27
|
+
it {Role.find_all_givable.should have(1).items}
|
28
|
+
it {Role.find_all_givable[0].should eql @mem_role1}
|
29
|
+
end
|
30
|
+
end
|
31
|
+
|
32
|
+
describe "instance methods" do
|
33
|
+
before (:each) do
|
34
|
+
@role = Role.new
|
35
|
+
end
|
36
|
+
|
37
|
+
describe :setable_permissions do
|
38
|
+
before {mock_permissions_for_setable_permissions}
|
39
|
+
|
40
|
+
it {@role.setable_permissions.should eql([@perm1, @perm2])}
|
41
|
+
end
|
42
|
+
end
|
43
|
+
end
|
@@ -0,0 +1,20 @@
|
|
1
|
+
#-- copyright
|
2
|
+
# OpenProject is a project management system.
|
3
|
+
#
|
4
|
+
# Copyright (C) 2010-2013 the OpenProject Team
|
5
|
+
#
|
6
|
+
# This program is free software; you can redistribute it and/or
|
7
|
+
# modify it under the terms of the GNU General Public License version 3.
|
8
|
+
#
|
9
|
+
# See doc/COPYRIGHT.rdoc for more details.
|
10
|
+
#++
|
11
|
+
|
12
|
+
require File.dirname(__FILE__) + '/../spec_helper'
|
13
|
+
|
14
|
+
describe User do
|
15
|
+
let(:klass) { User }
|
16
|
+
|
17
|
+
describe :registered_allowance_evaluators do
|
18
|
+
it { klass.registered_allowance_evaluators.should include(OpenProject::GlobalRoles::PrincipalAllowanceEvaluator::Global) }
|
19
|
+
end
|
20
|
+
end
|
@@ -0,0 +1,152 @@
|
|
1
|
+
#-- copyright
|
2
|
+
# OpenProject is a project management system.
|
3
|
+
#
|
4
|
+
# Copyright (C) 2010-2013 the OpenProject Team
|
5
|
+
#
|
6
|
+
# This program is free software; you can redistribute it and/or
|
7
|
+
# modify it under the terms of the GNU General Public License version 3.
|
8
|
+
#
|
9
|
+
# See doc/COPYRIGHT.rdoc for more details.
|
10
|
+
#++
|
11
|
+
|
12
|
+
module OpenProject
|
13
|
+
module GlobalRoles
|
14
|
+
module PluginSpecHelper
|
15
|
+
def mobile_tan_plugin_loaded?
|
16
|
+
plugin_loaded?("openproject_mobile_otp_authentication")
|
17
|
+
end
|
18
|
+
|
19
|
+
def privacy_plugin_loaded?
|
20
|
+
plugin_loaded?("openproject_dtag_privacy")
|
21
|
+
end
|
22
|
+
|
23
|
+
def costs_plugin_loaded?
|
24
|
+
plugin_loaded?("openproject_costs")
|
25
|
+
end
|
26
|
+
|
27
|
+
def plugin_loaded?(name)
|
28
|
+
Redmine::Plugin.all.detect {|x| x.id == name.to_sym}.present?
|
29
|
+
end
|
30
|
+
|
31
|
+
def mocks_for_member_roles
|
32
|
+
@role = mock_model Role
|
33
|
+
Role.stub!(:new).and_return(@role)
|
34
|
+
|
35
|
+
mock_permissions_on @role
|
36
|
+
|
37
|
+
mock_role_find
|
38
|
+
|
39
|
+
@non_mem = mock_model Role
|
40
|
+
@non_mem.stub!(:permissions).and_return(@non_mem_perm)
|
41
|
+
Role.stub!(:non_member).and_return(@non_mem)
|
42
|
+
@non_mem_perm = [:nm_perm1, :nm_perm2]
|
43
|
+
end
|
44
|
+
|
45
|
+
def mocks_for_global_roles
|
46
|
+
@role = mock_model GlobalRole
|
47
|
+
GlobalRole.stub!(:new).and_return(@role)
|
48
|
+
mock_permissions_on @role
|
49
|
+
end
|
50
|
+
|
51
|
+
def mock_permissions_on role
|
52
|
+
permissions = [:perm1, :perm2, :perm3]
|
53
|
+
role.stub!(:setable_permissions).and_return(permissions)
|
54
|
+
role.stub!(:permissions).and_return(permissions << :perm4)
|
55
|
+
end
|
56
|
+
|
57
|
+
def mock_role_find
|
58
|
+
mock_member_role_find
|
59
|
+
mock_global_role_find
|
60
|
+
end
|
61
|
+
|
62
|
+
def mock_member_role_find
|
63
|
+
@role1 = mock_model Role
|
64
|
+
@role2 = mock_model Role
|
65
|
+
@global_role1 = mock_model GlobalRole
|
66
|
+
@global_role2 = mock_model GlobalRole
|
67
|
+
@roles = [@role1, @global_role2, @role2, @global_role1]
|
68
|
+
Role.stub!(:find).and_return(@roles)
|
69
|
+
Role.stub!(:all).and_return(@roles)
|
70
|
+
Role.stub!(:order).and_return(@roles)
|
71
|
+
@roles.stub!(:page).and_return(@roles)
|
72
|
+
@roles.stub!(:per_page).and_return(@roles)
|
73
|
+
end
|
74
|
+
|
75
|
+
def mock_global_role_find
|
76
|
+
@global_role1 = mock_model GlobalRole
|
77
|
+
@global_role2 = mock_model GlobalRole
|
78
|
+
@global_roles = [@global_role1, @global_role2]
|
79
|
+
GlobalRole.stub!(:find).and_return(@global_roles)
|
80
|
+
GlobalRole.stub!(:all).and_return(@global_roles)
|
81
|
+
end
|
82
|
+
|
83
|
+
def mocks_for_creating role_class
|
84
|
+
role = mock_model role_class
|
85
|
+
role_class.stub!(:new).and_return role
|
86
|
+
mock_permissions_on role
|
87
|
+
role
|
88
|
+
end
|
89
|
+
|
90
|
+
def disable_flash_sweep
|
91
|
+
@controller.instance_eval{flash.stub!(:sweep)}
|
92
|
+
end
|
93
|
+
|
94
|
+
def disable_log_requesting_user
|
95
|
+
@controller.stub!(:log_requesting_user)
|
96
|
+
end
|
97
|
+
|
98
|
+
def response_should_render method, *params
|
99
|
+
unless @page
|
100
|
+
@page ||= mock("page")
|
101
|
+
controller.should_receive(:render).with(:update).and_yield(@page)
|
102
|
+
#fix for implicit render without parameters being called in test
|
103
|
+
controller.should_receive(:render).with
|
104
|
+
end
|
105
|
+
|
106
|
+
@page.should_receive(method).with(*params)
|
107
|
+
end
|
108
|
+
|
109
|
+
def mock_permissions_for_setable_permissions
|
110
|
+
@public_perm = mock_permissions(true, false)
|
111
|
+
@perm1 = mock_permissions(false, false)
|
112
|
+
@perm2 = mock_permissions(false, false)
|
113
|
+
@global_perm = mock_permissions(false, true)
|
114
|
+
|
115
|
+
@perms = [@public_perm, @perm1, @global_perm, @perm2]
|
116
|
+
Redmine::AccessControl.stub!(:permissions).and_return(@perms)
|
117
|
+
Redmine::AccessControl.stub!(:public_permissions).and_return([@public_perm])
|
118
|
+
Redmine::AccessControl.stub!(:global_permissions).and_return([@global_perm])
|
119
|
+
end
|
120
|
+
|
121
|
+
def mock_permissions(is_public, is_global)
|
122
|
+
permission = Object.new
|
123
|
+
permission.stub!(:public?).and_return(is_public)
|
124
|
+
permission.stub!(:global?).and_return(is_global)
|
125
|
+
permission
|
126
|
+
end
|
127
|
+
|
128
|
+
def create_non_member_role
|
129
|
+
create_builtin_role 'No member', Role::BUILTIN_NON_MEMBER
|
130
|
+
end
|
131
|
+
|
132
|
+
def create_anonymous_role
|
133
|
+
create_builtin_role "Anonymous", Role::BUILTIN_ANONYMOUS
|
134
|
+
end
|
135
|
+
|
136
|
+
def create_builtin_role(name, const)
|
137
|
+
Role.create(:name => name, :position => 0) do |role|
|
138
|
+
role.builtin = const
|
139
|
+
end
|
140
|
+
end
|
141
|
+
|
142
|
+
def stash_access_control_permissions
|
143
|
+
@stashed_permissions = Redmine::AccessControl.permissions.dup
|
144
|
+
Redmine::AccessControl.permissions.clear
|
145
|
+
end
|
146
|
+
|
147
|
+
def restore_access_control_permissions
|
148
|
+
Redmine::AccessControl.instance_variable_set(:@permissions, @stashed_permissions)
|
149
|
+
end
|
150
|
+
end
|
151
|
+
end
|
152
|
+
end
|
data/spec/spec_helper.rb
ADDED
@@ -0,0 +1,15 @@
|
|
1
|
+
#-- copyright
|
2
|
+
# OpenProject is a project management system.
|
3
|
+
#
|
4
|
+
# Copyright (C) 2010-2013 the OpenProject Team
|
5
|
+
#
|
6
|
+
# This program is free software; you can redistribute it and/or
|
7
|
+
# modify it under the terms of the GNU General Public License version 3.
|
8
|
+
#
|
9
|
+
# See doc/COPYRIGHT.rdoc for more details.
|
10
|
+
#++
|
11
|
+
|
12
|
+
require 'spec_helper'
|
13
|
+
|
14
|
+
require File.join(File.dirname(__FILE__), 'plugin_spec_helper')
|
15
|
+
include OpenProject::GlobalRoles::PluginSpecHelper
|
metadata
ADDED
@@ -0,0 +1,152 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: openproject-global_roles
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 1.0.0
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Finn GmbH
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2013-08-26 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: rails
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - ~>
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: 3.2.9
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - ~>
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: 3.2.9
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: factory_girl_rails
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - ~>
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '4.0'
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - ~>
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '4.0'
|
41
|
+
description: ! "Adds global roles not bound to a project. A user can have a global
|
42
|
+
role allowing to\n perform actions outside of the scope of a specific project normally
|
43
|
+
only allowed for administrators.\n By assigning the permission to create projects
|
44
|
+
to a global role, non-administrators can create top-level projects."
|
45
|
+
email: info@finn.de
|
46
|
+
executables: []
|
47
|
+
extensions: []
|
48
|
+
extra_rdoc_files: []
|
49
|
+
files:
|
50
|
+
- app/assets/javascripts/global_roles/principal_roles.js
|
51
|
+
- app/assets/javascripts/global_roles/global_roles.js
|
52
|
+
- app/assets/stylesheets/global_roles/global_roles.css
|
53
|
+
- app/controllers/principal_roles_controller.rb
|
54
|
+
- app/views/shared/_global_roles_header.html.erb
|
55
|
+
- app/views/roles/_member_attributes.html.erb
|
56
|
+
- app/views/roles/edit.html.erb
|
57
|
+
- app/views/roles/index.html.erb
|
58
|
+
- app/views/roles/new.html.erb
|
59
|
+
- app/views/roles/_global_form.html.erb
|
60
|
+
- app/views/roles/_member_form.html.erb
|
61
|
+
- app/views/roles/_permissions.html.erb
|
62
|
+
- app/views/roles/_global_attributes.html.erb
|
63
|
+
- app/views/roles/_form.html.erb
|
64
|
+
- app/views/users/_global_roles.html.erb
|
65
|
+
- app/views/users/_available_global_roles.html.erb
|
66
|
+
- app/views/users/_available_global_role.html.erb
|
67
|
+
- app/views/principal_roles/index.html.erb
|
68
|
+
- app/views/principal_roles/_show_table_row.html.erb
|
69
|
+
- app/views/principal_roles/_errors.html.erb
|
70
|
+
- app/models/global_role.rb
|
71
|
+
- app/models/principal_role.rb
|
72
|
+
- config/routes.rb
|
73
|
+
- config/locales/de.yml
|
74
|
+
- config/locales/en.yml
|
75
|
+
- db/migrate/001_sti_for_roles.rb
|
76
|
+
- lib/openproject-global_roles.rb
|
77
|
+
- lib/open_project/global_roles/version.rb
|
78
|
+
- lib/open_project/global_roles/engine.rb
|
79
|
+
- lib/open_project/global_roles/patches.rb
|
80
|
+
- lib/open_project/global_roles/patches/permission_patch.rb
|
81
|
+
- lib/open_project/global_roles/patches/user_patch.rb
|
82
|
+
- lib/open_project/global_roles/patches/roles_helper_patch.rb
|
83
|
+
- lib/open_project/global_roles/patches/users_controller_patch.rb
|
84
|
+
- lib/open_project/global_roles/patches/access_control_patch.rb
|
85
|
+
- lib/open_project/global_roles/patches/roles_controller_patch.rb
|
86
|
+
- lib/open_project/global_roles/patches/role_patch.rb
|
87
|
+
- lib/open_project/global_roles/patches/users_helper_patch.rb
|
88
|
+
- lib/open_project/global_roles/patches/principal_patch.rb
|
89
|
+
- lib/open_project/global_roles/principal_allowance_evaluator/global.rb
|
90
|
+
- lib/open_project/global_roles.rb
|
91
|
+
- doc/COPYRIGHT.rdoc
|
92
|
+
- doc/GPL.txt
|
93
|
+
- CHANGELOG.md
|
94
|
+
- README.md
|
95
|
+
- spec/spec_helper.rb
|
96
|
+
- spec/controllers/users_controller_spec.rb
|
97
|
+
- spec/controllers/roles_controller_spec.rb
|
98
|
+
- spec/controllers/principal_roles_controller_spec.rb
|
99
|
+
- spec/models/principal_spec.rb
|
100
|
+
- spec/models/principal_role_spec.rb
|
101
|
+
- spec/models/user_spec.rb
|
102
|
+
- spec/models/role_spec.rb
|
103
|
+
- spec/models/global_role_spec.rb
|
104
|
+
- spec/plugin_spec_helper.rb
|
105
|
+
- spec/lib/permission_spec.rb
|
106
|
+
- spec/lib/access_control_spec.rb
|
107
|
+
- spec/lib/global_roles/principal_allowance_evaluator/global_spec.rb
|
108
|
+
- spec/lib/loader_spec.rb
|
109
|
+
- spec/factories/principal_role_factory.rb
|
110
|
+
- spec/factories/global_role_factory.rb
|
111
|
+
homepage: https://www.openproject.org/projects/plugin-global-roles
|
112
|
+
licenses:
|
113
|
+
- GPLv3
|
114
|
+
metadata: {}
|
115
|
+
post_install_message:
|
116
|
+
rdoc_options: []
|
117
|
+
require_paths:
|
118
|
+
- lib
|
119
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
120
|
+
requirements:
|
121
|
+
- - ! '>='
|
122
|
+
- !ruby/object:Gem::Version
|
123
|
+
version: '0'
|
124
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
125
|
+
requirements:
|
126
|
+
- - ! '>='
|
127
|
+
- !ruby/object:Gem::Version
|
128
|
+
version: '0'
|
129
|
+
requirements: []
|
130
|
+
rubyforge_project:
|
131
|
+
rubygems_version: 2.0.7
|
132
|
+
signing_key:
|
133
|
+
specification_version: 4
|
134
|
+
summary: An OpenProject plugin to define global roles.
|
135
|
+
test_files:
|
136
|
+
- spec/spec_helper.rb
|
137
|
+
- spec/controllers/users_controller_spec.rb
|
138
|
+
- spec/controllers/roles_controller_spec.rb
|
139
|
+
- spec/controllers/principal_roles_controller_spec.rb
|
140
|
+
- spec/models/principal_spec.rb
|
141
|
+
- spec/models/principal_role_spec.rb
|
142
|
+
- spec/models/user_spec.rb
|
143
|
+
- spec/models/role_spec.rb
|
144
|
+
- spec/models/global_role_spec.rb
|
145
|
+
- spec/plugin_spec_helper.rb
|
146
|
+
- spec/lib/permission_spec.rb
|
147
|
+
- spec/lib/access_control_spec.rb
|
148
|
+
- spec/lib/global_roles/principal_allowance_evaluator/global_spec.rb
|
149
|
+
- spec/lib/loader_spec.rb
|
150
|
+
- spec/factories/principal_role_factory.rb
|
151
|
+
- spec/factories/global_role_factory.rb
|
152
|
+
has_rdoc:
|