Skip to content
This repository was archived by the owner on Jan 23, 2023. It is now read-only.

Commit 96b978c

Browse files
author
Prajwal A N
committed
ARM-CI: Add tests to CI script
Previously we just built coreclr for the emulator rootfs With this PR, we add the ability to perform selected tests using the built binaries in the emulated environment We copy artifacts from the Windows build only job and the corefx Linux ARM Emulator job and use the same to run the build and the test Signed-off-by: Prajwal A N <[email protected]>
1 parent c3e09ed commit 96b978c

File tree

2 files changed

+429
-33
lines changed

2 files changed

+429
-33
lines changed

netci.groovy

Lines changed: 45 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1768,11 +1768,24 @@ combinedScenarios.each { scenario ->
17681768
def armemul_path = '/opt/linux-arm-emulator'
17691769
def armrootfs_mountpath = '/opt/linux-arm-emulator-root'
17701770

1771-
// Call the ARM emulator build script to cross build using the ARM emulator rootfs
1772-
buildCommands += "./tests/scripts/arm32_ci_script.sh --emulatorPath=${armemul_path} --mountPath=${armrootfs_mountpath} --buildConfig=${lowerConfiguration}"
1771+
// Unzip the Windows test binaries first. Exit with 0
1772+
buildCommands += "unzip -q -o ./bin/tests/tests.zip -d ./bin/tests/Windows_NT.x64.${configuration} || exit 0"
17731773

1774+
// Unpack the corefx binaries
1775+
buildCommands += "tar -xf ./bin/build.tar.gz"
17741776

1775-
// Basic archiving of the build, no pal tests
1777+
// Call the ARM emulator build script to cross build and test using the ARM emulator rootfs
1778+
buildCommands += """./tests/scripts/arm32_ci_script.sh \\
1779+
--emulatorPath=${armemul_path} \\
1780+
--mountPath=${armrootfs_mountpath} \\
1781+
--buildConfig=${lowerConfiguration} \\
1782+
--testRootDir=./bin/tests/Windows_NT.x64.${configuration} \\
1783+
--coreFxNativeBinDir=./bin/Linux.arm-softfp.${configuration} \\
1784+
--coreFxBinDir=\"./bin/Linux.AnyCPU.${configuration};./bin/Unix.AnyCPU.${configuration};./bin/AnyOS.AnyCPU.${configuration}\" \\
1785+
--testDirFile=./tests/testsRunningInsideARM.txt"""
1786+
1787+
1788+
// Basic archiving of the build
17761789
Utilities.addArchival(newJob, "bin/Product/**")
17771790
break
17781791
}
@@ -1796,6 +1809,35 @@ combinedScenarios.each { scenario ->
17961809
}
17971810
}
17981811
else {
1812+
// Setup corefx and Windows test binaries for Linux ARM Emulator Build
1813+
if (isLinuxEmulatorBuild) {
1814+
// Define the Windows Tests and Corefx build job names
1815+
def WindowTestsName = projectFolder + '/' +
1816+
Utilities.getFullJobName(project,
1817+
getJobName(lowerConfiguration,
1818+
'x64' ,
1819+
'windows_nt',
1820+
'default',
1821+
true),
1822+
false)
1823+
def corefxFolder = Utilities.getFolderName('dotnet/corefx') + '/' +
1824+
Utilities.getFolderName(branch)
1825+
1826+
// Copy the Windows test binaries and the Corefx build binaries
1827+
copyArtifacts(WindowTestsName) {
1828+
excludePatterns('**/testResults.xml', '**/*.ni.dll')
1829+
buildSelector {
1830+
latestSuccessful(true)
1831+
}
1832+
}
1833+
copyArtifacts("${corefxFolder}/linuxarmemulator_cross_${lowerConfiguration}") {
1834+
includePatterns('bin/build.tar.gz')
1835+
buildSelector {
1836+
latestSuccessful(true)
1837+
}
1838+
}
1839+
}
1840+
17991841
buildCommands.each { buildCommand ->
18001842
shell(buildCommand)
18011843
}

0 commit comments

Comments
 (0)