feat: Jenkinsfile
This commit is contained in:
31
Jenkinsfile
vendored
Normal file
31
Jenkinsfile
vendored
Normal file
@@ -0,0 +1,31 @@
|
||||
pipeline {
|
||||
agent any
|
||||
environment {
|
||||
CI = 'true'
|
||||
}
|
||||
stages {
|
||||
stage('Install dependencies') {
|
||||
steps {
|
||||
script {
|
||||
if (fileExists('package-lock.json')) {
|
||||
bat 'npm ci'
|
||||
} else {
|
||||
bat 'npm install'
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
stage('Run Playwright tests') {
|
||||
steps {
|
||||
bat 'npx playwright install --with-deps'
|
||||
bat 'npx playwright test'
|
||||
}
|
||||
}
|
||||
}
|
||||
post {
|
||||
always {
|
||||
junit 'playwright/test-results/**/*.xml'
|
||||
archiveArtifacts artifacts: 'playwright/test-results/**', allowEmptyArchive: true
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user