TYPO3CMS  8
 All Classes Namespaces Files Functions Variables Pages
FileWriterTest Class Reference
Inheritance diagram for FileWriterTest:
UnitTestCase BaseTestCase

Public Member Functions

 setLogFileSetsLogFile ()
 
 setLogFileAcceptsAbsolutePath ()
 
 createsLogFileDirectory ()
 
 createsLogFile ()
 
 logsToFileDataProvider ()
 
 logsToFile (\TYPO3\CMS\Core\Log\LogRecord $record, $expectedResult)
 
 differentWritersLogToDifferentFiles (\TYPO3\CMS\Core\Log\LogRecord $record, $expectedResult)
 
 aSecondLogWriterToTheSameFileDoesNotOpenTheFileTwice ()
 

Protected Member Functions

 setUpVfsStream ()
 
 getDefaultFileName ($prependName= '')
 
- Protected Member Functions inherited from UnitTestCase
 tearDown ()
 
- Protected Member Functions inherited from 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,...$arguments)
 
 inject ($target, $name, $dependency)
 
 getUniqueId ($prefix= '')
 

Protected Attributes

 $logFileDirectory = 'Log'
 
 $logFileName = 'test.log'
 
- Protected Attributes inherited from UnitTestCase
 $backupGlobalsBlacklist = ['TYPO3_LOADED_EXT']
 
 $testFilesToDelete = []
 
- Protected Attributes inherited from BaseTestCase
 $backupGlobals = true
 
 $backupStaticAttributes = false
 

Detailed Description

Test case

Definition at line 23 of file FileWriterTest.php.

Member Function Documentation

aSecondLogWriterToTheSameFileDoesNotOpenTheFileTwice ( )
createsLogFile ( )
Test:

Definition at line 117 of file FileWriterTest.php.

References FileWriterTest\setUpVfsStream().

createsLogFileDirectory ( )
Test:

Definition at line 107 of file FileWriterTest.php.

References FileWriterTest\setUpVfsStream().

differentWritersLogToDifferentFiles ( \TYPO3\CMS\Core\Log\LogRecord  $record,
  $expectedResult 
)
Test:
Parameters
\TYPO3\CMS\Core\Log\LogRecord$recordRecord Test Data
string$expectedResultNeedle logsToFileDataProvider

Definition at line 157 of file FileWriterTest.php.

References FileWriterTest\getDefaultFileName(), and FileWriterTest\setUpVfsStream().

logsToFile ( \TYPO3\CMS\Core\Log\LogRecord  $record,
  $expectedResult 
)
Test:
Parameters
\TYPO3\CMS\Core\Log\LogRecord$recordRecord Test Data
string$expectedResultNeedle logsToFileDataProvider

Definition at line 143 of file FileWriterTest.php.

References FileWriterTest\getDefaultFileName(), and FileWriterTest\setUpVfsStream().

logsToFileDataProvider ( )
setLogFileAcceptsAbsolutePath ( )
Test:

Definition at line 96 of file FileWriterTest.php.

References GeneralUtility\makeInstance().

Member Data Documentation

$logFileDirectory = 'Log'
protected

Definition at line 28 of file FileWriterTest.php.

$logFileName = 'test.log'
protected

Definition at line 33 of file FileWriterTest.php.

Referenced by FileWriterTest\getDefaultFileName().