1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-08-11 03:04:09 +02:00

[ticket/15540] Properties

PHPBB3-15540
This commit is contained in:
rubencm
2021-03-23 04:16:34 +01:00
parent 5c67eabeed
commit 656e57fbf6
9 changed files with 173 additions and 145 deletions

View File

@@ -29,8 +29,8 @@ class phpbb_search_mysql_test extends phpbb_search_common_test_case
parent::setUp();
// dbal uses cache
$cache = new phpbb_mock_cache();
$cache = $this->createMock('\phpbb\cache\service');
$language = new \phpbb\language\language(new \phpbb\language\language_file_loader($phpbb_root_path, $phpEx));
$user = $this->createMock('\phpbb\user');
// set config values
@@ -40,6 +40,6 @@ class phpbb_search_mysql_test extends phpbb_search_common_test_case
$this->db = $this->new_dbal();
$phpbb_dispatcher = new phpbb_mock_event_dispatcher();
$class = self::get_search_wrapper('\phpbb\search\backend\fulltext_mysql');
$this->search = new $class($config, $this->db, $phpbb_dispatcher, $user, $phpbb_root_path, $phpEx);
$this->search = new $class($cache, $config, $this->db, $phpbb_dispatcher, $language, $user, $phpbb_root_path, $phpEx);
}
}

View File

@@ -29,8 +29,8 @@ class phpbb_search_native_test extends phpbb_search_test_case
parent::setUp();
// dbal uses cache
$cache = new phpbb_mock_cache();
$cache = $this->createMock('\phpbb\cache\service');
$language = new \phpbb\language\language(new \phpbb\language\language_file_loader($phpbb_root_path, $phpEx));
$user = $this->createMock('\phpbb\user');
$this->db = $this->new_dbal();
@@ -38,7 +38,7 @@ class phpbb_search_native_test extends phpbb_search_test_case
$class = self::get_search_wrapper('\phpbb\search\backend\fulltext_native');
$config['fulltext_native_min_chars'] = 2;
$config['fulltext_native_max_chars'] = 14;
$this->search = new $class($config, $this->db, $phpbb_dispatcher, $user, $phpbb_root_path, $phpEx);
$this->search = new $class($cache, $config, $this->db, $phpbb_dispatcher, $language, $user, $phpbb_root_path, $phpEx);
}
public function keywords()

View File

@@ -29,8 +29,8 @@ class phpbb_search_postgres_test extends phpbb_search_common_test_case
parent::setUp();
// dbal uses cache
$cache = new phpbb_mock_cache();
$cache = $this->createMock('\phpbb\cache\service');
$language = new \phpbb\language\language(new \phpbb\language\language_file_loader($phpbb_root_path, $phpEx));
$user = $this->createMock('\phpbb\user');
// set config values
@@ -40,6 +40,6 @@ class phpbb_search_postgres_test extends phpbb_search_common_test_case
$this->db = $this->new_dbal();
$phpbb_dispatcher = new phpbb_mock_event_dispatcher();
$class = self::get_search_wrapper('\phpbb\search\backend\fulltext_postgres');
$this->search = new $class($config, $this->db, $phpbb_dispatcher, $user, $phpbb_root_path, $phpEx);
$this->search = new $class($cache, $config, $this->db, $phpbb_dispatcher, $language, $user, $phpbb_root_path, $phpEx);
}
}