1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-30 21:40:43 +02:00

[ticket/11386] Update tests with new constructors for ext.manager/migrator

PHPBB3-11386
This commit is contained in:
Nathaniel Guse
2013-03-02 11:37:58 -06:00
parent 39ca212e17
commit 8415ae839c
4 changed files with 50 additions and 6 deletions

View File

@@ -97,15 +97,28 @@ class phpbb_extension_manager_test extends phpbb_database_test_case
$php_ext = 'php';
$table_prefix = 'phpbb_';
return new phpbb_extension_manager(
$manager = new phpbb_extension_manager(
new phpbb_mock_container_builder(),
$db,
$config,
new phpbb_db_migrator($config, $db, $db_tools, 'phpbb_migrations', $phpbb_root_path, $php_ext, $table_prefix, array()),
'phpbb_ext',
dirname(__FILE__) . '/',
'.' . $php_ext,
($with_cache) ? new phpbb_mock_cache() : null
);
$migrator = new phpbb_db_migrator(
$config,
$db,
$db_tools,
$manager,
'phpbb_migrations',
$phpbb_root_path,
$php_ext,
$table_prefix,
array()
);
$manager->set_migrator($migrator);
return $manager;
}
}

View File

@@ -53,7 +53,6 @@ class metadata_manager_test extends phpbb_database_test_case
new phpbb_mock_container_builder(),
$this->db,
$this->config,
new phpbb_db_migrator($this->config, $this->db, $this->db_tools, 'phpbb_migrations', $this->phpbb_root_path, $this->php_ext, $this->table_prefix, array()),
'phpbb_ext',
$this->phpbb_root_path,
$this->phpEx,