1
0
mirror of https://github.com/Llewellynvdm/starship.git synced 2024-11-09 14:51:04 +00:00
starship/azure-pipelines.yml

73 lines
2.0 KiB
YAML
Raw Normal View History

2019-04-04 03:33:19 +00:00
jobs:
# Run the Rust linter
2019-04-04 03:33:19 +00:00
- job: "Clippy"
pool:
vmImage: "ubuntu-16.04"
container: "rust:latest"
steps:
- script: rustup component add clippy
displayName: Install Clippy
- script: cargo clippy --all
displayName: Run clippy
# Run the Rust formatter
2019-04-04 03:33:19 +00:00
- job: "Rustfmt"
pool:
vmImage: "ubuntu-16.04"
container: "rust:latest"
condition: eq(variables['Build.Reason'], 'PullRequest')
steps:
- script: rustup component add rustfmt
displayName: Install Rustfmt
- script: cargo fmt --all -- --check
displayName: Run Rustfmt
# Run the integration tests in a Docker container
- job: "Docker"
pool:
vmImage: "ubuntu-16.04"
steps:
- script: ./integration_test
displayName: Dockerized tests
# Run the integration tests on virtual machines
2019-04-04 03:33:19 +00:00
- job: "Test"
strategy:
matrix:
windows-stable:
imageName: "vs2017-win2016"
rustup_toolchain: stable
mac-stable:
imageName: "macos-10.13"
rustup_toolchain: stable
linux-stable:
imageName: "ubuntu-16.04"
rustup_toolchain: stable
linux-beta:
imageName: "ubuntu-16.04"
rustup_toolchain: beta
linux-nightly:
imageName: "ubuntu-16.04"
rustup_toolchain: nightly
pool:
vmImage: "ubuntu-16.04"
steps:
# Install Node.js
- task: NodeTool@0
2019-04-28 17:34:46 +00:00
inputs:
versionSpec: "12.0.0"
2019-05-12 03:58:45 +00:00
# Install Go
- task: GoTool@0
inputs:
versionSpec: "1.10"
# Install Rust at a fixed version for integration tests
- template: ".build/install-rust.yml"
parameters:
versionSpec: "1.34.0"
# Because integration tests rely on a fixed Rust version, we must use rustup to run with the intended toolkit
- script: rustup run $RUSTUP_TOOLCHAIN cargo build --all
2019-04-04 03:33:19 +00:00
displayName: Cargo build
- script: rustup run $RUSTUP_TOOLCHAIN cargo test -- --ignored
2019-04-04 03:33:19 +00:00
displayName: Cargo test