mirror of
https://github.com/enso-org/enso.git
synced 2024-11-27 06:03:23 +03:00
555bd8eebb
This PR adds additional step that fails the pipeline if there were issues encountered. Currently test and benchmark steps in the CI pipeline do not stop the run on failure. This is desirable but led to builds being recognized by github as successful even if they shouldn't.
113 lines
3.3 KiB
YAML
113 lines
3.3 KiB
YAML
# https://aka.ms/yaml
|
|
|
|
trigger:
|
|
branches:
|
|
include: [ "*" ]
|
|
paths:
|
|
exclude:
|
|
- .github/*
|
|
- doc/*
|
|
- .gitignore
|
|
- .scalafmt.conf
|
|
- CODE_OF_CONDUCT.md
|
|
- CONTRIBUTING.md
|
|
- LICENSE
|
|
- README.md
|
|
|
|
pr: none
|
|
|
|
jobs:
|
|
- job: Linux
|
|
pool:
|
|
vmImage: 'Ubuntu-16.04'
|
|
container:
|
|
image: oracle/graalvm-ce:19.0.0
|
|
options: "--name ci-container -v /usr/bin/docker:/tmp/docker:ro"
|
|
steps:
|
|
- script: /tmp/docker exec -t -u 0 ci-container sh -c "yum install -y sudo"
|
|
displayName: Setup sudo
|
|
- script: |
|
|
curl https://bintray.com/sbt/rpm/rpm | sudo tee /etc/yum.repos.d/bintray-sbt-rpm.repo
|
|
sudo yum install -y sbt
|
|
displayName: "Install sbt"
|
|
- script: |
|
|
sbt -no-colors test
|
|
displayName: sbt test
|
|
continueOnError: true
|
|
- script: |
|
|
sbt -no-colors bench
|
|
displayName: sbt bench
|
|
continueOnError: true
|
|
- task: PublishTestResults@2
|
|
inputs:
|
|
testResultsFormat: 'JUnit'
|
|
testResultsFiles: '**/TEST-*.xml'
|
|
- script: |
|
|
echo "##vso[task.complete result=Failed;]DONE"
|
|
condition: eq(variables['Agent.JobStatus'], 'SucceededWithIssues')
|
|
displayName: "Fail if there were issues"
|
|
- job: macOS
|
|
pool:
|
|
vmImage: macOS-10.13
|
|
steps:
|
|
- script: |
|
|
curl -fSL -o graal.tar.gz https://github.com/oracle/graal/releases/download/vm-19.1.0/graalvm-ce-darwin-amd64-19.1.0.tar.gz
|
|
tar -x -z -C ~ -f graal.tar.gz
|
|
ls ~/graalvm-ce-19.1.0
|
|
sudo mv ~/graalvm-ce-19.1.0 /Library/Java/JavaVirtualMachines
|
|
echo "##vso[task.setvariable variable=JAVA_HOME]/Library/Java/JavaVirtualMachines/graalvm-ce-19.1.0/Contents/Home"
|
|
echo "##vso[task.setvariable variable=PATH]/Library/Java/JavaVirtualMachines/graalvm-ce-19.1.0/Contents/Home/bin:$PATH"
|
|
displayName: Install GraalVM
|
|
- script: |
|
|
brew update
|
|
brew install sbt
|
|
displayName: Install sbt
|
|
- script: |
|
|
sbt -no-colors test
|
|
displayName: sbt test
|
|
continueOnError: true
|
|
- script: |
|
|
sbt -no-colors bench
|
|
displayName: sbt bench
|
|
continueOnError: true
|
|
- task: PublishTestResults@2
|
|
inputs:
|
|
testResultsFormat: 'JUnit'
|
|
testResultsFiles: '**/TEST-*.xml'
|
|
- script: |
|
|
echo "##vso[task.complete result=Failed;]DONE"
|
|
condition: eq(variables['Agent.JobStatus'], 'SucceededWithIssues')
|
|
displayName: "Fail if there were issues"
|
|
- job: Windows
|
|
pool:
|
|
vmImage: windows-2019
|
|
steps:
|
|
- script: |
|
|
curl -fSL -o graal.zip https://github.com/oracle/graal/releases/download/vm-19.0.0/graalvm-ce-windows-amd64-19.0.0.zip
|
|
7z x -y -oC:\ graal.zip
|
|
displayName: "Install GraalVM"
|
|
- script: |
|
|
choco install -y sbt
|
|
displayName: "Install sbt"
|
|
- script: |
|
|
call refreshenv
|
|
echo ##vso[task.setvariable variable=JAVA_HOME]C:\graalvm-ce-19.0.0
|
|
echo ##vso[task.setvariable variable=PATH]C:\graalvm-ce-19.0.0\bin;%PATH%
|
|
displayName: "Adjust environment variables"
|
|
- script: |
|
|
sbt test
|
|
continueOnError: true
|
|
displayName: "sbt test"
|
|
- script: |
|
|
sbt bench
|
|
continueOnError: true
|
|
displayName: "sbt bench"
|
|
- task: PublishTestResults@2
|
|
inputs:
|
|
testResultsFormat: 'JUnit'
|
|
testResultsFiles: '**/TEST-*.xml'
|
|
- script: |
|
|
echo "##vso[task.complete result=Failed;]DONE"
|
|
condition: eq(variables['Agent.JobStatus'], 'SucceededWithIssues')
|
|
displayName: "Fail if there were issues"
|