Skip to content

Commit a92f4bb

Browse files
Merge pull request RustPython#487 from liranringel/azure-pipelines
Add Windows CI via Azure Pipelines
2 parents 159daf0 + 9b71608 commit a92f4bb

File tree

2 files changed

+57
-1
lines changed

2 files changed

+57
-1
lines changed

azure-pipelines.yml

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
trigger:
2+
- master
3+
4+
jobs:
5+
6+
- job: 'Test'
7+
pool:
8+
vmImage: 'vs2017-win2016'
9+
strategy:
10+
matrix:
11+
Python37:
12+
python.version: '3.7'
13+
maxParallel: 10
14+
15+
steps:
16+
- task: UsePythonVersion@0
17+
inputs:
18+
versionSpec: '$(python.version)'
19+
architecture: 'x64'
20+
21+
- script: |
22+
"C:\Program Files\Git\mingw64\bin\curl.exe" -sSf -o rustup-init.exe https://win.rustup.rs/
23+
.\rustup-init.exe -y
24+
set PATH=%PATH%;%USERPROFILE%\.cargo\bin
25+
rustc -V
26+
cargo -V
27+
displayName: 'Installing Rust'
28+
29+
- script: |
30+
set PATH=%PATH%;%USERPROFILE%\.cargo\bin
31+
cargo build --verbose --all
32+
displayName: 'Build'
33+
34+
- script: |
35+
set PATH=%PATH%;%USERPROFILE%\.cargo\bin
36+
cargo test --verbose --all
37+
displayName: 'Run tests'
38+
39+
- script: |
40+
pip install pipenv
41+
pushd tests
42+
pipenv install
43+
popd
44+
displayName: 'Install pipenv and python packages'
45+
46+
- script: |
47+
set PATH=%PATH%;%USERPROFILE%\.cargo\bin
48+
cargo build --verbose --release
49+
displayName: 'Build release'
50+
51+
- script: |
52+
set PATH=%PATH%;%USERPROFILE%\.cargo\bin
53+
pushd tests
54+
pipenv run pytest
55+
popd
56+
displayName: 'Run snippet tests'

tests/snippets/os_info.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
import os
22

3-
assert os.name == 'posix'
3+
assert os.name == 'posix' or os.name == 'nt'

0 commit comments

Comments
 (0)