PHP Class Kraken\_Unit\Filesystem\FilesystemTest

Inheritance: extends Kraken\Test\TUnit
Afficher le fichier Open project: kraken-php/framework

Méthodes publiques

Méthode Description
createFilesystem ( $internal ) : Kraken\Filesystem\FilesystemInterface
expect ( $method, $args = [], $times = 1 ) : Prophecy\Prophecy\MethodProphecy
prevent ( $method, $args = [] ) : Prophecy\Prophecy\MethodProphecy
setUp ( )
testApiAppend_CallsUpdateOnModel_WithExistingContents ( )
testApiAppend_ThrowsException_WhenReadThrowsException ( )
testApiAppend_ThrowsException_WhenUpdateThrowsException ( )
testApiCopyFile_CallsCopyOnModel ( )
testApiCopyFile_ThrowsException_WhenModelThrowsException ( )
testApiCreateFile_CallsWriteOnModel_WithConfig ( )
testApiCreateFile_ThrowsException_WhenLegueWriteThrowsException ( )
testApiCreate_CallsWriteOnModel_WithConfig ( )
testApiCreate_ThrowsException_WhenLegueWriteThrowsException ( )
testApiEraseFile_CallsUpdateOnModel ( )
testApiEraseFile_ThrowsException_WhenUpdateOnModelThrowsException ( )
testApiExists_ReturnsFalse_WhenModelHasReturnsFalse ( )
testApiExists_ReturnsTrue_WhenModelHasReturnsTrue ( )
testApiExists_ThrowsException_WhenModelHasThrowsException ( )
testApiGetMimetype_ReturnsMimetype_UsingGetMetadataOnModel ( )
testApiGetMimetype_ThrowsException_WhenGetMetadataOnModelThrowsException ( )
testApiGetSize_CallsGetSizeOnModel ( )
testApiGetSize_ThrowsException_WhenGetSizeOnModelThrowsException ( )
testApiGetTimestamp_ReturnsMimetype_UsingGetMetadataOnModel ( )
testApiGetTimestamp_ThrowsException_WhenGetMetadataOnModelThrowsException ( )
testApiGetType_ReturnsType_UsingGetMetadataOnModel ( )
testApiGetType_ThrowsException_WhenGetMetadataOnModelThrowsException ( )
testApiGetVisibility_ReturnsSameValue_AsModelGetVisibility ( )
testApiGetVisibility_ThrowsException_WhenModelThrowsException ( )
testApiIsDir_ReturnsFalse_WhenModelDoesNotReturnMetadataForDir ( )
testApiIsDir_ReturnsTrue_WhenModelReturnsMetadataForDir ( )
testApiIsDir_ThrowsException_WhenModelThrowsException ( )
testApiIsFile_ReturnsFalse_WhenModelDoesNotReturnMetadataForFile ( )
testApiIsFile_ReturnsTrue_WhenModelReturnsMetadataForFile ( )
testApiIsFile_ThrowsException_WhenModelThrowsException ( )
testApiIsPrivate_RethrowsException ( )
testApiIsPrivate_ReturnsFalse_WhenVisibilityIsNotPrivate ( )
testApiIsPrivate_ReturnsTrue_WhenVisibilityIsPrivate ( )
testApiIsPublic_RethrowsException ( )
testApiIsPublic_ReturnsFalse_WhenVisibilityIsNotPublic ( )
testApiIsPublic_ReturnsTrue_WhenVisibilityIsPublic ( )
testApiMove_ReturnsNull_WhenModelMoveReturnsTrue ( )
testApiMove_ThrowsException_WhenModelMoveReturnsFalse ( )
testApiMove_ThrowsException_WhenModelMoveThrowsException ( )
testApiPrepend_CallsUpdateOnModel_WithExistingContents ( )
testApiPrepend_ThrowsException_WhenReadThrowsException ( )
testApiPrepend_ThrowsException_WhenUpdateThrowsException ( )
testApiRead_ReturnsReadString_WhenReadWasSuccessful ( )
testApiRead_ThrowsException_WhenModelReadThrowsException ( )
testApiRead_ThrowsException_WhenReadWasNotSuccessful ( )
testApiRemoveFile_CallsDeleteOnModel ( )
testApiRemoveFile_ThrowsException_WhenDeleteOnModelThrowsException ( )
testApiReq_ThrowsException_WhenModelReadThrowsException ( )
testApiReq_UsesEvalToIncludePhpFilesFromExternalSources ( )
testApiSetPrivate_SetsPrivate_WhenSettingIsPossible ( )
testApiSetPrivate_ThrowsException_WhenModelThrows ( )
testApiSetPrivate_ThrowsException_WhenSettingIsNotPossible ( )
testApiSetPublic_SetsPublic_WhenSettingIsPossible ( )
testApiSetPublic_ThrowsException_WhenModelThrows ( )
testApiSetPublic_ThrowsException_WhenSettingIsNotPossible ( )
testApiSetVisibility_SetsVisibility_WhenSettingIsPossible ( )
testApiSetVisibility_ThrowsException_WhenModelThrows ( )
testApiSetVisibility_ThrowsException_WhenSettingIsNotPossible ( )
testApiWrite_CallsPutOnModel_WithConfig ( )
testApiWrite_ThrowsException_WhenModelPutThrowsException ( )

Private Methods

Méthode Description
prepareConfig ( $visibility ) : string[]

Method Details

createFilesystem() public méthode

public createFilesystem ( $internal ) : Kraken\Filesystem\FilesystemInterface
Résultat Kraken\Filesystem\FilesystemInterface

expect() public méthode

public expect ( $method, $args = [], $times = 1 ) : Prophecy\Prophecy\MethodProphecy
Résultat Prophecy\Prophecy\MethodProphecy

prevent() public méthode

public prevent ( $method, $args = [] ) : Prophecy\Prophecy\MethodProphecy
Résultat Prophecy\Prophecy\MethodProphecy

setUp() public méthode

public setUp ( )

testApiAppend_CallsUpdateOnModel_WithExistingContents() public méthode

testApiAppend_ThrowsException_WhenReadThrowsException() public méthode

testApiAppend_ThrowsException_WhenUpdateThrowsException() public méthode

testApiCopyFile_CallsCopyOnModel() public méthode

testApiCopyFile_ThrowsException_WhenModelThrowsException() public méthode

testApiCreateFile_CallsWriteOnModel_WithConfig() public méthode

testApiCreateFile_ThrowsException_WhenLegueWriteThrowsException() public méthode

testApiCreate_CallsWriteOnModel_WithConfig() public méthode

testApiCreate_ThrowsException_WhenLegueWriteThrowsException() public méthode

testApiEraseFile_CallsUpdateOnModel() public méthode

testApiEraseFile_ThrowsException_WhenUpdateOnModelThrowsException() public méthode

testApiExists_ReturnsFalse_WhenModelHasReturnsFalse() public méthode

testApiExists_ReturnsTrue_WhenModelHasReturnsTrue() public méthode

testApiExists_ThrowsException_WhenModelHasThrowsException() public méthode

testApiGetMimetype_ReturnsMimetype_UsingGetMetadataOnModel() public méthode

testApiGetMimetype_ThrowsException_WhenGetMetadataOnModelThrowsException() public méthode

testApiGetSize_CallsGetSizeOnModel() public méthode

testApiGetSize_ThrowsException_WhenGetSizeOnModelThrowsException() public méthode

testApiGetTimestamp_ReturnsMimetype_UsingGetMetadataOnModel() public méthode

testApiGetTimestamp_ThrowsException_WhenGetMetadataOnModelThrowsException() public méthode

testApiGetType_ReturnsType_UsingGetMetadataOnModel() public méthode

testApiGetType_ThrowsException_WhenGetMetadataOnModelThrowsException() public méthode

testApiGetVisibility_ReturnsSameValue_AsModelGetVisibility() public méthode

testApiGetVisibility_ThrowsException_WhenModelThrowsException() public méthode

testApiIsDir_ReturnsFalse_WhenModelDoesNotReturnMetadataForDir() public méthode

testApiIsDir_ReturnsTrue_WhenModelReturnsMetadataForDir() public méthode

testApiIsDir_ThrowsException_WhenModelThrowsException() public méthode

testApiIsFile_ReturnsFalse_WhenModelDoesNotReturnMetadataForFile() public méthode

testApiIsFile_ReturnsTrue_WhenModelReturnsMetadataForFile() public méthode

testApiIsFile_ThrowsException_WhenModelThrowsException() public méthode

testApiIsPrivate_RethrowsException() public méthode

testApiIsPrivate_ReturnsFalse_WhenVisibilityIsNotPrivate() public méthode

testApiIsPrivate_ReturnsTrue_WhenVisibilityIsPrivate() public méthode

testApiIsPublic_RethrowsException() public méthode

testApiIsPublic_ReturnsFalse_WhenVisibilityIsNotPublic() public méthode

testApiIsPublic_ReturnsTrue_WhenVisibilityIsPublic() public méthode

testApiMove_ReturnsNull_WhenModelMoveReturnsTrue() public méthode

testApiMove_ThrowsException_WhenModelMoveReturnsFalse() public méthode

testApiMove_ThrowsException_WhenModelMoveThrowsException() public méthode

testApiPrepend_CallsUpdateOnModel_WithExistingContents() public méthode

testApiPrepend_ThrowsException_WhenReadThrowsException() public méthode

testApiPrepend_ThrowsException_WhenUpdateThrowsException() public méthode

testApiRead_ReturnsReadString_WhenReadWasSuccessful() public méthode

testApiRead_ThrowsException_WhenModelReadThrowsException() public méthode

testApiRead_ThrowsException_WhenReadWasNotSuccessful() public méthode

testApiRemoveFile_CallsDeleteOnModel() public méthode

testApiRemoveFile_ThrowsException_WhenDeleteOnModelThrowsException() public méthode

testApiReq_ThrowsException_WhenModelReadThrowsException() public méthode

testApiReq_UsesEvalToIncludePhpFilesFromExternalSources() public méthode

testApiSetPrivate_SetsPrivate_WhenSettingIsPossible() public méthode

testApiSetPrivate_ThrowsException_WhenModelThrows() public méthode

testApiSetPrivate_ThrowsException_WhenSettingIsNotPossible() public méthode

testApiSetPublic_SetsPublic_WhenSettingIsPossible() public méthode

testApiSetPublic_ThrowsException_WhenModelThrows() public méthode

testApiSetPublic_ThrowsException_WhenSettingIsNotPossible() public méthode

testApiSetVisibility_SetsVisibility_WhenSettingIsPossible() public méthode

testApiSetVisibility_ThrowsException_WhenModelThrows() public méthode

testApiSetVisibility_ThrowsException_WhenSettingIsNotPossible() public méthode

testApiWrite_CallsPutOnModel_WithConfig() public méthode

testApiWrite_ThrowsException_WhenModelPutThrowsException() public méthode