diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index a704105..eec4bf8 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -4,23 +4,19 @@ stages: playwright_tests: stage: test - image: mcr.microsoft.com/playwright:focal + image: mcr.microsoft.com/playwright:v1.43.0-jammy # 使用官方 Playwright 镜像 before_script: - - export NVM_DIR="$HOME/.nvm" - - . "$NVM_DIR/nvm.sh" - - nvm use 20.17.0 - npm config set registry https://registry.npmmirror.com # 使用淘宝镜像 script: - npm install - npx playwright install - - npx playwright install-deps - npx playwright test artifacts: paths: - test-results/ expire_in: 1 week tags: - - test # 指定使用标签为 test 的 Runner + - test only: - main @@ -36,6 +32,6 @@ send_report: echo "No test results found." fi tags: - - test # 指定使用标签为 test 的 Runner + - test only: - main