1+ name : CI
2+
3+ on :
4+ push :
5+ branches :
6+ - ' **'
7+ pull_request :
8+
9+ # A workflow run is made up of one or more jobs that can run sequentially or in parallel
10+ jobs :
11+ # This workflow contains a single job called "build"
12+ build :
13+ # The type of runner that the job will run on
14+ runs-on : ${{ matrix.os }}
15+ strategy :
16+ fail-fast : false
17+ matrix :
18+ os : [macos-latest, ubuntu-latest, windows-latest]
19+ python-version : [3.6, 3.7, 3.8, 3.9]
20+
21+ if : " !contains(github.event.head_commit.message, 'ci skip')"
22+
23+ # Steps represent a sequence of tasks that will be executed as part of the job
24+ steps :
25+ - name : Checkout
26+ uses : actions/checkout@v2
27+
28+ - name : Set up Python ${{ matrix.python-version }}
29+ uses : actions/setup-python@v2
30+ with :
31+ python-version : ${{ matrix.python-version }}
32+
33+ - name : Set up conda
34+ # if: ${{ matrix.os == 'ubuntu-latest' && matrix.python-version == '3.6' }}
35+ if : ${{ matrix.os != 'windows-latest' }}
36+ uses : s-weigand/setup-conda@v1
37+ with :
38+ python-version : ${{ matrix.python-version}}
39+
40+ - name : Install dependencies for Unix
41+ if : ${{ matrix.os != 'windows-latest' }}
42+ run : |
43+ pip3 install -U scikit-build
44+ pip3 install -U awscli pip pytest coverage codecov
45+
46+ - name : Install dependencies for Windows
47+ if : ${{ matrix.os == 'windows-latest' }}
48+ run : |
49+ pip3 install -U scikit-build --user
50+ pip3 install -U awscli pip pytest coverage codecov --user
51+
52+ - name : Build and install
53+ run : python3 setup.py install
54+
55+ - name : Run unittest
56+ env :
57+ KMP_DUPLICATE_LIB_OK : " TRUE"
58+ OBJC_DISABLE_INITIALIZE_FORK_SAFETY : " YES"
59+ run : |
60+ python3 -m coverage run -m pytest -s --log-cli-level=DEBUG
61+ echo "Done test. Start combining coverage report"
62+ python3 -m coverage combine
63+ echo "Done combine coverage report. Showing it out"
64+ python3 -m coverage report
65+
66+ - name : Upload coverage report
67+ run : codecov
0 commit comments