-
Notifications
You must be signed in to change notification settings - Fork 9
61 lines (55 loc) · 1.87 KB
/
windows_conda_testing.yaml
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
name: Windows Testing
on: [push]
jobs:
build:
runs-on: windows-latest
strategy:
matrix:
# Apparently 3.10 gets converted to 3.1 if it's not a string. Brilliant.
python-version: [3.8]
steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: 3.8
- name: Install dependencies
run: |
python --version
C:\Miniconda\condabin\conda.bat env update --file environment.yml --name base
python --version
C:\Miniconda\condabin\conda.bat init powershell
python --version
- name: Lint with flake8
uses: actions/setup-python@v2
with:
python-version: 3.8
run: |
# Activate the base environment
python --version
C:\Miniconda\condabin\conda.bat activate base
python --version
C:\Miniconda\condabin\conda.bat install flake8
python --version
# stop the build if there are Python syntax errors or undefined names
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
python --version
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
python --version
- name: Test with pytest
uses: actions/setup-python@v2
with:
python-version: 3.8
run: |
# Activate the base environment
python --version
C:\Miniconda\condabin\conda.bat activate base
python --version
C:\Miniconda\condabin\conda.bat install pytest pytest-cov coverage mock pip
python --version
C:\Miniconda\condabin\conda.bat install -c conda-forge shapely
python --version
pip install --upgrade pip
pip install -r requirements.txt
py.test