‪TYPO3CMS  10.4
ElementsBasicInputRangeCest.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 
20 use Codeception\Example;
23 
28 {
35  public function ‪_before(‪BackendTester $I, ‪PageTree $pageTree)
36  {
37  $I->useExistingSession('admin');
38  $I->click('List');
39  $pageTree->openPath(['styleguide TCA demo', 'elements basic']);
40  $I->switchToContentFrame();
41 
42  // Open record and wait until form is ready
43  $I->waitForText('elements basic', 20);
44  $editRecordLinkCssPath = '#recordlist-tx_styleguide_elements_basic a[data-original-title="Edit record"]';
45  $I->click($editRecordLinkCssPath);
46  $I->waitForElementNotVisible('#t3js-ui-block');
47  $I->waitForText('Edit Form', 3, 'h1');
48  }
49 
54  {
55  return [
67  [
68  'label' => 'input_25 eval=int default=0 range lower=-2 range upper=2',
69  'inputValue' => '2',
70  'expectedValue' => '2',
71  'expectedInternalValue' => '2',
72  'expectedValueAfterSave' => '2',
73  'comment' => '',
74  ],
75  [
76  'label' => 'input_25 eval=int default=0 range lower=-2 range upper=2',
77  'inputValue' => '-1',
78  'expectedValue' => '-1',
79  'expectedInternalValue' => '-1',
80  'expectedValueAfterSave' => '-1',
81  'comment' => '',
82  ],
83  [
84  'label' => 'input_12 eval=md5',
85  'inputValue' => 'Kasper TYPO3!',
86  'expectedValue' => '748469dd64911af8df8f9a3dcb2c9378',
87  'expectedInternalValue' => '748469dd64911af8df8f9a3dcb2c9378',
88  'expectedValueAfterSave' => '748469dd64911af8df8f9a3dcb2c9378',
89  'comment' => '',
90  ],
91  [
92  'label' => 'input_12 eval=md5',
93  'inputValue' => ' Kasper TYPO3! ',
94  'expectedValue' => '792a085606250c47d6ebb8c98804d5b0',
95  'expectedInternalValue' => '792a085606250c47d6ebb8c98804d5b0',
96  'expectedValueAfterSave' => '792a085606250c47d6ebb8c98804d5b0',
97  'comment' => 'Check whitespaces are not trimmed.',
98  ],
99  ];
100  }
101 
107  public function ‪simpleRangeAndMd5Fields(‪BackendTester $I, Example $testData)
108  {
109  $this->‪runInputFieldTest($I, $testData);
110  }
111 }
‪TYPO3\CMS\Core\Tests\Acceptance\Backend\FormEngine\ElementsBasicInputRangeCest\simpleRangeAndMd5FieldsDataProvider
‪simpleRangeAndMd5FieldsDataProvider()
Definition: ElementsBasicInputRangeCest.php:53
‪TYPO3\CMS\Core\Tests\Acceptance\Backend\FormEngine\ElementsBasicInputRangeCest
Definition: ElementsBasicInputRangeCest.php:28
‪TYPO3\CMS\Core\Tests\Acceptance\Backend\FormEngine\AbstractElementsBasicCest\runInputFieldTest
‪runInputFieldTest(BackendTester $I, Example $testData)
Definition: AbstractElementsBasicCest.php:39
‪TYPO3\CMS\Core\Tests\Acceptance\Support\BackendTester
Definition: BackendTester.php:27
‪TYPO3\CMS\Core\Tests\Acceptance\Backend\FormEngine\ElementsBasicInputRangeCest\_before
‪_before(BackendTester $I, PageTree $pageTree)
Definition: ElementsBasicInputRangeCest.php:35
‪TYPO3\CMS\Core\Tests\Acceptance\Backend\FormEngine\ElementsBasicInputRangeCest\simpleRangeAndMd5Fields
‪simpleRangeAndMd5Fields(BackendTester $I, Example $testData)
Definition: ElementsBasicInputRangeCest.php:107
‪TYPO3\CMS\Core\Tests\Acceptance\Backend\FormEngine\AbstractElementsBasicCest
Definition: AbstractElementsBasicCest.php:31
‪TYPO3\CMS\Core\Tests\Acceptance\Support\Helper\PageTree
Definition: PageTree.php:28
‪TYPO3\CMS\Core\Tests\Acceptance\Backend\FormEngine
Definition: AbstractElementsBasicCest.php:18