-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathazure-pipelines.yml
More file actions
40 lines (34 loc) · 1.12 KB
/
azure-pipelines.yml
File metadata and controls
40 lines (34 loc) · 1.12 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
jobs:
- job: linux
pool:
vmImage: "ubuntu-latest"
variables:
CONDA_CACHE_DIR: /usr/share/miniconda/envs
steps:
- checkout: self
persistCredentials: "true"
- script: |
echo "##vso[task.prependpath]$CONDA/bin"
sudo chown -R $(whoami):$(id -ng) $(CONDA_CACHE_DIR)
displayName: Add conda to PATH
- task: Cache@2
displayName: Cache conda environment
inputs:
key: 'conda | "$(Agent.OS)" | environment.yaml'
restoreKeys: |
python | "$(Agent.OS)"
python
path: $(CONDA_CACHE_DIR)
cacheHitVar: CONDA_CACHE_RESTORED
- script: conda env create --quiet --file environment.yaml
displayName: Create conda environment
condition: eq(variables.CONDA_CACHE_RESTORED, 'false')
- script: |
source activate ntstat
meson setup --prefix=$CONDA_PREFIX build
meson install -C build
displayName: Compile project
- script: |
source activate ntstat
python -m unittest discover -s tests
displayName: Run tests