public function LingotekTestServiceProvider::alter in Lingotek Translation 8
Same name and namespace in other branches
- 8.2 tests/modules/lingotek_test/src/LingotekTestServiceProvider.php \Drupal\lingotek_test\LingotekTestServiceProvider::alter()
- 4.0.x tests/modules/lingotek_test/src/LingotekTestServiceProvider.php \Drupal\lingotek_test\LingotekTestServiceProvider::alter()
- 3.0.x tests/modules/lingotek_test/src/LingotekTestServiceProvider.php \Drupal\lingotek_test\LingotekTestServiceProvider::alter()
- 3.1.x tests/modules/lingotek_test/src/LingotekTestServiceProvider.php \Drupal\lingotek_test\LingotekTestServiceProvider::alter()
- 3.2.x tests/modules/lingotek_test/src/LingotekTestServiceProvider.php \Drupal\lingotek_test\LingotekTestServiceProvider::alter()
- 3.3.x tests/modules/lingotek_test/src/LingotekTestServiceProvider.php \Drupal\lingotek_test\LingotekTestServiceProvider::alter()
- 3.4.x tests/modules/lingotek_test/src/LingotekTestServiceProvider.php \Drupal\lingotek_test\LingotekTestServiceProvider::alter()
- 3.5.x tests/modules/lingotek_test/src/LingotekTestServiceProvider.php \Drupal\lingotek_test\LingotekTestServiceProvider::alter()
- 3.6.x tests/modules/lingotek_test/src/LingotekTestServiceProvider.php \Drupal\lingotek_test\LingotekTestServiceProvider::alter()
- 3.7.x tests/modules/lingotek_test/src/LingotekTestServiceProvider.php \Drupal\lingotek_test\LingotekTestServiceProvider::alter()
- 3.8.x tests/modules/lingotek_test/src/LingotekTestServiceProvider.php \Drupal\lingotek_test\LingotekTestServiceProvider::alter()
Modifies existing service definitions.
Parameters
ContainerBuilder $container: The ContainerBuilder whose service definitions can be altered.
Overrides ServiceProviderBase::alter
File
- tests/
modules/ lingotek_test/ src/ LingotekTestServiceProvider.php, line 20 - Contains Drupal\lingotek_test\LingotekServiceProvider
Class
- LingotekTestServiceProvider
- Modifies the lingotek service.
Namespace
Drupal\lingotek_testCode
public function alter(ContainerBuilder $container) {
// Overrides lingotek class to mock communication with the server.
$definition = $container
->getDefinition('lingotek');
$definition
->setClass('Drupal\\lingotek_test\\LingotekFake');
}