File tree 1 file changed +62
-0
lines changed
1 file changed +62
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : install-test
2
+
3
+ on :
4
+ push :
5
+ branches :
6
+ - master
7
+ tags :
8
+ - ' *'
9
+ pull_request :
10
+ branches :
11
+ - master
12
+ schedule :
13
+ # 7am EST / 8am EDT Mondays
14
+ - cron : ' 0 12 * * 1'
15
+
16
+ jobs :
17
+ test :
18
+ runs-on : ubuntu-latest
19
+ strategy :
20
+ matrix :
21
+ python-version : [3.7, 3.8, 3.9, 3.10]
22
+ install : [repo]
23
+ pip-flags : ['', '--pre']
24
+ include :
25
+ - python-version : 3.9
26
+ install : sdist
27
+ pip-flags : ' '
28
+ - python-version : 3.9
29
+ install : wheel
30
+ pip-flags : ' '
31
+ - python-version : 3.9
32
+ install : editable
33
+ pip-flags : ' '
34
+
35
+ env :
36
+ INSTALL_TYPE : ${{ matrix.install }}
37
+ PIP_FLAGS : ${{ matrix.pip-flags }}
38
+
39
+ steps :
40
+ - uses : actions/checkout@v3
41
+ with :
42
+ fetch-depth : 0
43
+ - name : Set up Python ${{ matrix.python-version }}
44
+ uses : actions/setup-python@v3
45
+ with :
46
+ python-version : ${{ matrix.python-version }}
47
+ - name : Select archive
48
+ run : |
49
+ if [ "$INSTALL_TYPE" = "sdist" ]; then
50
+ ARCHIVE=$( ls dist/*.tar.gz )
51
+ elif [ "$INSTALL_TYPE" = "wheel" ]; then
52
+ ARCHIVE=$( ls dist/*.whl )
53
+ elif [ "$INSTALL_TYPE" = "repo" ]; then
54
+ ARCHIVE="."
55
+ elif [ "$INSTALL_TYPE" = "editable" ]; then
56
+ ARCHIVE="-e ."
57
+ fi
58
+ echo "ARCHIVE=$ARCHIVE" >> $GITHUB_ENV
59
+ - name : Install package and test dependencies
60
+ run : python -m pip install $PIP_FLAGS $ARCHIVE[test]
61
+ - name : Run tests
62
+ run : python -m pytest -sv --doctest-modules etelemetry
You can’t perform that action at this time.
0 commit comments