‪TYPO3CMS  11.5
InstalledExtensionsCest.php
Go to the documentation of this file.
1 <?php
2 
3 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 
21 
26 {
30  public function ‪_before(‪ApplicationTester $I): void
31  {
32  $I->useExistingSession('admin');
33 
34  $I->click('Extensions', '#modulemenu');
35  $I->switchToContentFrame();
36  $I->waitForElementVisible('#typo3-extension-list');
37  }
38 
43  {
44  $I->seeNumberOfElements('#typo3-extension-list tbody tr[role="row"]', [10, 100]);
45 
46  // Fill extension search field
47  $I->fillField('Tx_Extensionmanager_extensionkey', 'backend');
48  $I->waitForElementNotVisible('tr#core');
49 
50  // see 2 rows. 1 for the header and one for the result
51  $I->seeNumberOfElements('#typo3-extension-list tbody tr[role="row"]', 3);
52 
53  // Look for extension key
54  $I->see('backend', '#typo3-extension-list tbody tr[role="row"] td');
55 
56  // unset the filter
57  $I->waitForElementVisible('#Tx_Extensionmanager_extensionkey ~button.close', 10);
58  $I->click('#Tx_Extensionmanager_extensionkey ~button.close');
59  $I->wait(1);
60  $I->seeNumberOfElements('#typo3-extension-list tbody tr[role="row"]', [10, 100]);
61  }
62 
68  {
69  $I->cantSeeElement('.module-body .extension-upload-form');
70  $I->click('a[title="Upload Extension"]', '.module-docheader');
71  $I->seeElement('.module-body .extension-upload-form');
72  }
73 
79  {
80  $I->wantTo('Check if uninstalling and installing an extension with backend module removes and adds the module from the module menu.');
81  $I->amGoingTo('uninstall extension belog');
82  $I->switchToMainFrame();
83  $I->seeElement('#system_BelogLog');
84 
85  $I->switchToContentFrame();
86  $I->waitForElementVisible('//*[@id="typo3-extension-list"]/tbody/tr[@id="belog"]');
87  $I->click('a[aria-label="Deactivate"]', '//*[@id="typo3-extension-list"]/tbody/tr[@id="belog"]');
88 
89  $I->switchToMainFrame();
90  $I->cantSeeElement('#system_BelogLog');
91 
92  $I->amGoingTo('install extension belog');
93  $I->switchToMainFrame();
94  $I->seeElement('.modulemenu-action');
95  $I->cantSeeElement('#system_BelogLog');
96 
97  $I->switchToContentFrame();
98  $I->waitForElementVisible('//*[@id="typo3-extension-list"]/tbody/tr[@id="belog"]');
99  $I->click('a[aria-label="Activate"]', '//*[@id="typo3-extension-list"]/tbody/tr[@id="belog"]');
100 
101  $I->switchToMainFrame();
102  $I->seeElement('#system_BelogLog');
103  }
104 }
‪TYPO3\CMS\Core\Tests\Acceptance\Application\Extensionmanager\InstalledExtensionsCest\checkUninstallingAndInstallingAnExtension
‪checkUninstallingAndInstallingAnExtension(ApplicationTester $I)
Definition: InstalledExtensionsCest.php:78
‪TYPO3\CMS\Core\Tests\Acceptance\Support\ApplicationTester
Definition: ApplicationTester.php:27
‪TYPO3\CMS\Core\Tests\Acceptance\Application\Extensionmanager\InstalledExtensionsCest\checkIfUploadFormAppears
‪checkIfUploadFormAppears(ApplicationTester $I)
Definition: InstalledExtensionsCest.php:67
‪TYPO3\CMS\Core\Tests\Acceptance\Application\Extensionmanager\InstalledExtensionsCest
Definition: InstalledExtensionsCest.php:26
‪TYPO3\CMS\Core\Tests\Acceptance\Application\Extensionmanager
Definition: GetExtensionsCest.php:18
‪TYPO3\CMS\Core\Tests\Acceptance\Application\Extensionmanager\InstalledExtensionsCest\checkSearchFiltersList
‪checkSearchFiltersList(ApplicationTester $I)
Definition: InstalledExtensionsCest.php:42
‪TYPO3\CMS\Core\Tests\Acceptance\Application\Extensionmanager\InstalledExtensionsCest\_before
‪_before(ApplicationTester $I)
Definition: InstalledExtensionsCest.php:30