PHP Class Scalr\Tests\Service\CloudStack\CloudStackTestCase

Since: 4.5.2
Author: Vlad Dobrovolskiy ([email protected])
Inheritance: extends Scalr\Tests\TestCase
Afficher le fichier Open project: scalr/scalr Class Usage Examples

Protected Properties

Свойство Type Description
$cloudstack Scalr\Service\CloudStack\CloudStack CloudStack instance

Méthodes publiques

Méthode Description
getCloudStackClassName ( string $classSuffix ) : string Gets full class name by its suffix after CloudStack\\
getCloudStackFixtureClassName ( string $classSuffix ) : string Gets full FIXTURE class name by its suffix after CloudStack\\
getCloudStackMock ( string $serviceName = null, Closure | callback | string $callback = null ) : CloudStack Gets an CloudStack mock
getContainer ( ) : Container Gets DI Container
getEnvironment ( ) : Environment Gets Scalr Environment
getFixtureFileContent ( string $filename ) : string Gets fixture file content
getFixtureFilePath ( string $filename ) : string Returns fixtures file path
getFixturesDirectory ( )
getQueryClientResponseMock ( string $body, $command, integer $responseCode = null ) : QueryClientResponse Gets QueryClientResponse Mock.
getServiceInterfaceMock ( string $serviceName, CloudStack $csStub ) : ServiceInterface Gets an service interface mock object

Méthodes protégées

Méthode Description
setUp ( )
tearDown ( )

Method Details

getCloudStackClassName() public méthode

Gets full class name by its suffix after CloudStack\\
public getCloudStackClassName ( string $classSuffix ) : string
$classSuffix string
Résultat string

getCloudStackFixtureClassName() public méthode

Gets full FIXTURE class name by its suffix after CloudStack\\
public getCloudStackFixtureClassName ( string $classSuffix ) : string
$classSuffix string
Résultat string

getCloudStackMock() public méthode

Gets an CloudStack mock
public getCloudStackMock ( string $serviceName = null, Closure | callback | string $callback = null ) : CloudStack
$serviceName string Service name (Network, Volume etc..)
$callback Closure | callback | string optional callback for QueryClientResponse mock
Résultat Scalr\Service\CloudStack\CloudStack Returns CloudStack Mock stub

getContainer() public méthode

Gets DI Container
public getContainer ( ) : Container
Résultat Scalr\DependencyInjection\Container

getEnvironment() public méthode

Gets Scalr Environment
public getEnvironment ( ) : Environment
Résultat Environment

getFixtureFileContent() public méthode

Gets fixture file content
public getFixtureFileContent ( string $filename ) : string
$filename string A fixture file name
Résultat string Returns fixture file content

getFixtureFilePath() public méthode

Returns fixtures file path
public getFixtureFilePath ( string $filename ) : string
$filename string A fixture file name
Résultat string Returns fixtures file path

getFixturesDirectory() public méthode

getQueryClientResponseMock() public méthode

Gets QueryClientResponse Mock.
public getQueryClientResponseMock ( string $body, $command, integer $responseCode = null ) : QueryClientResponse
$body string
$responseCode integer optional The code of the http response
Résultat QueryClientResponse Returns response mock object

getServiceInterfaceMock() public méthode

Gets an service interface mock object
public getServiceInterfaceMock ( string $serviceName, CloudStack $csStub ) : ServiceInterface
$serviceName string Service name (Network, Volume etc..)
$csStub Scalr\Service\CloudStack\CloudStack CloudStack Mock stub
Résultat ServiceInterface Returns service interface mock

setUp() protected méthode

See also: PHPUnit_Framework_TestCase::setUp()
protected setUp ( )

tearDown() protected méthode

See also: PHPUnit_Framework_TestCase::tearDown()
protected tearDown ( )

Property Details

$cloudstack protected_oe property

CloudStack instance
protected CloudStack,Scalr\Service\CloudStack $cloudstack
Résultat Scalr\Service\CloudStack\CloudStack