From 8b569ed46c31070c274c15b3274eee0740d33bee Mon Sep 17 00:00:00 2001 From: swoichha Date: Thu, 5 Mar 2020 16:55:44 +0545 Subject: [PATCH 1/2] scenario for renaming file with dots in the path --- .../features/apiWebdavMove2/moveFile.feature | 20 +++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/tests/acceptance/features/apiWebdavMove2/moveFile.feature b/tests/acceptance/features/apiWebdavMove2/moveFile.feature index f2f527e9109a..450672108058 100644 --- a/tests/acceptance/features/apiWebdavMove2/moveFile.feature +++ b/tests/acceptance/features/apiWebdavMove2/moveFile.feature @@ -279,3 +279,23 @@ Feature: move (rename) file | #oc ab?cd=ef# | | *a@b#c$e%f&g* | | 1 2 3##.## | + + Scenario Outline: renaming file with dots in the path + Given using DAV path + And user "user0" has created folder "" + When user "user0" uploads file with content "uploaded content for file name ending with a dot" to "/" using the WebDAV API + And user "user0" moves file "//" to "/" using the WebDAV API + Then the HTTP status code should be "" + Examples: + | dav_version | folder_name | file_name | renamed_file | http-code | + | old | /upload. | abc. | abc.txt | 201 | + | old | /upload. | abc . | abc.txt | 201 | + | old | /upload.1 | abc.txt | abc.txt | 201 | + | old | /upload...1.. | abc...txt.. | abc.txt | 201 | + | old | /... | abcd.txt | abc.txt | 201 | + | new | /upload. | abc. | abc.txt | 201 | + | new | /upload. | abc . | abc.txt | 201 | + | new | /upload.1 | abc.txt | abc.txt | 201 | + | new | /upload...1.. | abc...txt.. | abc.txt | 201 | + | new | /... | ... | abc.txt | 201 | + | new | /..upload | ..abc | abc.txt | 201 | \ No newline at end of file From 66d04a33ddcc90eea148298584311b472dba966b Mon Sep 17 00:00:00 2001 From: swoichha Date: Fri, 6 Mar 2020 16:57:31 +0545 Subject: [PATCH 2/2] resolved reviews --- .../features/apiWebdavMove2/moveFile.feature | 30 ++++++++++--------- 1 file changed, 16 insertions(+), 14 deletions(-) diff --git a/tests/acceptance/features/apiWebdavMove2/moveFile.feature b/tests/acceptance/features/apiWebdavMove2/moveFile.feature index 450672108058..631194111def 100644 --- a/tests/acceptance/features/apiWebdavMove2/moveFile.feature +++ b/tests/acceptance/features/apiWebdavMove2/moveFile.feature @@ -284,18 +284,20 @@ Feature: move (rename) file Given using DAV path And user "user0" has created folder "" When user "user0" uploads file with content "uploaded content for file name ending with a dot" to "/" using the WebDAV API - And user "user0" moves file "//" to "/" using the WebDAV API - Then the HTTP status code should be "" + And user "user0" moves file "/" to "/abc.txt" using the WebDAV API + Then the HTTP status code should be "201" + And as "user0" file "/abc.txt" should exist Examples: - | dav_version | folder_name | file_name | renamed_file | http-code | - | old | /upload. | abc. | abc.txt | 201 | - | old | /upload. | abc . | abc.txt | 201 | - | old | /upload.1 | abc.txt | abc.txt | 201 | - | old | /upload...1.. | abc...txt.. | abc.txt | 201 | - | old | /... | abcd.txt | abc.txt | 201 | - | new | /upload. | abc. | abc.txt | 201 | - | new | /upload. | abc . | abc.txt | 201 | - | new | /upload.1 | abc.txt | abc.txt | 201 | - | new | /upload...1.. | abc...txt.. | abc.txt | 201 | - | new | /... | ... | abc.txt | 201 | - | new | /..upload | ..abc | abc.txt | 201 | \ No newline at end of file + | dav_version | folder_name | file_name | + | old | /upload. | abc. | + | old | /upload. | abc . | + | old | /upload.1 | abc | + | old | /upload...1.. | abc...txt.. | + | old | /... | abcd.txt | + | old | /..upload | ..abc | + | new | /upload. | abc. | + | new | /upload. | abc . | + | new | /upload.1 | ..abc.txt | + | new | /upload...1.. | abc...txt.. | + | new | /... | ... | + | new | /..upload | ..abc | \ No newline at end of file