File tree 10 files changed +142
-0
lines changed
10 files changed +142
-0
lines changed Original file line number Diff line number Diff line change
1
+ coverage :
2
+ status :
3
+ patch :
4
+ default :
5
+ target : ' 100'
6
+ project :
7
+ default :
8
+ target : ' 88'
Original file line number Diff line number Diff line change
1
+ [run]
2
+ source =
3
+ smithy_python
4
+
5
+ [report]
6
+ exclude_lines =
7
+ raise NotImplementedError
Original file line number Diff line number Diff line change
1
+ name : CI
2
+
3
+ on :
4
+ push :
5
+ branches : develop
6
+ pull_request :
7
+ branches : develop
8
+
9
+ jobs :
10
+ test :
11
+ runs-on : ubuntu-latest
12
+
13
+ strategy :
14
+ fail-fast : false
15
+ matrix :
16
+ python-version : [3.6, 3.7, 3.8]
17
+
18
+ steps :
19
+ - name : Checkout Repository
20
+ uses : actions/checkout@v1
21
+ - name : Set Up Python - ${{ matrix.python-version }}
22
+ uses : actions/setup-python@v1
23
+ with :
24
+ python-version : ${{ matrix.python-version }}
25
+ - name : Install tox
26
+ run : |
27
+ python${{ matrix.python-version }} -m pip install --upgrade tox
28
+ - name : Run tests
29
+ run : |
30
+ tox -e py
31
+ - name : Upload coverage
32
+ if : matrix.python-version == 3.7
33
+ uses : codecov/codecov-action@v1
34
+ with :
35
+ token : ${{ secrets.CODECOV_TOKEN }}
36
+ file : ./coverage.xml
37
+ flags : unittests
38
+ name : codecov-umbrella
39
+ yml : ./codecov.yml
40
+ fail_ci_if_error : true
Original file line number Diff line number Diff line change
1
+ name : Lint
2
+
3
+ on :
4
+ push :
5
+ branches : develop
6
+ pull_request :
7
+ branches : develop
8
+
9
+ jobs :
10
+ black-and-flake8 :
11
+ runs-on : ubuntu-latest
12
+
13
+ steps :
14
+ - name : Checkout Repository
15
+ uses : actions/checkout@v1
16
+ - name : Set Up Python 3.7
17
+ uses : actions/setup-python@v1
18
+ with :
19
+ python-version : 3.7
20
+ - name : Install tox
21
+ run : |
22
+ python3.7 -m pip install tox
23
+ - name : Run linting
24
+ run : |
25
+ tox -e lint
Original file line number Diff line number Diff line change
1
+ name : Type Check
2
+
3
+ on :
4
+ push :
5
+ branches : develop
6
+ pull_request :
7
+ branches : develop
8
+
9
+ jobs :
10
+ mypy :
11
+ runs-on : ubuntu-latest
12
+
13
+ steps :
14
+ - name : Checkout Repository
15
+ uses : actions/checkout@v1
16
+ - name : Set Up Python 3.7
17
+ uses : actions/setup-python@v1
18
+ with :
19
+ python-version : 3.7
20
+ - name : Install tox
21
+ run : |
22
+ python3.7 -m pip install tox
23
+ - name : Run type checks
24
+ run : |
25
+ tox -e type
Original file line number Diff line number Diff line change
1
+ import smithy_python
2
+
3
+
4
+ def test_version ():
5
+ # TODO: Remove me when there's a real test
6
+ assert isinstance (smithy_python .__version__ , str )
Original file line number Diff line number Diff line change
1
+ [tox]
2
+ envlist = py36,py37,py38
3
+
4
+ skipsdist = True
5
+
6
+ [testenv]
7
+ deps =
8
+ -r requirements-dev.txt
9
+ -e .
10
+ commands =
11
+ pytest --cov-config =.coveragerc --cov =./ --cov-report =xml tests/functional tests/unit
12
+
13
+ [testenv:lint]
14
+ deps =
15
+ -r requirements-dev.txt
16
+ commands =
17
+ black --check --diff smithy_python tests
18
+ flake8 smithy_python
19
+
20
+ [testenv:type]
21
+ deps =
22
+ -r requirements-dev.txt
23
+ commands =
24
+ mypy smithy_python --strict
25
+
26
+ [testenv:full_tests]
27
+ deps =
28
+ -r requirements-dev.txt
29
+ -e .
30
+ commands =
31
+ pytest --cov-config =.coveragerc --cov =./ --cov-report =xml tests
You can’t perform that action at this time.
0 commit comments