Closed phil-davis closed 4 years ago
An example test scenario run is:
make test-acceptance-webui BEHAT_FEATURE=tests/acceptance/features/webUIPasswordChangeUsersPage/passwordChangeLowercaseLetters.feature:25
And I see output like:
[Tue Mar 24 09:52:15 2020] 172.17.0.3:59492 [200]: /index.php/settings/users/changepassword
[Tue Mar 24 09:52:16 2020] 10.49.210.9:39956 [200]: /ocs/v2.php/cloud/users/user1
[Tue Mar 24 09:52:16 2020] 10.49.210.9:39958 [200]: /remote.php/webdav/textfile0.txt
[Tue Mar 24 09:52:16 2020] Login failed: 'user1' (Remote IP: '10.49.210.9')
[Tue Mar 24 09:52:16 2020] 10.49.210.9:39960 [401]: /remote.php/webdav/textfile0.txt
[Tue Mar 24 09:52:16 2020] Undefined index: value at /home/phil/git/owncloud/core/apps-external/testing/lib/Config.php#102
[Tue Mar 24 09:52:16 2020] 10.49.210.9:39962 [200]: /ocs/v2.php/apps/testing/api/v1/apps
[Tue Mar 24 09:52:16 2020] 10.49.210.9:39964 [200]: /ocs/v2.php/apps/testing/api/v1/apps
[Tue Mar 24 09:52:16 2020] 10.49.210.9:39966 [200]: /ocs/v2.php/apps/testing/api/v1/occ
[Tue Mar 24 09:52:16 2020] 10.49.210.9:39968 [200]: /ocs/v2.php/apps/testing/api/v1/opcache
[Tue Mar 24 09:52:17 2020] 10.49.210.9:39970 [200]: /ocs/v2.php/apps/testing/api/v1/occ
It seems to happen with UI tests.
IMO that "login failed" was meant to be part of the test - the test scenario does check for trying to download with a wrong password. That might help debugging - the Undefined index
comes after the test step, so it could be that the problem is in an AfterScenario
While doing var dump in one of the After Scenario for the test
make test-acceptance-webui BEHAT_FEATURE=tests/acceptance/features/webUIPasswordChangeUsersPage/passwordChangeLowercaseLetters.feature:25
The output was Like this
....../core/tests/TestHelpers/AppConfigHelper.php:299:
│ array(3) {
.
.
.
│ [2] =>
│ array(3) {
│ 'configkey' =>
│ string(5) "types"
│ 'value' =>
│ array(0) {
│ }
│ 'appid' =>
│ string(15) "password_policy"
│ }
│ }
Here, The value
is an empty array, which is responsible for the undefined index value output in server log. The problem has been fixed by the PR https://github.com/owncloud/core/pull/37162 by converting the array of value
into string
While running some password_policy tests locally I noticed my PHP dev server output:
Something is calling the testing app to set some setting(s) and is not sending
value
Investigate.
(Probably this will be something in
run.sh
or a BeforeScenario of the ordinary test environment setup - ~likely it needs fixing in core - just a guess~ - it does not happen when I run a core scenario, so next guess is something in password_policy BeforeScenario)