function DevelGenerateCommandsTest::testDrushGenerateUsers
Same name in other branches
- 4.x devel_generate/tests/src/Functional/DevelGenerateCommandsTest.php \Drupal\Tests\devel_generate\Functional\DevelGenerateCommandsTest::testDrushGenerateUsers()
Tests generating users.
File
-
devel_generate/
tests/ src/ Functional/ DevelGenerateCommandsTest.php, line 66
Class
- DevelGenerateCommandsTest
- Test class for the Devel Generate drush commands.
Namespace
Drupal\Tests\devel_generate\FunctionalCode
public function testDrushGenerateUsers() : void {
// Make sure users get created, and with correct roles.
$this->drush(DevelGenerateCommands::USERS, [
'55',
], [
'kill' => NULL,
'roles' => 'administrator',
]);
$user = User::load(55);
$this->assertTrue($user->hasRole('administrator'));
}