Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
UnlockAdminAccountCommandTest.php
Go to the documentation of this file.
1 <?php
8 
10 
14 class UnlockAdminAccountCommandTest extends \PHPUnit\Framework\TestCase
15 {
17  private $objectManager;
18 
22  private $command;
23 
27  protected function setUp()
28  {
29  $this->objectManager = new \Magento\Framework\TestFramework\Unit\Helper\ObjectManager($this);
30  parent::setUp();
31  }
32 
38  public function testConfigure()
39  {
40  $this->command = $this->objectManager
41  ->getObject(\Magento\User\Console\UnlockAdminAccountCommand::class);
42 
43  $this->assertEquals(UnlockAdminAccountCommand::COMMAND_ADMIN_ACCOUNT_UNLOCK, $this->command->getName());
44  $this->assertEquals(UnlockAdminAccountCommand::COMMAND_DESCRIPTION, $this->command->getDescription());
45  $this->command->getDefinition()->getArgument(UnlockAdminAccountCommand::ARGUMENT_ADMIN_USERNAME);
46  $this->assertContains('This command unlocks an admin account by its username', $this->command->getHelp());
47  }
48 }