Files

46 lines
2.2 KiB
Gherkin
Raw Permalink Normal View History

@env-config
2023-01-02 16:20:53 +05:45
Feature: delay post-processing of uploaded files
As a user
I want to delay the post-processing of uploaded files
So that I can check the early request
2023-01-02 16:20:53 +05:45
Background:
Given user "Alice" has been created with default attributes
2024-04-26 15:27:00 +05:45
And async upload has been enabled with post-processing delayed to "30" seconds
2023-01-02 16:20:53 +05:45
2023-01-05 11:58:30 +05:45
@issue-5326
2023-01-02 16:20:53 +05:45
Scenario Outline: user sends GET request to the file while it's still being processed
2023-01-05 17:54:33 +05:45
Given user "Alice" has uploaded file with content "uploaded content" to "/file.txt"
When user "Alice" requests "<dav-path>" with "GET" without retrying
2023-01-02 16:20:53 +05:45
Then the HTTP status code should be "425"
Examples:
2024-09-17 17:11:20 +05:45
| dav-path |
| /webdav/file.txt |
| /dav/files/%username%/file.txt |
| /dav/spaces/%spaceid%/file.txt |
2023-01-02 16:20:53 +05:45
2023-01-05 15:00:32 +05:45
2023-01-02 16:20:53 +05:45
Scenario Outline: user sends PROPFIND request to the file while it's still being processed
2023-01-05 17:54:33 +05:45
Given user "Alice" has uploaded file with content "uploaded content" to "/file.txt"
When user "Alice" requests "<dav-path>" with "PROPFIND" without retrying
2023-01-05 15:00:32 +05:45
Then the HTTP status code should be "207"
And the value of the item "//d:response/d:propstat/d:status" in the response should be "HTTP/1.1 425 TOO EARLY"
2023-01-02 16:20:53 +05:45
Examples:
2024-09-17 17:11:20 +05:45
| dav-path |
| /webdav/file.txt |
| /dav/files/%username%/file.txt |
| /dav/spaces/%spaceid%/file.txt |
2023-01-05 17:54:33 +05:45
2023-01-06 12:21:19 +05:45
Scenario Outline: user sends PROPFIND request to the folder while files in the folder are still being processed
2023-01-05 17:54:33 +05:45
Given user "Alice" has created folder "my_data"
And user "Alice" has uploaded file with content "uploaded content" to "/my_data/file.txt"
When user "Alice" requests "<dav-path>" with "PROPFIND" without retrying
2023-01-05 17:54:33 +05:45
Then the HTTP status code should be "207"
And as user "Alice" the value of the item "//d:status" of path "<dav-path>/" in the response should be "HTTP/1.1 200 OK"
And as user "Alice" the value of the item "//d:status" of path "<dav-path>/file.txt" in the response should be "HTTP/1.1 425 TOO EARLY"
2023-01-05 17:54:33 +05:45
Examples:
2024-09-17 17:11:20 +05:45
| dav-path |
| /webdav/my_data |
| /dav/files/%username%/my_data |
| /dav/spaces/%spaceid%/my_data |