# 安装pip3
sudo apt install python3-pip
# 安装pytest插件 pip3 install pytest-playwright pip3 install playwright
# 安装chromium firefox webkit等浏览器的驱动文件(内置浏览器)
python3 -m playwright install
若出现:BEWARE: your OS is not officially supported by Playwright; downloading fallback build.
rm -rf ~/.cache/ms-playwright/
# 录制
python3 -m playwright codegen 空白地址
python3 -m playwright codegen playwright.dev(制定域名)
标签:playwright,pip3,pytest,install,常用命令,python3 From: https://www.cnblogs.com/xxx1234-11225/p/17510521.html