Skip to content
Snippets Groups Projects
Commit e8824421 authored by Roger Codina's avatar Roger Codina
Browse files

Moved Role Expire configuration form to Configuration > People > Role expire

parent 5fa9f7ee
No related branches found
Tags 7.x-2.0-beta1
No related merge requests found
Role expire 2.0.1, XXXX-XX-XX
Role expire 2.0.1, 2021-07-03
-----------------------------
#3193800: RoleExpiresEvent should not depend on Rules module
#3203077: Create additional permissions
#3213495: Highlight relative expiry dates can be set using rules action
Moved Role Expire configuration form to "Configuration > People > Role expire"
Role expire 2.0.0, 2020-12-24
-----------------------------
......
......@@ -57,7 +57,7 @@ INSTALLATION
CONFIGURATION
-------------
* Configure module's options in Administration » Configuration » System
* Configure module's options in Administration » Configuration » People
» Role Expire:
- Configure a default role after each role expiration.
......
......@@ -2,4 +2,4 @@ role_expire.config:
title: Role Expire
description: 'Configure a default role after each role expiration'
route_name: role_expire.config
parent: system.admin_config_system
parent: user.admin_index
administer role expire:
title: 'Administer role expire'
description: 'Allow users to configure module (admin/config/system/role-expire).'
description: 'Allow users to configure module (admin/config/people/role-expire).'
restrict access: TRUE
edit users role expire:
title: 'Edit users role expire'
......
role_expire.config:
path: 'admin/config/system/role-expire'
path: 'admin/config/people/role-expire'
defaults:
_form: 'Drupal\role_expire\Form\RoleExpireConfigurationForm'
_title: 'Role expire'
......
......@@ -48,7 +48,7 @@ class UiRoleExpireTest extends BrowserTestBase {
$account = $this->drupalCreateUser(['administer role expire']);
$this->drupalLogin($account);
$this->drupalGet('admin/config/system/role-expire');
$this->drupalGet('admin/config/people/role-expire');
$this->assertSession()->statusCodeEquals(200);
// Test that we can set default roles after a roles expires.
......@@ -97,13 +97,13 @@ class UiRoleExpireTest extends BrowserTestBase {
// We assign a role to assign after each role expires.
$test_def = 'test_role_two';
$test_two_def = 'test_role';
$this->drupalGet('admin/config/system/role-expire');
$this->drupalGet('admin/config/people/role-expire');
$this->getSession()->getPage()->selectFieldOption('edit-test-role', $test_def);
$this->getSession()->getPage()->selectFieldOption('edit-test-role-two', $test_two_def);
$this->getSession()->getPage()->pressButton('Save configuration');
$this->assertSession()->statusCodeEquals(200);
$this->drupalGet('admin/config/system/role-expire');
$this->drupalGet('admin/config/people/role-expire');
$this->assertSession()->statusCodeEquals(200);
$stored_value = $this->getSession()->getPage()->findField('edit-test-role')->getValue();
......@@ -127,14 +127,14 @@ class UiRoleExpireTest extends BrowserTestBase {
// First role enabled and second one disabled.
$test_def = 1;
$test_two_def = 0;
$this->drupalGet('admin/config/system/role-expire');
$this->drupalGet('admin/config/people/role-expire');
$this->getSession()->getPage()->checkField('edit-disable-test-role');
$this->getSession()->getPage()->uncheckField('edit-disable-test-role-two');
$this->getSession()->getPage()->pressButton('Save configuration');
$this->assertSession()->statusCodeEquals(200);
$this->drupalGet('admin/config/system/role-expire');
$this->drupalGet('admin/config/people/role-expire');
$this->assertSession()->statusCodeEquals(200);
$stored_value = $this->getSession()->getPage()->findField('edit-disable-test-role')->getValue();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment