diff options
author | Tristan Darricau <github@nicofuma.fr> | 2016-09-18 21:14:47 +0200 |
---|---|---|
committer | Tristan Darricau <github@nicofuma.fr> | 2016-09-18 21:14:47 +0200 |
commit | 19bbbfe0f3e9898f2ee8d8d392ecf2584dafce86 (patch) | |
tree | c6ee9901bdf6f8bd405d3bcd563a9cab8d8a7392 /tests/functional/search | |
parent | 47d2f34a1b9008332bcd27d5e855f1fc05ff1ab2 (diff) | |
parent | bc08813866a4496b88777a5d152f601ac521fef1 (diff) | |
download | forums-19bbbfe0f3e9898f2ee8d8d392ecf2584dafce86.tar forums-19bbbfe0f3e9898f2ee8d8d392ecf2584dafce86.tar.gz forums-19bbbfe0f3e9898f2ee8d8d392ecf2584dafce86.tar.bz2 forums-19bbbfe0f3e9898f2ee8d8d392ecf2584dafce86.tar.xz forums-19bbbfe0f3e9898f2ee8d8d392ecf2584dafce86.zip |
Merge branch '3.1.x' into 3.2.x
* 3.1.x:
[ticket/14789] Add form tokens to tests and uncomment add_form_key
[ticket/14789] Add link hashes and form tokens to all acp links/buttons
Diffstat (limited to 'tests/functional/search')
-rw-r--r-- | tests/functional/search/base.php | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/functional/search/base.php b/tests/functional/search/base.php index a3cac381d2..f77ef70ecc 100644 --- a/tests/functional/search/base.php +++ b/tests/functional/search/base.php @@ -78,6 +78,8 @@ abstract class phpbb_functional_search_base extends phpbb_functional_test_case 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); + $form_values = $crawler->selectButton('Delete index')->form()->getValues(); $crawler = self::request( 'POST', 'adm/index.php?i=acp_search&mode=index&sid=' . $this->sid, @@ -85,6 +87,8 @@ abstract class phpbb_functional_search_base extends phpbb_functional_test_case 'search_type' => ( ($backend === null) ? $this->search_backend : $backend ), 'action' => 'create', 'submit' => true, + 'form_token' => $form_values['form_token'], + 'creation_time' => $form_values['creation_time'], ) ); $this->assertContainsLang('SEARCH_INDEX_CREATED', $crawler->text()); @@ -93,6 +97,8 @@ abstract class phpbb_functional_search_base extends phpbb_functional_test_case protected function delete_search_index() { $this->add_lang('acp/search'); + $crawler = self::request('GET', 'adm/index.php?i=acp_search&mode=index&sid=' . $this->sid); + $form_values = $crawler->selectButton('Delete index')->form()->getValues(); $crawler = self::request( 'POST', 'adm/index.php?i=acp_search&mode=index&sid=' . $this->sid, @@ -100,6 +106,8 @@ abstract class phpbb_functional_search_base extends phpbb_functional_test_case 'search_type' => $this->search_backend, 'action' => 'delete', 'submit' => true, + 'form_token' => $form_values['form_token'], + 'creation_time' => $form_values['creation_time'], ) ); $this->assertContainsLang('SEARCH_INDEX_REMOVED', $crawler->text()); |