From 3ae9a5f1be5260cb930d97530d28dedb202e62dc Mon Sep 17 00:00:00 2001 From: nabim777 Date: Tue, 18 Jul 2023 10:52:46 +0545 Subject: [PATCH] add api test for search restored file through tag --- tests/acceptance/config/behat.yml | 1 + .../features/apiFullTextSearch/search.feature | 17 +++++++++++++++++ 2 files changed, 18 insertions(+) diff --git a/tests/acceptance/config/behat.yml b/tests/acceptance/config/behat.yml index c42a4e7c56d..c797fd44f60 100644 --- a/tests/acceptance/config/behat.yml +++ b/tests/acceptance/config/behat.yml @@ -209,6 +209,7 @@ default: - CapabilitiesContext: - FilesVersionsContext: - OCSContext: + - TrashbinContext: extensions: rdx\behatvars\BehatVariablesExtension: ~ diff --git a/tests/acceptance/features/apiFullTextSearch/search.feature b/tests/acceptance/features/apiFullTextSearch/search.feature index fb3fdd86856..edba6eead60 100644 --- a/tests/acceptance/features/apiFullTextSearch/search.feature +++ b/tests/acceptance/features/apiFullTextSearch/search.feature @@ -66,3 +66,20 @@ Feature: full text search | old | | new | | spaces | + + + Scenario Outline: search restored files by content + Given using DAV path + And user "Alice" has created folder "uploadFolder" + And user "Alice" has uploaded file with content "hello world from nepal" to "keywordAtStart.txt" + And user "Alice" has deleted file "keywordAtStart.txt" + And user "Alice" has restored the file with original path "keywordAtStart.txt" + When user "Alice" searches for "Content:hello" using the WebDAV API + Then the HTTP status code should be "207" + And the search result of user "Alice" should contain only these files: + | keywordAtStart.txt | + Examples: + | dav-path-version | + | old | + | new | + | spaces |