Fixed: FileSystem.waitForFile: do not crash if directory does not exist yet by danielrentz ยท Pull Request #5421 ยท codeceptjs/CodeceptJS

Motivation/Description of the PR

Reworked the complex implementation of FileSystem.waitForFile, now it contains a simple polling loop that uses the existing fileExists helper function like FileSystem.seeFile does.

Applicable helpers:

  • Playwright
  • Puppeteer
  • WebDriver
  • REST
  • FileHelper
  • Appium
  • TestCafe

Applicable plugins:

  • allure
  • autoDelay
  • autoLogin
  • customLocator
  • pauseOnFail
  • coverage
  • retryFailedStep
  • screenshotOnFail
  • selenoid
  • stepByStepReport
  • stepTimeout
  • wdio
  • subtitles

Type of change

  • ๐Ÿ”ฅ Breaking changes
  • ๐Ÿš€ New functionality
  • ๐Ÿ› Bug fix
  • ๐Ÿงน Chore
  • ๐Ÿ“‹ Documentation changes/updates
  • โ™จ๏ธ Hot fix
  • ๐Ÿ”จ Markdown files fix - not related to source code
  • ๐Ÿ’… Polish code

Checklist:

  • Tests have been added
  • Documentation has been added (Run npm run docs)
  • Lint checking (Run npm run lint)
  • Local tests are passed (Run npm test)