trait Bootstrap in AmazonS3 7.2
Same name in this branch
- 7.2 tests/DrupalAdapter/Bootstrap.php \Drupal\amazons3Test\DrupalAdapter\Bootstrap
- 7.2 src/DrupalAdapter/Bootstrap.php \Drupal\amazons3\DrupalAdapter\Bootstrap
Methods that map to includes/bootstrap.inc.
@class Bootstrap @package Drupal\amazons3\DrupalAdapter @codeCoverageIgnore
Hierarchy
- trait \Drupal\amazons3Test\DrupalAdapter\Bootstrap
3 files declare their use of Bootstrap
- CloudFrontClient.php in tests/
Stub/ CloudFrontClient.php - S3Client.php in tests/
Stub/ S3Client.php - StreamWrapperConfiguration.php in tests/
Stub/ StreamWrapperConfiguration.php
File
- tests/
DrupalAdapter/ Bootstrap.php, line 12
Namespace
Drupal\amazons3Test\DrupalAdapterView source
trait Bootstrap {
protected static $variableData = array();
public static function setVariableData(array $data) {
static::$variableData = $data;
}
/**
* Static version of variable_get() for testing.
*
* @param string $name
* @param null $default
* @return string
*/
public static function variable_get($name, $default = NULL) {
if (isset(static::$variableData[$name])) {
return static::$variableData[$name];
}
if (isset($default)) {
return $default;
}
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
Bootstrap:: |
protected static | property | ||
Bootstrap:: |
public static | function | ||
Bootstrap:: |
public static | function | Static version of variable_get() for testing. |