aboutsummaryrefslogtreecommitdiffstats
path: root/tests/functional/search
diff options
context:
space:
mode:
Diffstat (limited to 'tests/functional/search')
-rw-r--r--tests/functional/search/base.php7
1 files changed, 5 insertions, 2 deletions
diff --git a/tests/functional/search/base.php b/tests/functional/search/base.php
index d41e3ec925..f77ef70ecc 100644
--- a/tests/functional/search/base.php
+++ b/tests/functional/search/base.php
@@ -36,6 +36,8 @@ abstract class phpbb_functional_search_base extends phpbb_functional_test_case
$this->login();
$this->admin_login();
+ $this->create_search_index('\phpbb\search\fulltext_native');
+
$post = $this->create_topic(2, 'Test Topic 1 foosubject', 'This is a test topic posted by the barsearch testing framework.');
$crawler = self::request('GET', 'adm/index.php?i=acp_search&mode=settings&sid=' . $this->sid);
@@ -58,6 +60,7 @@ abstract class phpbb_functional_search_base extends phpbb_functional_test_case
$this->delete_topic($post['topic_id']);
$this->markTestSkipped("Search backend is not supported/running");
}
+
$this->create_search_index();
}
@@ -72,7 +75,7 @@ abstract class phpbb_functional_search_base extends phpbb_functional_test_case
$this->delete_topic($post['topic_id']);
}
- protected function create_search_index()
+ protected function create_search_index($backend = null)
{
$this->add_lang('acp/search');
$crawler = self::request('GET', 'adm/index.php?i=acp_search&mode=index&sid=' . $this->sid);
@@ -81,7 +84,7 @@ abstract class phpbb_functional_search_base extends phpbb_functional_test_case
'POST',
'adm/index.php?i=acp_search&mode=index&sid=' . $this->sid,
array(
- 'search_type' => $this->search_backend,
+ 'search_type' => ( ($backend === null) ? $this->search_backend : $backend ),
'action' => 'create',
'submit' => true,
'form_token' => $form_values['form_token'],