From 330b4c1f44c0e191eaef39ce5e879eb84289dcc7 Mon Sep 17 00:00:00 2001 From: Jiri Vanek Date: Mon, 14 Aug 2023 17:47:03 +0200 Subject: [PATCH] Added testrun for jcov three tests are failing, and I think it is due to testng and jcommander version clash, but I had failed to set better versions combinations. This needs to be elaborate in upstream --- tools/code-tools/Jenkinsfile | 2 +- tools/code-tools/jcov.sh | 11 +++++++++++ 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/tools/code-tools/Jenkinsfile b/tools/code-tools/Jenkinsfile index 828224dc0..57ec170ea 100644 --- a/tools/code-tools/Jenkinsfile +++ b/tools/code-tools/Jenkinsfile @@ -76,7 +76,7 @@ def build(stageName) { checkout([$class: 'GitSCM', branches: [[name: 'master']], doGenerateSubmoduleConfigurations: false, extensions: [[$class: 'RelativeTargetDirectory', relativeTargetDir: "${stageName}"]], submoduleCfg: [], userRemoteConfigs: [[url: toolsUrl]]]) } sh label: "${stageName}", script: "./tools/code-tools/${stageName}.sh" - archiveArtifacts artifacts: "**/temurin-*-sbom.jar, ${stageName}/*.tar.gz, ${stageName}/${stageName}*.jar, ${stageName}/${stageName}*.jar.*.txt, ${stageName}/*.tar.gz.*sum*.txt, ${stageName}/${stageName}*.jar.html, ${stageName}/${stageName}*.jar.md, ${stageName}/${stageName}*.zip", followSymlinks: false + archiveArtifacts artifacts: "**/temurin-*-sbom.jar, ${stageName}/*.tar.gz, ${stageName}/${stageName}*.jar, ${stageName}/${stageName}*.jar.*.txt,${stageName}/${stageName}*.tar.gz.*.txt, ${stageName}/*.tar.gz.*sum*.txt, ${stageName}/${stageName}*.jar.html, ${stageName}/${stageName}*.jar.md, ${stageName}/${stageName}*.zip", followSymlinks: false } catch (Exception e) { slackSend channel: 'jenkins', color: 'danger', message: "${env.JOB_NAME} : #${env.BUILD_NUMBER} : ${stageName}() FAILED with following error message:\n${e}", teamDomain: 'adoptium' throw new Exception("[ERROR] ${stageName} FAILED\n${e}") diff --git a/tools/code-tools/jcov.sh b/tools/code-tools/jcov.sh index 30354ab58..fc8d0b3b2 100755 --- a/tools/code-tools/jcov.sh +++ b/tools/code-tools/jcov.sh @@ -91,6 +91,16 @@ function getJavatest() { sed "s/javatestjar.*/javatestjar=/g" -i build.properties fi fi + if [ ! -e testng.jar ] ; then + local testngv=6.9.10 + wget https://repo1.maven.org/maven2/org/testng/testng/$testngv/testng-$testngv.jar + mv testng-$testngv.jar testng.jar + fi + if [ ! -e jcommander.jar ] ; then + jcommanderv=1.81 + wget https://repo1.maven.org/maven2/com/beust/jcommander/$jcommanderv/jcommander-$jcommanderv.jar + mv jcommander-$jcommanderv.jar jcommander.jar + fi popd } @@ -134,6 +144,7 @@ pushd $REPO_DIR getAsmDeps "9.0" getJavatest pushd build + ant $ASM_PROPS test | tee ../$main_file-$tip_shortened.tar.gz.txt || true ant $ASM_PROPS build popd pushd $BUILD_PATH/jcov*/