1
0
mirror of https://github.com/owncloud/ocis.git synced 2026-10-23 23:29:02 +03:00
Files
ocis/tests/acceptance/features/cliCommands/searchOptimize.feature
Pradip Subedi 766e350ef9 [tests-only][full-ci] test(cli): add acceptance tests for the search optimize command (#12741)
* test(cli): add acceptance tests for the search optimize command

* test(cli): fix search retry loop passing limit as isVault

* test(cli): add empty-index optimize scenario and baseline search assertion

* test(cli): retry search only on 5xx and harden searchOptimize assertions
2026-09-08 16:34:35 +05:45

37 lines
1.5 KiB
Gherkin

@env-config
Feature: optimize search index via CLI command
As an administrator
I want to optimize the search index
So that I can improve search query performance
Background:
Given the administrator has cleaned the search service data
Scenario: optimize the search index
Given user "Alice" has been created with default attributes
And using spaces DAV path
And user "Alice" has uploaded file with content "some data" to "textfile.txt"
When the administrator reindexes all spaces using the CLI
Then the command should be successful
When user "Alice" searches for "textfile.txt" using the WebDAV API
Then the HTTP status code should be "207"
And the search result of user "Alice" should contain only these entries:
| /textfile.txt |
And the administrator has stopped the server
When the administrator optimizes the search index using the CLI
Then the command should be successful
And the command output should contain "index optimization complete"
When the administrator starts the server
And user "Alice" searches for "textfile.txt" using the WebDAV API
Then the HTTP status code should be "207"
And the search result of user "Alice" should contain only these entries:
| /textfile.txt |
Scenario: optimize the search index without any indexed content
Given the administrator has stopped the server
When the administrator optimizes the search index using the CLI
Then the command should be successful
And the command output should contain "index optimization complete"