TYPO3 CMS  TYPO3_7-6
TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest Class Reference
Inheritance diagram for TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest:
TYPO3\CMS\Core\Tests\UnitTestCase TYPO3\CMS\Core\Tests\BaseTestCase

Public Member Functions

 calcAgeDataProvider ()
 
 calcAgeReturnsExpectedValues ($seconds, $expectedLabel)
 
 getProcessedValueForZeroStringIsZero ()
 
 getProcessedValueForGroup ()
 
 getProcessedValueForGroupWithOneAllowedTable ()
 
 getProcessedValueForGroupWithMultipleAllowedTables ()
 
 getProcessedValueForSelectWithMMRelation ()
 
 inputTypeDateDisplayOptions ()
 
 getCommonSelectFieldsReturnsCorrectFieldsDataProvider ()
 
 getCommonSelectFieldsReturnsCorrectFields ($table, $prefix='', array $presetFields, array $tca, $expectedFields='')
 
 getLabelFromItemlistReturnsCorrectFieldsDataProvider ()
 
 getLabelFromItemlistReturnsCorrectFields ($table, $col='', $key='', array $tca, $expectedLabel='')
 
 getLabelFromItemListMergedReturnsCorrectFieldsDataProvider ()
 
 getLabelFromItemListMergedReturnsCorrectFields ($pageId, $table, $column='', $key='', array $tca, $expectedLabel='')
 
 getFuncCheckReturnsInputTagWithValueAttribute ()
 
 getLabelsFromItemsListDataProvider ()
 
 getLabelsFromItemsListReturnsCorrectValue ($table, $col, $keyList, $tca, array $pageTsConfig, $expectedLabel)
 
 getProcessedValueReturnsLabelsForExistingValuesSolely ()
 
 getProcessedValueReturnsPlainValueIfItemIsNotFound ()
 
 viewOnClickReturnsOnClickCodeWithAlternativeUrl ()
 
 getModTSconfigIgnoresValuesFromUserTsConfigIfNoSet ()
 
 replaceL10nModeFieldsReplacesFieldsDataProvider ()
 
 getSpecConfPartsSplitsDefaultExtras ()
 
 getTCAtypesReturnsCorrectValuesDataProvider ()
 
 getTCAtypesReturnsCorrectValues ($table, $rec, $useFieldNameAsKey, $expected)
 

Additional Inherited Members

- Protected Member Functions inherited from TYPO3\CMS\Core\Tests\UnitTestCase
 tearDown ()
 
- Protected Member Functions inherited from TYPO3\CMS\Core\Tests\BaseTestCase
 getAccessibleMock ( $originalClassName, $methods=[], array $arguments=[], $mockClassName='', $callOriginalConstructor=true, $callOriginalClone=true, $callAutoload=true)
 
 getAccessibleMockForAbstractClass ( $originalClassName, array $arguments=[], $mockClassName='', $callOriginalConstructor=true, $callOriginalClone=true, $callAutoload=true, $mockedMethods=[])
 
 buildAccessibleProxy ($className)
 
 callInaccessibleMethod ($object, $name)
 
 inject ($target, $name, $dependency)
 
 getUniqueId ($prefix='')
 
- Protected Attributes inherited from TYPO3\CMS\Core\Tests\UnitTestCase
 $backupGlobalsBlacklist = ['TYPO3_LOADED_EXT']
 
 $testFilesToDelete = []
 
- Protected Attributes inherited from TYPO3\CMS\Core\Tests\BaseTestCase
 $backupGlobals = true
 
 $backupStaticAttributes = false
 

Detailed Description

Test case

Definition at line 35 of file BackendUtilityTest.php.

Member Function Documentation

◆ calcAgeDataProvider()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::calcAgeDataProvider ( )

Data provider for calcAge function

Returns
array

Definition at line 45 of file BackendUtilityTest.php.

◆ calcAgeReturnsExpectedValues()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::calcAgeReturnsExpectedValues (   $seconds,
  $expectedLabel 
)
Test:
calcAgeDataProvider
Parameters
int$seconds
string$expectedLabel

Definition at line 126 of file BackendUtilityTest.php.

References TYPO3\CMS\Backend\Utility\BackendUtility\calcAge().

◆ getCommonSelectFieldsReturnsCorrectFields()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::getCommonSelectFieldsReturnsCorrectFields (   $table,
  $prefix = '',
array  $presetFields,
array  $tca,
  $expectedFields = '' 
)
Test:
getCommonSelectFieldsReturnsCorrectFieldsDataProvider
Parameters
string$table
string$prefix
array$presetFields
array$tca
string$expectedFields

Definition at line 509 of file BackendUtilityTest.php.

References $GLOBALS, $tca, and TYPO3\CMS\Backend\Utility\BackendUtility\getCommonSelectFields().

◆ getCommonSelectFieldsReturnsCorrectFieldsDataProvider()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::getCommonSelectFieldsReturnsCorrectFieldsDataProvider ( )

Tests concerning getCommonSelectFields Data provider for getCommonSelectFieldsReturnsCorrectFields

Returns
array The test data with $table, $prefix, $presetFields, $tca, $expectedFields

Definition at line 404 of file BackendUtilityTest.php.

◆ getFuncCheckReturnsInputTagWithValueAttribute()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::getFuncCheckReturnsInputTagWithValueAttribute ( )

Tests concerning getFuncCheck

Test:

Definition at line 686 of file BackendUtilityTest.php.

References TYPO3\CMS\Backend\Utility\BackendUtility\getFuncCheck().

◆ getLabelFromItemListMergedReturnsCorrectFields()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::getLabelFromItemListMergedReturnsCorrectFields (   $pageId,
  $table,
  $column = '',
  $key = '',
array  $tca,
  $expectedLabel = '' 
)
Test:
getLabelFromItemListMergedReturnsCorrectFieldsDataProvider
Parameters
int$pageId
string$table
string$column
string$key
array$tca
string$expectedLabel

Definition at line 672 of file BackendUtilityTest.php.

References $GLOBALS, $tca, and TYPO3\CMS\Backend\Utility\BackendUtility\getLabelFromItemListMerged().

◆ getLabelFromItemListMergedReturnsCorrectFieldsDataProvider()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::getLabelFromItemListMergedReturnsCorrectFieldsDataProvider ( )

Tests concerning getLabelFromItemListMerged Data provider for getLabelFromItemListMerged

Returns
array The test data with $pageId, $table, $column, $key, $expectedLabel

Definition at line 615 of file BackendUtilityTest.php.

◆ getLabelFromItemlistReturnsCorrectFields()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::getLabelFromItemlistReturnsCorrectFields (   $table,
  $col = '',
  $key = '',
array  $tca,
  $expectedLabel = '' 
)
Test:
getLabelFromItemlistReturnsCorrectFieldsDataProvider
Parameters
string$table
string$col
string$key
array$tca
string$expectedLabel

Definition at line 599 of file BackendUtilityTest.php.

References $GLOBALS, $tca, and TYPO3\CMS\Backend\Utility\BackendUtility\getLabelFromItemlist().

◆ getLabelFromItemlistReturnsCorrectFieldsDataProvider()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::getLabelFromItemlistReturnsCorrectFieldsDataProvider ( )

Tests concerning getLabelFromItemlist Data provider for getLabelFromItemlistReturnsCorrectFields

Returns
array The test data with $table, $col, $key, $expectedLabel

Definition at line 525 of file BackendUtilityTest.php.

◆ getLabelsFromItemsListDataProvider()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::getLabelsFromItemsListDataProvider ( )
Returns
array

Definition at line 698 of file BackendUtilityTest.php.

◆ getLabelsFromItemsListReturnsCorrectValue()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::getLabelsFromItemsListReturnsCorrectValue (   $table,
  $col,
  $keyList,
  $tca,
array  $pageTsConfig,
  $expectedLabel 
)
Test:
getLabelsFromItemsListDataProvider
Parameters
string$table
string$col
string$keyList
array$tca
array$pageTsConfig
string$expectedLabel

Definition at line 756 of file BackendUtilityTest.php.

References $GLOBALS, $tca, and TYPO3\CMS\Backend\Utility\BackendUtility\getLabelsFromItemsList().

◆ getModTSconfigIgnoresValuesFromUserTsConfigIfNoSet()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::getModTSconfigIgnoresValuesFromUserTsConfigIfNoSet ( )

◆ getProcessedValueForGroup()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::getProcessedValueForGroup ( )
Test:

Definition at line 157 of file BackendUtilityTest.php.

References $GLOBALS.

◆ getProcessedValueForGroupWithMultipleAllowedTables()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::getProcessedValueForGroupWithMultipleAllowedTables ( )
Test:

Definition at line 202 of file BackendUtilityTest.php.

References $GLOBALS.

◆ getProcessedValueForGroupWithOneAllowedTable()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::getProcessedValueForGroupWithOneAllowedTable ( )
Test:

Definition at line 176 of file BackendUtilityTest.php.

References $GLOBALS.

◆ getProcessedValueForSelectWithMMRelation()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::getProcessedValueForSelectWithMMRelation ( )
Test:

Definition at line 225 of file BackendUtilityTest.php.

References $GLOBALS.

◆ getProcessedValueForZeroStringIsZero()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::getProcessedValueForZeroStringIsZero ( )
Test:
See also
http://forge.typo3.org/issues/20994

Definition at line 138 of file BackendUtilityTest.php.

References $GLOBALS.

◆ getProcessedValueReturnsLabelsForExistingValuesSolely()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::getProcessedValueReturnsLabelsForExistingValuesSolely ( )
Test:

Definition at line 770 of file BackendUtilityTest.php.

References $GLOBALS, and $tca.

◆ getProcessedValueReturnsPlainValueIfItemIsNotFound()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::getProcessedValueReturnsPlainValueIfItemIsNotFound ( )
Test:

Definition at line 803 of file BackendUtilityTest.php.

References $GLOBALS, and $tca.

◆ getSpecConfPartsSplitsDefaultExtras()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::getSpecConfPartsSplitsDefaultExtras ( )

◆ getTCAtypesReturnsCorrectValues()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::getTCAtypesReturnsCorrectValues (   $table,
  $rec,
  $useFieldNameAsKey,
  $expected 
)
Test:
getTCAtypesReturnsCorrectValuesDataProvider
Parameters
string$table
array$rec
bool$useFieldNameAsKey
array$expected

Definition at line 1271 of file BackendUtilityTest.php.

References $GLOBALS, and TYPO3\CMS\Backend\Utility\BackendUtility\getTCAtypes().

◆ getTCAtypesReturnsCorrectValuesDataProvider()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::getTCAtypesReturnsCorrectValuesDataProvider ( )
Test:

Definition at line 1086 of file BackendUtilityTest.php.

◆ inputTypeDateDisplayOptions()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::inputTypeDateDisplayOptions ( )
Returns
array

Definition at line 340 of file BackendUtilityTest.php.

References $GLOBALS.

◆ replaceL10nModeFieldsReplacesFieldsDataProvider()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::replaceL10nModeFieldsReplacesFieldsDataProvider ( )

Data provider for replaceL10nModeFieldsReplacesFields

Returns
array

Definition at line 883 of file BackendUtilityTest.php.

References $GLOBALS, $tca, and TYPO3\CMS\Core\Tests\BaseTestCase\getAccessibleMock().

◆ viewOnClickReturnsOnClickCodeWithAlternativeUrl()

TYPO3\CMS\Backend\Tests\Unit\Utility\BackendUtilityTest::viewOnClickReturnsOnClickCodeWithAlternativeUrl ( )