‪TYPO3CMS  9.5
SysNoteCest.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 
18 use Codeception\Util\Locator;
21 
26 {
30  public function ‪_before(‪BackendTester $I)
31  {
32  $I->useExistingSession('admin');
33  }
34 
39  public function ‪notesEntryCanBeEdited(‪BackendTester $I, ‪PageTree $pageTree)
40  {
41  $I->wantToTest('whether sysnote entries can be edited via the Internal Notes section in List View');
42 
43  $I->amGoingTo('create a record');
44  $I->click('List');
45  $I->waitForElementNotVisible('#nprogress');
46  $pageTree->openPath(['styleguide TCA demo']);
47  $I->wait(0.2);
48  $I->switchToContentFrame();
49 
50  $I->click('.module-docheader .btn[title="Create new record"]');
51  $I->wait(0.2);
52  $I->canSee('New record');
53 
54  $I->scrollTo(Locator::find('span', ['data-table' => 'sys_note']));
55  $I->click('Internal note');
56 
57  $I->fillField('//input[contains(@data-formengine-input-name, "data[sys_note]") and contains(@data-formengine-input-name, "[subject]")]', 'new sys_note');
58  $I->click('button[name="_savedok"]');
59  $I->wait(0.2);
60  $I->waitForElementNotVisible('#t3js-ui-block');
61  $I->click('a[title="Close"]');
62  $I->wait(1);
63  $I->canSee('styleguide TCA demo', 'h1');
64  $I->click('a.t3js-toggle-recordlist[data-table="pages"]');
65  $I->canSee('Internal notes', 'h2');
66  $I->canSee('new sys_note');
67  $I->click('div.typo3-dblist-sysnotes > div > div.panel-heading.clearfix > div > a:nth-child(1)');
68  $I->wait(0.2);
69  $I->canSee('Edit Internal note "new sys_note"');
70  }
71 }
‪TYPO3\CMS\Core\Tests\Acceptance\Backend\RecordList\SysNoteCest
Definition: SysNoteCest.php:26
‪TYPO3\CMS\Core\Tests\Acceptance\Backend\RecordList\SysNoteCest\_before
‪_before(BackendTester $I)
Definition: SysNoteCest.php:30
‪TYPO3\CMS\Core\Tests\Acceptance\Support\BackendTester
Definition: BackendTester.php:25
‪TYPO3\CMS\Core\Tests\Acceptance\Backend\RecordList
Definition: SysNoteCest.php:3
‪TYPO3\CMS\Core\Tests\Acceptance\Support\Helper\PageTree
Definition: PageTree.php:25
‪TYPO3\CMS\Core\Tests\Acceptance\Backend\RecordList\SysNoteCest\notesEntryCanBeEdited
‪notesEntryCanBeEdited(BackendTester $I, PageTree $pageTree)
Definition: SysNoteCest.php:39