notroj / litmus

WebDAV test suite.
https://notroj.github.io/litmus/
GNU General Public License v2.0
12 stars 4 forks source link

Proppatch method is poorly evaluated in several tests #21

Open johaven opened 3 months ago

johaven commented 3 months ago

Random properties placed in the "set" are not necessarily allowed on the server. It is therefore normal that a multistatus response with a code 207 is generated and for some tests this should be enough! Even if the content of the multistatus contains errors (unknown or unauthorized properties)

Some examples:

Capture d’écran 2024-05-31 à 10 28 47

In this case a 207 response should be accepted (the properties are not allowed) Same for the propmanys test.

Capture d’écran 2024-05-31 à 10 31 46

In this case a 207 response should be accepted, the lock test should not be dependent on the multistatus response (especially for unauthorized property modification). In case of a lock that is not held by the owner, the response should be a 423 code (since the method targets the direct resource)

notroj commented 1 month ago

By "not necessarily allowed" do you mean that the server doesn't support arbitrary dead properties? This is only a SHOULD requirement in 4918 but I think most of the litmus property tests would pointless if it only gave warnings for servers for servers where dead props were unusable.

(You could similarly argue that litmus isn't good for testing a DAV compliant server which only accepts PUT requests to resources called "fred.txt" - sure, you can make such a server and argue it's perfectly compliant with 4918 - there's just not much point running litmus against it)

I would accept a PR adding a --no-dead-props argument to skip these tests as way to opt-out, I guess?