solid-contrib/webid-provider-tests

Allow different ways to get a login cookie

Closed this issue · 2 comments

The code in https://github.com/solid/webid-provider-tests/blob/master/test/surface/authorize-endpoint.test.ts#L8
was only tested on node-solid-server. I should have a version for nextcloud-server, including:

curl -ki https://localhost/login | grep requesttoken
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  5524  100  5524    0     0  71740      0 --:--:-- --:--:-- --:--:-- 71740
 data-requesttoken="BAw3N1zas5Z8O8Z3dbH2tYhaHbSE963wtep3iLap+EU=:Vz1YZgS+mOxNS60cRdaRxu4tTuP0wMaE34IQsfTLkyI=">

and 'user' instead of 'username' in https://github.com/solid/webid-provider-tests/blob/master/test/surface/authorize-endpoint.test.ts#L13

still not able to obtain a cookie for nextcloud-server. it seems the browser is doing something different in its POST request when you use the login form than when you click copy-as-curl on that request and play it from the command line. For now, I'll use a workaround where you need to specify COOKIE as an env var. This means that these tests cannot be run automatically as part of pdsinterop/test-suites yet.

the code for getting the cookie was moved to separate docker images, one for each server in pdsinterop/test-suites