mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-10 10:44:20 +02:00
[ticket/14948] Adjust calls for twig and phpunit updates
PHPBB3-14948
This commit is contained in:
@@ -26,7 +26,7 @@ namespace
|
||||
protected $phpbb_root_path;
|
||||
protected $filename;
|
||||
|
||||
public function setUp()
|
||||
public function setUp(): void
|
||||
{
|
||||
$this->phpbb_root_path = dirname(__FILE__) . '/';
|
||||
$this->config_php = new \phpbb\config_php_file($this->phpbb_root_path . 'fixtures/', 'php');
|
||||
|
@@ -18,7 +18,7 @@ class phpbb_ordered_service_collection_test extends \phpbb_test_case
|
||||
*/
|
||||
protected $service_collection;
|
||||
|
||||
public function setUp()
|
||||
public function setUp(): void
|
||||
{
|
||||
$container = new phpbb_mock_container_builder();
|
||||
$container->set('foo', new StdClass);
|
||||
|
@@ -18,7 +18,7 @@ class phpbb_service_collection_test extends \phpbb_test_case
|
||||
*/
|
||||
protected $service_collection;
|
||||
|
||||
public function setUp()
|
||||
public function setUp(): void
|
||||
{
|
||||
$container = new phpbb_mock_container_builder();
|
||||
$container->set('foo', new StdClass);
|
||||
@@ -56,14 +56,16 @@ class phpbb_service_collection_test extends \phpbb_test_case
|
||||
|
||||
public function test_get_by_class_many_services_exception()
|
||||
{
|
||||
$this->setExpectedException('RuntimeException', 'More than one service definitions found for class "bar_class" in collection.');
|
||||
$this->expectException('RuntimeException');
|
||||
$this->expectExceptionMessage('More than one service definitions found for class "bar_class" in collection.');
|
||||
|
||||
$this->service_collection->get_by_class('bar_class');
|
||||
}
|
||||
|
||||
public function test_get_by_class_no_service_exception()
|
||||
{
|
||||
$this->setExpectedException('RuntimeException', 'No service found for class "baz_class" in collection.');
|
||||
$this->expectException('RuntimeException');
|
||||
$this->expectExceptionMessage('No service found for class "baz_class" in collection.');
|
||||
|
||||
$this->service_collection->get_by_class('baz_class');
|
||||
}
|
||||
|
Reference in New Issue
Block a user