From 2532aca967d543b05fc2d3995b0800b845aa6b5e Mon Sep 17 00:00:00 2001 From: Alexey Sokolov Date: Sat, 17 Sep 2016 18:23:54 +0100 Subject: [PATCH] Simplify jenkins file and enable integration test --- Jenkinsfile | 40 +++++++++++++++------------------------- 1 file changed, 15 insertions(+), 25 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 2de28418..ca1f389f 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,39 +1,29 @@ #!groovy node('freebsd') { - // freebsd 10.3 + pkg install git openjdk cmake icu pkgconf swig30 python3 + // freebsd 10.3 + pkg install git openjdk cmake icu pkgconf swig30 python3 boost-libs gettext-tools qt5-buildtools qt5-network qt5-qmake timestamps { - try { - timeout(time: 30, unit: 'MINUTES') { - def srcdir = pwd() - def tmpdir = pwd([tmp: true]) - stage('Checkout') { - step([$class: 'WsCleanup']) - checkout scm - sh 'git submodule update --init --recursive' - } + timeout(time: 30, unit: 'MINUTES') { + def srcdir = pwd() + def tmpdir = pwd([tmp: true]) + stage('Checkout') { + step([$class: 'WsCleanup']) + checkout scm + sh 'git submodule update --init --recursive' + } + dir("$tmpdir/build") { stage('Build') { - dir("$tmpdir/build") { - sh "cmake $srcdir -DWANT_PERL=ON -DWANT_PYTHON=ON -DCMAKE_INSTALL_PREFIX=$tmpdir/install-prefix" - sh 'make VERBOSE=1 all' - } + sh "cmake $srcdir -DWANT_PERL=ON -DWANT_PYTHON=ON -DCMAKE_INSTALL_PREFIX=$tmpdir/install-prefix" + sh 'make VERBOSE=1 all' } stage('Unit test') { - dir("$tmpdir/build") { - sh 'make unittest' - } + sh 'make unittest' } stage('Integration test') { - dir("$tmpdir/build") { - sh 'make install' - // TODO: run make inttest - } + sh 'make install' + sh 'make inttest' } } - currentBuild.result = 'SUCCESS' - } catch (err) { - echo "Error: ${err}" - currentBuild.result = 'FAILURE' } } }