‪TYPO3CMS  9.5
ModuleMenuCest.php
Go to the documentation of this file.
1 <?php
2 declare(strict_types = 1);
4 
5 /*
6  * This file is part of the TYPO3 CMS project.
7  *
8  * It is free software; you can redistribute it and/or modify it under
9  * the terms of the GNU General Public License, either version 2
10  * of the License, or any later version.
11  *
12  * For the full copyright and license information, please read the
13  * LICENSE.txt file that was distributed with this source code.
14  *
15  * The TYPO3 project - inspiring people to share!
16  */
17 
19 
24 {
28  public function ‪_before(‪BackendTester $I)
29  {
30  $I->useExistingSession('admin');
31  }
32 
37  {
38  // A sub-element of web module is shown
39  $I->waitForElementVisible('#web .modulemenu-group-container .modulemenu-item');
40  $I->seeElement('#web .modulemenu-group-container .modulemenu-item');
41 
42  // Collapse web module and verify sub elements are hidden
43  $I->wantTo('collapse the menu element');
44  $I->waitForElementVisible('#web .modulemenu-group-header');
45  $I->click('#web .modulemenu-group-header');
46  $I->waitForElementNotVisible('#web .modulemenu-group-container .modulemenu-item');
47  $I->dontSeeElement('#web .modulemenu-group-container .modulemenu-item');
48 
49  // Expand again and verify sub elements are shown
50  $I->wantTo('expand the menu element again');
51  $I->click('#web .modulemenu-group-header');
52  $I->waitForElementVisible('#web .modulemenu-group-container .modulemenu-item');
53  $I->seeElement('#web .modulemenu-group-container .modulemenu-item');
54  }
55 
60  {
61  $I->seeNumberOfElements('#web .modulemenu-item-link', [2, 20]);
62 
63  $I->wantTo('check that the second element has no "active" class\'');
64  $I->cantSeeElement('#web #web_list.active');
65  $I->click('#web #web_list .modulemenu-item-link');
66 
67  $I->wantTo('see that the second element has an "active" class');
68  $I->canSeeElement('#web #web_list.active');
69  }
70 }
‪TYPO3\CMS\Core\Tests\Acceptance\Backend\General\ModuleMenuCest\checkIfModuleMenuIsCollapsible
‪checkIfModuleMenuIsCollapsible(BackendTester $I)
Definition: ModuleMenuCest.php:36
‪TYPO3\CMS\Core\Tests\Acceptance\Backend\General\ModuleMenuCest
Definition: ModuleMenuCest.php:24
‪TYPO3\CMS\Core\Tests\Acceptance\Backend\General\ModuleMenuCest\selectingAModuleDoesHighlightIt
‪selectingAModuleDoesHighlightIt(BackendTester $I)
Definition: ModuleMenuCest.php:59
‪TYPO3\CMS\Core\Tests\Acceptance\Backend\General\ModuleMenuCest\_before
‪_before(BackendTester $I)
Definition: ModuleMenuCest.php:28
‪TYPO3\CMS\Core\Tests\Acceptance\Support\BackendTester
Definition: BackendTester.php:25
‪TYPO3\CMS\Core\Tests\Acceptance\Backend\General
Definition: ModuleMenuCest.php:3