summaryrefslogtreecommitdiff
path: root/netci.groovy
diff options
context:
space:
mode:
authorMichelle McDaniel <adiaaida@gmail.com>2016-08-25 11:27:17 -0700
committerMichelle McDaniel <adiaaida@gmail.com>2016-08-25 15:29:37 -0700
commitc7868f2b57bedf2e24475cd30ebea5535b69e12d (patch)
treeba5521e41a7dd44832ae9466906c346a684e4e72 /netci.groovy
parentcace8ca2ab09601c06ba382552c5a772536d7908 (diff)
downloadcoreclr-c7868f2b57bedf2e24475cd30ebea5535b69e12d.tar.gz
coreclr-c7868f2b57bedf2e24475cd30ebea5535b69e12d.tar.bz2
coreclr-c7868f2b57bedf2e24475cd30ebea5535b69e12d.zip
Move groovy logic to python script
Diffstat (limited to 'netci.groovy')
-rwxr-xr-xnetci.groovy78
1 files changed, 8 insertions, 70 deletions
diff --git a/netci.groovy b/netci.groovy
index dda99118ed..f083400354 100755
--- a/netci.groovy
+++ b/netci.groovy
@@ -556,7 +556,7 @@ def static addTriggers(def job, def branch, def isPR, def architecture, def os,
if (scenario == 'formatting') {
assert configuration == 'Checked'
if (os == 'Windows_NT' || os == 'Ubuntu') {
- Utilities.addGithubPRTriggerForBranch(job, branch, "${os} ${architecture} Formatting Build & Test", "(?i).*test\\W+formatting.*")
+ Utilities.addGithubPRTriggerForBranch(job, branch, "${os} ${architecture} Formatting", "(?i).*test\\W+${os}\\W+formatting.*")
}
break
}
@@ -1476,7 +1476,9 @@ combinedScenarios.each { scenario ->
if (configuration != 'Checked') {
return
}
- println("Formatting not skipped: ${os} ${architecture} ${configuration}")
+ if (isBuildOnly) {
+ return
+ }
break
case 'default':
// Nothing skipped
@@ -1544,35 +1546,7 @@ combinedScenarios.each { scenario ->
buildCommands += "set __TestIntermediateDir=int&&build-test.cmd ${lowerConfiguration} ${arch}"
}
else if (scenario == 'formatting') {
- // Build with NMake Makefiles for all configurations
- buildCommands += "set __TestIntermediateDir=int&&build.cmd Debug ${arch} usenmakemakefiles"
- buildCommands += "set __TestIntermediateDir=int&&build.cmd Checked ${arch} usenmakemakefiles"
- buildCommands += "set __TestIntermediateDir=int&&build.cmd Release ${arch} usenmakemakefiles"
-
- // Download jitutils
- def url = "https://raw.githubusercontent.com/dotnet/jitutils/master/bootstrap.cmd"
- def outfile = "bootstrap.cmd"
- buildCommands += "powershell Invoke-WebRequest -Uri ${url} -OutFile ${outfile}"
-
- // Install x64 dotnet cli version 1.0.0.0
- def dotnetcliUrl = "https://go.microsoft.com/fwlink/?LinkID=809115"
- buildCommands += "mkdir Tools\\dotnetcli-jitutils&&powershell -Command \"Invoke-WebRequest -Uri ${dotnetcliUrl} -OutFile Tools\\dotnetcli-jitutils\\dotnetcli-jitutils.zip; Add-Type -Assembly 'System.IO.Compression.FileSystem'; [System.IO.Compression.ZipFile]::ExtractToDirectory(Tools\\dotnetcli-jitutils\\dotnetcli-jitutils.zip, Tools\\dotnetcli-jitutils)\""
-
- // Run bootstrap script
- buildCommands += "set PATH=%PATH%;%WORKSPACE%\\Tools\\dotnetcli-jitutils&&bootstrap.cmd"
-
- // run jit-format
- buildCommands += "set PATH=%PATH%;%WORKSPACE%\\Tools\\dotnetcli-jitutils;%WORKSPACE%\\jitutils\\bin&&jit-format.cmd -a ${arch} -b Checked -o Windows_NT -c %WORKSPACE% --verbose --projects dll"
- buildCommands += "set PATH=%PATH%;%WORKSPACE%\\Tools\\dotnetcli-jitutils;%WORKSPACE%\\jitutils\\bin&&jit-format.cmd -a ${arch} -b Checked -o Windows_NT -c %WORKSPACE% --verbose --projects standalone"
- buildCommands += "set PATH=%PATH%;%WORKSPACE%\\Tools\\dotnetcli-jitutils;%WORKSPACE%\\jitutils\\bin&&jit-format.cmd -a ${arch} -b Checked -o Windows_NT -c %WORKSPACE% --verbose --projects crossgen"
-
- buildCommands += "set PATH=%PATH%;%WORKSPACE%\\Tools\\dotnetcli-jitutils;%WORKSPACE%\\jitutils\\bin&&jit-format.cmd -a ${arch} -b Debug -o Windows_NT -c %WORKSPACE% --verbose --projects dll"
- buildCommands += "set PATH=%PATH%;%WORKSPACE%\\Tools\\dotnetcli-jitutils;%WORKSPACE%\\jitutils\\bin&&jit-format.cmd -a ${arch} -b Debug -o Windows_NT -c %WORKSPACE% --verbose --projects standalone"
- buildCommands += "set PATH=%PATH%;%WORKSPACE%\\Tools\\dotnetcli-jitutils;%WORKSPACE%\\jitutils\\bin&&jit-format.cmd -a ${arch} -b Debug -o Windows_NT -c %WORKSPACE% --verbose --projects crossgen"
-
- buildCommands += "set PATH=%PATH%;%WORKSPACE%\\Tools\\dotnetcli-jitutils;%WORKSPACE%\\jitutils\\bin&&jit-format.cmd -a ${arch} -b Release -o Windows_NT -c %WORKSPACE% --verbose --projects dll"
- buildCommands += "set PATH=%PATH%;%WORKSPACE%\\Tools\\dotnetcli-jitutils;%WORKSPACE%\\jitutils\\bin&&jit-format.cmd -a ${arch} -b Release -o Windows_NT -c %WORKSPACE% --verbose --projects standalone"
- buildCommands += "set PATH=%PATH%;%WORKSPACE%\\Tools\\dotnetcli-jitutils;%WORKSPACE%\\jitutils\\bin&&jit-format.cmd -a ${arch} -b Release -o Windows_NT -c %WORKSPACE% --verbose --projects crossgen"
+ buildCommands += "python tests\\scripts\\format.py -c %WORKSPACE% -o Windows_NT -a ${arch}"
break
}
else {
@@ -1583,7 +1557,7 @@ combinedScenarios.each { scenario ->
// If we are running a stress mode, we should write out the set of key
// value env pairs to a file at this point and then we'll pass that to runtest.cmd
- if (!isBuildOnly && scenario != 'formatting') {
+ if (!isBuildOnly) {
//If this is a crossgen build, pass 'crossgen' to runtest.cmd
def crossgenStr = ''
def runcrossgentestsStr = ''
@@ -1765,36 +1739,7 @@ combinedScenarios.each { scenario ->
}
if (scenario == 'formatting') {
- // configure all of the configurations
- buildCommands += "./build.sh verbose configureonly release x64"
- buildCommands += "./build.sh verbose configureonly checked x64"
- buildCommands += "./build.sh verbose configureonly debug x64"
-
- // install correct version of dotnet cli
- def dotnetCliUrl = "https://go.microsoft.com/fwlink/?LinkID=809118"
- def dotnetCliTar = "dotnetcli.tar"
- def dotnetCliPath = "\${WORKSPACE}/Tools/dotnetcli-jitutils"
- buildCommands += "wget --trust-server-names ${dotnetCliUrl} -O ${dotnetCliTar}.gz; gunzip ${dotnetCliTar}.gz; mkdir ${dotnetCliPath}; tar -xf ${dotnetCliTar} -C ${dotnetCliPath}"
-
- // get and run bootstrap script
- def url = "https://raw.githubusercontent.com/dotnet/jitutils/master/bootstrap.sh"
- buildCommands += "wget ${url}"
- buildCommands += "chmod 751 bootstrap.sh"
- buildCommands += "export PATH=\${PATH}:${dotnetCliPath}; ./bootstrap.sh"
- def jitutilsPath = "\${WORKSPACE}/jitutils/bin"
-
- // run jit-format
- buildCommands += "export PATH=\${PATH}:${dotnetCliPath}:${jitutilsPath}&&jit-format -a ${arch} -b Checked -o Linux -c \${WORKSPACE} --verbose --projects dll"
- buildCommands += "export PATH=\${PATH}:${dotnetCliPath}:${jitutilsPath}&&jit-format -a ${arch} -b Checked -o Linux -c \${WORKSPACE} --verbose --projects standalone"
- buildCommands += "export PATH=\${PATH}:${dotnetCliPath}:${jitutilsPath}&&jit-format -a ${arch} -b Checked -o Linux -c \${WORKSPACE} --verbose --projects crossgen"
-
- buildCommands += "export PATH=\${PATH}:${dotnetCliPath}:${jitutilsPath}&&jit-format -a ${arch} -b Debug -o Linux -c \${WORKSPACE} --verbose --projects dll"
- buildCommands += "export PATH=\${PATH}:${dotnetCliPath}:${jitutilsPath}&&jit-format -a ${arch} -b Debug -o Linux -c \${WORKSPACE} --verbose --projects standalone"
- buildCommands += "export PATH=\${PATH}:${dotnetCliPath}:${jitutilsPath}&&jit-format -a ${arch} -b Debug -o Linux -c \${WORKSPACE} --verbose --projects crossgen"
-
- buildCommands += "export PATH=\${PATH}:${dotnetCliPath}:${jitutilsPath}&&jit-format -a ${arch} -b Release -o Linux -c \${WORKSPACE} --verbose --projects dll"
- buildCommands += "export PATH=\${PATH}:${dotnetCliPath}:${jitutilsPath}&&jit-format -a ${arch} -b Release -o Linux -c \${WORKSPACE} --verbose --projects standalone"
- buildCommands += "export PATH=\${PATH}:${dotnetCliPath}:${jitutilsPath}&&jit-format -a ${arch} -b Release -o Linux -c \${WORKSPACE} --verbose --projects crossgen"
+ buildCommands += "python tests/scripts/format.py -c \${WORKSPACE} -o Linux -a ${arch}"
break
}
@@ -2065,14 +2010,7 @@ combinedScenarios.each { scenario ->
return
}
case 'formatting':
- // We only want Ubuntu Checked for formatting
- if (os != 'Ubuntu') {
- return
- }
- if (configuration != 'Checked') {
- return
- }
- break
+ return
case 'default':
// Nothing skipped
break