public function testGetThrowsExceptionOnServiceConfiguration() {
$c = new ProjectServiceContainer();
try {
$c
->get('throws_exception_on_service_configuration');
$this
->fail('The container can not contain invalid service!');
} catch (\Exception $e) {
$this
->assertEquals('Something was terribly wrong while trying to configure the service!', $e
->getMessage());
}
$this
->assertFalse($c
->initialized('throws_exception_on_service_configuration'));
try {
$c
->get('throws_exception_on_service_configuration');
$this
->fail('The container can not contain invalid service!');
} catch (\Exception $e) {
$this
->assertEquals('Something was terribly wrong while trying to configure the service!', $e
->getMessage());
}
$this
->assertFalse($c
->initialized('throws_exception_on_service_configuration'));
}