public function ContactPermissionsTest::setUp in Contact Permissions 8.2
Same name and namespace in other branches
- 8 tests/src/Functional/ContactPermissionsTest.php \Drupal\Tests\contact_permissions\Functional\ContactPermissionsTest::setUp()
Overrides BrowserTestBase::setUp
File
- tests/
src/ Functional/ ContactPermissionsTest.php, line 55
Class
- ContactPermissionsTest
- Tests the permission provided by contact_permissions module.
Namespace
Drupal\Tests\contact_permissions\FunctionalCode
public function setUp() {
parent::setUp();
$contactable = $this
->drupalCreateUser();
$contactable
->addRole('contactable');
$contactable
->save();
$this->contactable = $contactable;
$noncontactable = $this
->drupalCreateUser();
$noncontactable
->addRole('noncontactable');
$noncontactable
->save();
$this->nonContactable = $noncontactable;
$this->admin = $this
->drupalCreateUser([], NULL, TRUE);
}