Skip to content
Permalink
Browse files

Execute OE12 unit tests with Ant 1.10 and Corretto 8

  • Loading branch information...
gquerret committed Jun 14, 2019
1 parent 25f0321 commit adb1203e5dec55cb0536179ec7518df1ed8cf2f1
Showing with 21 additions and 16 deletions.
  1. +17 −15 Jenkinsfile
  2. +0 −1 build.xml
  3. +4 −0 tests.xml
@@ -32,21 +32,22 @@ stage('Standard build') {
withEnv(["TERM=xterm", "JAVA_HOME=${jdk}"]) {
sh "${antHome}/bin/ant -DDLC10=${dlc10} -DDLC10-64=${dlc10_64} -DDLC11=${dlc11} -DDLC12=${dlc12} -DGIT_COMMIT=${commit} dist"
}
stash name: 'tests', includes: 'dist/testcases.zip,tests.xml'
stash name: 'tests', includes: 'dist/PCT.jar,dist/testcases.zip,tests.xml'
archiveArtifacts 'dist/PCT.jar,dist/PCT-javadoc.jar,dist/PCT-sources.jar'
}
}

stage('Full tests') {
parallel branch1: { testBranch('windows', 'OpenEdge-10.2B', false, '10.2-Win', 10, 32) },
branch2: { testBranch('windows', 'OpenEdge-11.7', true, '11.7-Win', 11, 32) },
branch3: { testBranch('linux', 'OpenEdge-10.2B-64b', false, '10.2-64-Linux', 10, 64) },
branch4: { testBranch('linux', 'OpenEdge-11.6', false, '11.6-Linux', 11, 64) },
branch5: { testBranch('linux', 'OpenEdge-11.7', false, '11.7-Linux', 11, 64) },
branch6: { testBranch('linux', 'OpenEdge-10.2B', false, '10.2-Linux', 10, 32) },
branch7: { testBranch('linux', 'OpenEdge-12.0', false, '12.0-Linux', 12, 64) },
branch8: { testBranch('windows', 'OpenEdge-12.0', true, '12.0-Win', 12, 64) },
failFast: false
parallel branch1: { testBranch('windows', 'JDK8', 'Ant 1.9', 'OpenEdge-10.2B', false, '10.2-Win') },
branch2: { testBranch('windows', 'JDK8', 'Ant 1.9', 'OpenEdge-11.7', true, '11.7-Win') },
branch3: { testBranch('linux', 'JDK8', 'Ant 1.9', 'OpenEdge-10.2B-64b', false, '10.2-64-Linux') },
branch4: { testBranch('linux', 'JDK8', 'Ant 1.9', 'OpenEdge-11.6', false, '11.6-Linux') },
branch5: { testBranch('linux', 'JDK8', 'Ant 1.9', 'OpenEdge-11.7', false, '11.7-Linux') },
branch6: { testBranch('linux', 'JDK8', 'Ant 1.9', 'OpenEdge-10.2B', false, '10.2-Linux') },
branch7: { testBranch('linux', 'Corretto 8', 'Ant 1.10', 'OpenEdge-12.0', false, '12.0-Linux') },
branch8: { testBranch('windows', 'Corretto 8', 'Ant 1.10', 'OpenEdge-12.0', true, '12.0-Win') },
failFast: false

node('linux') {
// Wildcards not accepted in unstash...
unstash name: 'junit-10.2-Win'
@@ -57,6 +58,7 @@ stage('Full tests') {
unstash name: 'junit-11.7-Linux'
unstash name: 'junit-12.0-Linux'
unstash name: 'junit-12.0-Win'

sh "mkdir junitreports"
unzip zipFile: 'junitreports-10.2-Win.zip', dir: 'junitreports'
unzip zipFile: 'junitreports-11.7-Win.zip', dir: 'junitreports'
@@ -82,19 +84,19 @@ stage('Sonar') {
}
}

def testBranch(nodeName, dlcVersion, stashCoverage, label, majorVersion, arch) {
def testBranch(nodeName, jdkVersion, antVersion, dlcVersion, stashCoverage, label) {
node(nodeName) {
ws {
deleteDir()
def dlc = tool name: dlcVersion, type: 'openedge'
def jdk = tool name: 'JDK8', type: 'jdk'
def antHome = tool name: 'Ant 1.9', type: 'ant'
def jdk = tool name: jdkVersion, type: 'jdk'
def antHome = tool name: antVersion, type: 'ant'
unstash name: 'tests'
withEnv(["TERM=xterm", "JAVA_HOME=${jdk}"]) {
if (isUnix())
sh "${antHome}/bin/ant -DDLC=${dlc} -DPROFILER=true -DTESTENV=${label} -DOE_MAJOR_VERSION=${majorVersion} -DOE_ARCH=${arch} -f tests.xml init dist"
sh "${antHome}/bin/ant -lib dist/PCT.jar -DDLC=${dlc} -DPROFILER=true -DTESTENV=${label} -f tests.xml init dist"
else
bat "${antHome}/bin/ant -DDLC=${dlc} -DPROFILER=true -DTESTENV=${label} -DOE_MAJOR_VERSION=${majorVersion} -DOE_ARCH=${arch} -f tests.xml init dist"
bat "${antHome}/bin/ant -lib dist/PCT.jar -DDLC=${dlc} -DPROFILER=true -DTESTENV=${label} -f tests.xml init dist"
}
stash name: "junit-${label}", includes: 'junitreports-*.zip'
archiveArtifacts 'emailable-report-*.html'
@@ -405,7 +405,6 @@
<zipfileset dir="tests" includes="**/*" prefix="testbox" />
<zipfileset dir="${src.progress}" includes="Consultingwerk/**/*" prefix="testbox/ClassDocumentation/test3/src" />
<zipfileset dir="lib" includes="ast.jar,ast-dependencies.jar,ini4j-0.5.1.jar,guava.jar,testng-6.13.1.jar,jcommander-1.30.jar,jacocoant-0.8.4.jar,*.pl" prefix="lib" />
<zipfileset dir="${dist}" includes="PCT.jar" prefix="dist" />
</zip>
</target>

@@ -7,6 +7,10 @@
<property name="PROFILER" value="false" />
<property name="TESTLIBS" value="${basedir}/lib" />

<!-- Only used for OE version number -->
<taskdef resource="PCT.properties" />
<ProgressVersion dlcHome="${DLC}" majorVersion="OE_MAJOR_VERSION" minorVersion="OE_MINOR_VERSION" bitness="OE_ARCH" />

<!-- Assume version 11 when in local development -->
<condition property="GROUPS" value="v10,v11">
<not><isset property="OE_MAJOR_VERSION" /></not>

0 comments on commit adb1203

Please sign in to comment.
You can’t perform that action at this time.