kanbanworkflowstimelinescrumrubyroadmapproject-planningproject-managementopenprojectangularissue-trackerifcgantt-chartganttbug-trackerboardsbcf
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
80 lines
3.2 KiB
80 lines
3.2 KiB
11 years ago
|
#-- copyright
|
||
11 years ago
|
# OpenProject Global Roles Plugin
|
||
11 years ago
|
#
|
||
11 years ago
|
# Copyright (C) 2010 - 2014 the OpenProject Foundation (OPF)
|
||
11 years ago
|
#
|
||
|
# This program is free software; you can redistribute it and/or
|
||
11 years ago
|
# modify it under the terms of the GNU General Public License
|
||
|
# version 3.
|
||
11 years ago
|
#
|
||
11 years ago
|
# This program is distributed in the hope that it will be useful,
|
||
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||
|
# GNU General Public License for more details.
|
||
|
#
|
||
|
# You should have received a copy of the GNU General Public License
|
||
|
# along with this program; if not, write to the Free Software
|
||
|
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||
11 years ago
|
#++
|
||
|
|
||
14 years ago
|
Feature: Global Role Assignment
|
||
|
|
||
14 years ago
|
@javascript
|
||
|
Scenario: Going to the global role assignment page
|
||
|
Given there is the global permission "global1" of the module "global"
|
||
|
And there is the global permission "global2" of the module "global"
|
||
|
And there is a global role "global_role1"
|
||
|
And there is a global role "global_role2"
|
||
|
And the global role "global_role1" may have the following rights:
|
||
|
| global1 |
|
||
|
And the global role "global_role2" may have the following rights:
|
||
|
| global2 |
|
||
|
And there is 1 User with:
|
||
|
| Login | bob |
|
||
|
| Firstname | Bob |
|
||
|
| Lastname | Bobbit |
|
||
|
And the user "bob" has the global role "global_role1"
|
||
11 years ago
|
And I am already admin
|
||
14 years ago
|
When I go to the edit page of the user called "bob"
|
||
|
And I click on "tab-global_roles"
|
||
|
Then I should see "global_role1" within "#table_principal_roles"
|
||
|
And I should not see "global_role1" within "#available_principal_roles"
|
||
|
And I should see "global_role2" within "#available_principal_roles"
|
||
|
|
||
14 years ago
|
@javascript
|
||
14 years ago
|
Scenario: Assigning a global role to a user
|
||
14 years ago
|
Given there is the global permission "global1" of the module "global"
|
||
14 years ago
|
And there is a global role "global_role"
|
||
|
And the global role "global_role" may have the following rights:
|
||
|
| global1 |
|
||
14 years ago
|
And there is 1 User with:
|
||
|
| Login | bob |
|
||
|
| Firstname | Bob |
|
||
|
| Lastname | Bobbit |
|
||
11 years ago
|
And I am already admin
|
||
14 years ago
|
When I go to the edit page of the user called "bob"
|
||
|
And I click on "tab-global_roles"
|
||
14 years ago
|
And I select the available global role "global_role"
|
||
13 years ago
|
And I press "Add"
|
||
14 years ago
|
Then I should see "global_role" within "#table_principal_roles"
|
||
14 years ago
|
And I should not see "global_role" within "#available_principal_roles"
|
||
9 years ago
|
And I should see "There is currently nothing to display"
|
||
14 years ago
|
|
||
|
@javascript
|
||
|
Scenario: Deleting a global role of a user
|
||
|
Given there is the global permission "global1" of the module "global"
|
||
|
And there is a global role "global_role"
|
||
|
And the global role "global_role" may have the following rights:
|
||
|
| global1 |
|
||
|
And there is 1 User with:
|
||
|
| Login | bob |
|
||
|
| Firstname | Bob |
|
||
|
| Lastname | Bobbit |
|
||
|
And the user "bob" has the global role "global_role"
|
||
11 years ago
|
And I am already admin
|
||
14 years ago
|
When I go to the edit page of the user called "bob"
|
||
|
And I click on "tab-global_roles"
|
||
|
And I delete the assigned role "global_role"
|
||
9 years ago
|
Then I should see "Nothing to display" within "#assigned_principal_roles"
|
||
13 years ago
|
And I should see "global_role" within "#available_principal_roles"
|