Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
LogoutUserOnBackendStep.php
Go to the documentation of this file.
1 <?php
8 
10 use Magento\Backend\Test\Page\Adminhtml\Dashboard;
11 use Magento\Mtf\TestStep\TestStepInterface;
12 
16 class LogoutUserOnBackendStep implements TestStepInterface
17 {
23  protected $adminAuth;
24 
30  protected $dashboard;
31 
37  public function __construct(AdminAuthLogin $adminAuth, Dashboard $dashboard)
38  {
39  $this->adminAuth = $adminAuth;
40  $this->dashboard = $dashboard;
41  }
42 
48  public function run()
49  {
50  $this->adminAuth->open();
51  $this->dashboard->getSystemMessageDialog()->closePopup();
52  $this->dashboard->getAdminPanelHeader()->logOut();
53  }
54 }
__construct(AdminAuthLogin $adminAuth, Dashboard $dashboard)