core icon indicating copy to clipboard operation
core copied to clipboard

TUS tests (most of them) cannot check the HTTP status code

Open individual-it opened this issue 3 years ago • 2 comments

In most test-cases for TUS we are using a library and that does not report the HTTP status code, so the checks should be deleted from there

e.g.

    And user "Alice" uploads file with content "01234" in 5 chunks to "/myChunkedFile.txt" using the TUS protocol on the WebDAV API        # TUSContext::userUploadsAFileWithContentInChunksUsingTus()
    Then the HTTP status code should be "200" 

above, the Then the HTTP status code should be "200" passes because it checks a completely different response code, not the one returned by the tus upload (which uses 201 for the initial POST and 204 for PATCH requests).

Note: There are some steps e.g. @When user :user creates a new TUS resource on the WebDAV API with these headers: that do low-level API calls with our own code and those DO report the HTTP status code, for those cases the checks should stay in place

individual-it avatar Jul 19 '22 09:07 individual-it

user uploads file with content "01234" in 5 chunks -> it means that he sends 5 times PatchRequest. But we don't check that evert requests get us 204

ScharfViktor avatar Jul 19 '22 09:07 ScharfViktor

No, because the library we are using is not exposing that information

individual-it avatar Jul 19 '22 10:07 individual-it