Docker Basics merge requestshttps://codebase.helmholtz.cloud/kit-scc-sdm/onlinestorage/httpd-webdav/docker-basics/-/merge_requests2023-06-23T14:46:09+02:00https://codebase.helmholtz.cloud/kit-scc-sdm/onlinestorage/httpd-webdav/docker-basics/-/merge_requests/3Request authentication in WebDAV test suite2023-06-23T14:46:09+02:00Paul SkopnikRequest authentication in WebDAV test suiteThis MR contributes a first version of configuring authentication per file/directory for the WebDAV test suite.
* Auth objects (`BasicAuth`, ...) have to be instantiated [in the specific test file](https://codebase.helmholtz.cloud/kit-...This MR contributes a first version of configuring authentication per file/directory for the WebDAV test suite.
* Auth objects (`BasicAuth`, ...) have to be instantiated [in the specific test file](https://codebase.helmholtz.cloud/kit-scc-sdm/onlinestorage/httpd-webdav/docker-basics/-/blob/webdav-suite-authentication/images/configurations/dav/tests/test_webdav.py).
That is a mismatch to the otherwise pure-dict spec containing the information for known files and directories.
Instantiating auth objects is perhaps the simplest way to express the no auth/basic auth/token auth configuration.
We could consider switching to instantiating the full info objects directly.
* **→ This MR requires specifying full info objects directly**
* Tests involving multiple entities (e.g. copying a _file_ to a _collection_, `test_copy_accessible`) must have the same authentication attached to the entities - i.e. info objects - to be meaningful.
However, for parameterised fixtures, pytest will run all combinations (cartesian product) of parameter values.
The `single_auth_info` fixture will automatically discard combinations of parameter values containing different authentications.
It does so by marking the test as skipped, see `Mismatching auth infos` [in the output](https://codebase.helmholtz.cloud/kit-scc-sdm/onlinestorage/httpd-webdav/docker-basics/-/jobs/888145).
The skipping behaviour makes reviewing tests complicated:
If there happens to be no single combination of parameter values with the same auth, the underlying test (e.g. `test_copy_accessible`) is never executed and this is only visible when looking at passed vs skipped tests.
This is even more complicated, because for the particular trick with the common suite, not all information is shown at the same time (try identifying which function is skipped due to mismatching auths purely from output...).
A possible fix could be to check after the testing completes whether a specific function was always skipped with a mismatching auth message.
* **→ There will be an issue filed for possibly tackling this in the future**
* Non-existent entities are not specified by in the test file right now but instead chosen in the generic suite.
To fulfill the above requirement, these will need authentication as well, so for example these must be specified in the specific test file.
* **→ This MR allows specifying non-existent "paths" (as these don't exist there is no distinction between files and directories)**
/cc @cw296Paul SkopnikPaul Skopnikhttps://codebase.helmholtz.cloud/kit-scc-sdm/onlinestorage/httpd-webdav/docker-basics/-/merge_requests/2Add LDAP server image with test data2023-03-10T15:13:34+01:00Florian HeuschkelAdd LDAP server image with test dataAdd LDAP server image with test data for the webdav_suite tests.
Closes #11Add LDAP server image with test data for the webdav_suite tests.
Closes #11Florian HeuschkelFlorian Heuschkelhttps://codebase.helmholtz.cloud/kit-scc-sdm/onlinestorage/httpd-webdav/docker-basics/-/merge_requests/1Add HTTPS support in pytest apache httpd2023-02-23T18:30:11+01:00Florian HeuschkelAdd HTTPS support in pytest apache httpdAdd HTTPS support in pytest apache httpd.
Set certificate verification to False since for testing purposes we
already know the server which only has self signed certs.
Closes #10Add HTTPS support in pytest apache httpd.
Set certificate verification to False since for testing purposes we
already know the server which only has self signed certs.
Closes #10Florian HeuschkelFlorian Heuschkel