我可以使用Playwright-core和puppeteer-core启动Chrome浏览器,但我想使用codeceptjs和Playwright。
我们可以在CodeceptJS中使用Playwright-core或puppeteer core吗?
发布于 2021-03-22 06:58:40
已经给出了无需下载铬二进制文件in this issue post即可安装木偶剧的解决方案
npm config set puppeteer_skip_chromium_download true
npm install puppeteer对于playwright,存在与in their documentation相同类型的环境变量
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD=1 npm i -D playwright之后,您可以照常安装和配置CodeceptJS:
npm install codeceptjs
npx codeceptjs init请注意,还有an open issue in the CodeceptJS repository about supporting explicitely playwright-core包,因此没有直接安装该包的官方方式。
https://stackoverflow.com/questions/66736684
复制相似问题