cfiles
cfiles copied to clipboard
Check Tests
It seems that the tests currently fail randomly.
@luke- Yes, I confirm it is randomly, because after commit the PR https://github.com/humhub/cfiles/pull/182 tests were broken, and only after re-run they became green. It looks sometimes not enough time to execute, and it always randomly.
@yurabakhtin Can you identify which steps has not enough time?
@luke- Today I have re-run the tests of the PR 2 times and they were successful. Then I run them locally:
The error $I->waitForElement(".disable-module-cfiles") at ..\..\..\humhub\tests\codeception\_support\AcceptanceTester.php:258
is from core module enabling $I->enableModule($guid, 'cfiles')
.
The error 31. $I->waitForText("newFile.txt") at codeception\_support\AcceptanceTester.php:46
because default time is 10 seconds waitForElement($element, $timeout = 10)
but I am not sure that we should increase it to 15 or 20 seconds because after that error I could run 4 times locally without error and then again the same error.
Maybe my local server is not enough fast and we just should merge the PR https://github.com/humhub/cfiles/pull/182 and wait when new error will appears.
@yurabakhtin Ok, thanks. Then lets try it PR 182 is enough. Otherwise we can try to increase the timeout.
@luke- After merge the PR I see an error only on PHP 8.1-mysql-5.7-humhub-master
- https://github.com/humhub/cfiles/actions/runs/5145542272/jobs/9263314209
I can try to increase a time here https://github.com/humhub/cfiles/blob/master/tests/codeception/_support/AcceptanceTester.php#L137 but not sure we should do this.
@yurabakhtin Hmm, any other idea instead to increase this timeout?
@luke- Sorry, no idea because it looks correctly:
Maybe only if set the second param 10
because the method has the declration public function waitForText($text, $timeout = 10, $selector = NULL)
.