‪TYPO3CMS  10.4
BackendGroupsVisibleFieldsTest.php
Go to the documentation of this file.
1 <?php
2 
3 /*
4  * This file is part of the TYPO3 CMS project.
5  *
6  * It is free software; you can redistribute it and/or modify it under
7  * the terms of the GNU General Public License, either version 2
8  * of the License, or any later version.
9  *
10  * For the full copyright and license information, please read the
11  * LICENSE.txt file that was distributed with this source code.
12  *
13  * The TYPO3 project - inspiring people to share!
14  */
15 
17 
21 use TYPO3\TestingFramework\Core\Functional\FunctionalTestCase;
22 
23 class ‪BackendGroupsVisibleFieldsTest extends FunctionalTestCase
24 {
25  protected static ‪$backendGroupsFields = [
26  'hidden',
27  'title',
28  'description',
29  'subgroup',
30  'groupMods',
31  'tables_select',
32  'tables_modify',
33  'pagetypes_select',
34  'non_exclude_fields',
35  'explicit_allowdeny',
36  'allowed_languages',
37  'db_mountpoints',
38  'file_mountpoints',
39  'file_permissions',
40  'category_perms',
41  'lockToDomain',
42  'TSconfig',
43  ];
44 
49  {
50  $this->setUpBackendUserFromFixture(1);
51  ‪$GLOBALS['LANG'] = GeneralUtility::makeInstance(LanguageService::class);
52 
53  $formEngineTestService = GeneralUtility::makeInstance(FormTestService::class);
54  $formResult = $formEngineTestService->createNewRecordForm('be_groups');
55 
56  foreach (static::$backendGroupsFields as $expectedField) {
57  self::assertNotFalse(
58  $formEngineTestService->formHtmlContainsField($expectedField, $formResult['html']),
59  'The field ' . $expectedField . ' is not in the HTML'
60  );
61  }
62  }
63 }
‪TYPO3\CMS\Core\Tests\Functional\Tca
Definition: BackendGroupsVisibleFieldsTest.php:16
‪TYPO3\CMS\Core\Tests\Functional\Tca\BackendGroupsVisibleFieldsTest\$backendGroupsFields
‪static $backendGroupsFields
Definition: BackendGroupsVisibleFieldsTest.php:25
‪TYPO3\CMS\Core\Tests\Functional\Tca\BackendGroupsVisibleFieldsTest
Definition: BackendGroupsVisibleFieldsTest.php:24
‪TYPO3\CMS\Core\Tests\Functional\Tca\BackendGroupsVisibleFieldsTest\backendGroupsFormContainsExpectedFields
‪backendGroupsFormContainsExpectedFields()
Definition: BackendGroupsVisibleFieldsTest.php:48
‪$GLOBALS
‪$GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['adminpanel']['modules']
Definition: ext_localconf.php:5
‪TYPO3\CMS\Backend\Tests\Functional\Form\FormTestService
Definition: FormTestService.php:27
‪TYPO3\CMS\Core\Localization\LanguageService
Definition: LanguageService.php:42
‪TYPO3\CMS\Core\Utility\GeneralUtility
Definition: GeneralUtility.php:46