1
0
mirror of https://github.com/Bayselonarrend/OpenIntegrations.git synced 2025-11-25 22:12:29 +02:00
Files
OpenIntegrations/ci/split_tests/Bitrix24/cli_deb_test_en

132 lines
5.3 KiB
Plaintext
Raw Normal View History

2025-07-30 09:58:25 +03:00
def runCommand(String command) {
if (isUnix()) {
sh(script: command)
} else {
bat(script: command)
}
}
pipeline {
agent {
label 'Deb-Agent' // Имя или метка агента
}
stages {
stage('Remove oint') {
steps {
script {
// Удаляем oint, если он установлен
sh 'dpkg -r oint || echo "oint not installed"'
}
}
}
stage('Download oint package') {
steps {
script {
// Скачиваем новый deb-пакет oint
2025-09-18 13:55:48 +03:00
sh 'wget -O oint_1.28.0_all_en.deb https://jenkins.openintegrations.dev/job/OpiBuild/job/OpiRelease/lastSuccessfulBuild/artifact/1.28.0/oint_1.28.0_all_en.deb '
2025-07-30 09:58:25 +03:00
}
}
}
stage('Install oint package') {
steps {
script {
// Устанавливаем скаченный пакет
2025-09-18 13:55:48 +03:00
sh 'dpkg -i oint_1.28.0_all_en.deb'
2025-07-30 09:58:25 +03:00
}
}
}
stage('Prepare'){
steps{
2025-09-18 13:55:48 +03:00
sh 'cd ./src/en/OInt && opm build && opm install oint-1.28.0.ospx && rm oint-1.28.0.ospx'
2025-07-30 09:58:25 +03:00
withCredentials([string(credentialsId: 'gpgkey', variable: 'GPGKEY')]) {
sh 'gpg --quiet --batch --yes --decrypt --passphrase="$GPGKEY" --output ./data.json ./data.json.gpg'
}
}
}
2025-09-02 09:03:47 +03:00
stage('Create ReportPortal launch'){
steps{
sh 'oscript ./ci/os/rp_start.os "CLI"'
}
}
2025-07-30 09:58:25 +03:00
stage('Testing-Bitrix24') {
steps {
catchError(buildResult: 'FAILURE', stageResult: 'FAILURE') {
2025-09-02 11:36:01 +03:00
runCommand('1testrunner -run "./src/en/OInt/tests/Modules/internal/OPI_TestsCLI.os" "B24_TokenManagement"')
2025-07-30 09:58:25 +03:00
}
catchError(buildResult: 'FAILURE', stageResult: 'FAILURE') {
2025-09-02 11:36:01 +03:00
runCommand('1testrunner -run "./src/en/OInt/tests/Modules/internal/OPI_TestsCLI.os" "B24_ServerTime"')
2025-07-30 09:58:25 +03:00
}
catchError(buildResult: 'FAILURE', stageResult: 'FAILURE') {
2025-09-02 11:36:01 +03:00
runCommand('1testrunner -run "./src/en/OInt/tests/Modules/internal/OPI_TestsCLI.os" "B24_PostsManagement"')
2025-07-30 09:58:25 +03:00
}
catchError(buildResult: 'FAILURE', stageResult: 'FAILURE') {
2025-09-02 11:36:01 +03:00
runCommand('1testrunner -run "./src/en/OInt/tests/Modules/internal/OPI_TestsCLI.os" "B24_TaskManagement"')
2025-07-30 09:58:25 +03:00
}
catchError(buildResult: 'FAILURE', stageResult: 'FAILURE') {
2025-09-02 11:36:01 +03:00
runCommand('1testrunner -run "./src/en/OInt/tests/Modules/internal/OPI_TestsCLI.os" "B24_CommentsManagement"')
2025-07-30 09:58:25 +03:00
}
catchError(buildResult: 'FAILURE', stageResult: 'FAILURE') {
2025-09-02 11:36:01 +03:00
runCommand('1testrunner -run "./src/en/OInt/tests/Modules/internal/OPI_TestsCLI.os" "B24_WorkingWithDrive"')
2025-07-30 09:58:25 +03:00
}
catchError(buildResult: 'FAILURE', stageResult: 'FAILURE') {
2025-09-02 11:36:01 +03:00
runCommand('1testrunner -run "./src/en/OInt/tests/Modules/internal/OPI_TestsCLI.os" "B24_Kanban"')
2025-07-30 09:58:25 +03:00
}
catchError(buildResult: 'FAILURE', stageResult: 'FAILURE') {
2025-09-02 11:36:01 +03:00
runCommand('1testrunner -run "./src/en/OInt/tests/Modules/internal/OPI_TestsCLI.os" "B24_Timekeeping"')
2025-07-30 09:58:25 +03:00
}
catchError(buildResult: 'FAILURE', stageResult: 'FAILURE') {
2025-09-02 11:36:01 +03:00
runCommand('1testrunner -run "./src/en/OInt/tests/Modules/internal/OPI_TestsCLI.os" "B24_ChatManagement"')
2025-07-30 09:58:25 +03:00
}
catchError(buildResult: 'FAILURE', stageResult: 'FAILURE') {
2025-09-02 11:36:01 +03:00
runCommand('1testrunner -run "./src/en/OInt/tests/Modules/internal/OPI_TestsCLI.os" "B24_NotificationsManagement"')
2025-07-30 09:58:25 +03:00
}
catchError(buildResult: 'FAILURE', stageResult: 'FAILURE') {
2025-09-02 11:36:01 +03:00
runCommand('1testrunner -run "./src/en/OInt/tests/Modules/internal/OPI_TestsCLI.os" "B24_TasksFieldsManagement"')
2025-07-30 09:58:25 +03:00
}
catchError(buildResult: 'FAILURE', stageResult: 'FAILURE') {
2025-09-02 11:36:01 +03:00
runCommand('1testrunner -run "./src/en/OInt/tests/Modules/internal/OPI_TestsCLI.os" "B24_DepartmentsManagement"')
2025-07-30 09:58:25 +03:00
}
catchError(buildResult: 'FAILURE', stageResult: 'FAILURE') {
2025-09-02 11:36:01 +03:00
runCommand('1testrunner -run "./src/en/OInt/tests/Modules/internal/OPI_TestsCLI.os" "B2_UsersManagement"')
2025-07-30 09:58:25 +03:00
}
catchError(buildResult: 'FAILURE', stageResult: 'FAILURE') {
2025-09-02 11:36:01 +03:00
runCommand('1testrunner -run "./src/en/OInt/tests/Modules/internal/OPI_TestsCLI.os" "B24_LeadsManagement"')
2025-07-30 09:58:25 +03:00
}
catchError(buildResult: 'FAILURE', stageResult: 'FAILURE') {
2025-09-02 11:36:01 +03:00
runCommand('1testrunner -run "./src/en/OInt/tests/Modules/internal/OPI_TestsCLI.os" "B24_DealsManagement"')
2025-07-30 09:58:25 +03:00
}
catchError(buildResult: 'FAILURE', stageResult: 'FAILURE') {
2025-09-02 11:36:01 +03:00
runCommand('1testrunner -run "./src/en/OInt/tests/Modules/internal/OPI_TestsCLI.os" "B24_CalendarsManagement"')
2025-07-30 09:58:25 +03:00
}
}
}
}
post{
always{
script {
2025-09-02 15:31:57 +03:00
catchError() {
2025-09-03 09:01:54 +03:00
runCommand('oscript ./ci/os/rp_stop.os "en"')
2025-09-02 15:31:57 +03:00
}
2025-07-30 09:58:25 +03:00
withCredentials([string(credentialsId: 'gpgkey', variable: 'GPGKEY')]) {
sh 'rm "./data.json.gpg"'
sh 'gpg --batch --symmetric --cipher-algo AES256 --passphrase="$GPGKEY" ./data.json'
sh 'rm "./data.json"'
}
withCredentials([gitUsernamePassword(credentialsId: 'gitmain', gitToolName: 'Default')]) {
sh "git config user.email vitaly.the.alpaca@gmail.com"
sh 'git config user.name "Vitaly the Alpaca (bot)"'
sh "git config --global core.ignorecase true"
sh "git add ."
sh 'git commit -m "Test data update (Jenkins)"'
sh "git push origin HEAD:main"
}
}
}
}
}