File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -2,9 +2,11 @@ pipeline {
22 agent any
33
44 environment {
5- NODE_VERSION = ' 18'
6- TEST_ENV = ' QA'
7- PLAYWRIGHT_BROWSERS_PATH = " ${ WORKSPACE} \\ ms-playwright"
5+ NODE_VERSION = ' 18'
6+ TEST_ENV = ' QA'
7+ PLAYWRIGHT_BROWSERS_PATH = " ${ WORKSPACE} \\ ms-playwright"
8+ NPM_CONFIG_PREFIX = " ${ WORKSPACE} \\ .npm-global"
9+ PATH = " ${ WORKSPACE} \\ .npm-global\\ bin;${ env.PATH} "
810 }
911
1012 parameters {
@@ -35,6 +37,14 @@ pipeline {
3537 githubPush()
3638 }
3739
40+ stage(' 📦 Prepare NPM' ) {
41+ steps {
42+ bat '''
43+ if not exist "%WORKSPACE%\\ .npm-global" mkdir "%WORKSPACE%\\ .npm-global"
44+ '''
45+ }
46+ }
47+
3848 stages {
3949 stage(' 🔍 Checkout' ) {
4050 steps {
@@ -59,7 +69,7 @@ pipeline {
5969 echo ' === Instalando navegadores de Playwright ==='
6070 bat '''
6171 set PLAYWRIGHT_BROWSERS_PATH=%WORKSPACE%\\ ms-playwright
62- npx playwright install
72+ npx --prefix %WORKSPACE% \\ .npm-global playwright install
6373 '''
6474 }
6575 }
You can’t perform that action at this time.
0 commit comments