Skip to content

Commit

Permalink
typing was never updated for py37 (#131)
Browse files Browse the repository at this point in the history
* typing was never updated for py37

Extend CI
  • Loading branch information
penguinolog committed Feb 18, 2019
1 parent aa56772 commit c6effd4
Show file tree
Hide file tree
Showing 5 changed files with 49 additions and 13 deletions.
1 change: 1 addition & 0 deletions .azure_pipelines/run_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ jobs:
dependsOn:
- PyLint
- MyPy
- PEP8
pool:
vmImage: "vs2017-win2016"

Expand Down
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ jobs:
install:
- *upgrade_python_toolset
- *install_deps
- pip install --upgrade "mypy >= 0.660"
- pip install --upgrade "mypy >= 0.670"
script:
- mypy --strict exec_helpers
- <<: *static_analysis
Expand Down
45 changes: 36 additions & 9 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# https://docs.microsoft.com/azure/devops/pipelines/languages/python

jobs:
- job: 'PyLint'
- job: 'PEP8'
pool:
vmIMage: 'VS2017-Win2016'
steps:
Expand All @@ -16,20 +16,47 @@ jobs:
python -m pip install --upgrade pip
pip install -U setuptools
pip install -r requirements.txt
pip install -U pytest pylint pytest-sugar pytest-flake8 flake8-bugbear flake8-docstrings
displayName: 'Install dependencies'
- script: |
pytest -vvv --flake8 -m flake8 --junitxml=flake8_result.xml exec_helpers
displayName: 'PEP8'
- task: PublishTestResults@2
displayName: publish test results via junit
condition: succeededOrFailed()
inputs:
testResultsFormat: "JUnit"
testResultsFiles: ${{ format('$(System.DefaultWorkingDirectory)/flake8_result.xml') }}
testRunTitle: 'PEP8'

- job: 'PyLint'
pool:
vmIMage: 'VS2017-Win2016'
steps:
- task: UsePythonVersion@0
inputs:
versionSpec: '3.7'

- script: |
python -m pip install --upgrade pip
pip install -U setuptools
pip install -r requirements.txt
pip install -U pytest pylint pytest-pylint pytest-sugar
displayName: 'Install dependencies'
- script: |
pytest -vvv --pylint -m pylint --junitxml=pylint_result.xml exec_helpers
displayName: 'PyLint'
# - task: PublishTestResults@2
# displayName: publish test results via junit
# condition: succeededOrFailed()
# inputs:
# testResultsFormat: "PyLint"
# testResultsFiles: ${{ format('$(System.DefaultWorkingDirectory)/pylint_result.xml') }}
# testRunTitle: 'MyPy'
- task: PublishTestResults@2
displayName: publish test results via junit
condition: succeededOrFailed()
inputs:
testResultsFormat: "JUnit"
testResultsFiles: ${{ format('$(System.DefaultWorkingDirectory)/pylint_result.xml') }}
testRunTitle: 'PyLint'

- job: 'MyPy'
pool:
Expand All @@ -43,10 +70,10 @@ jobs:
python -m pip install --upgrade pip
pip install -U setuptools
pip install -r requirements.txt
pip install -U mypy
displayName: 'Install dependencies'
- script: |
pip install -U mypy
mypy --strict --junit-xml=mypy_result.xml exec_helpers
displayName: 'MyPy'
Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@ six>=1.10.0 # MIT
threaded>=2.0 # Apache-2.0
PyYAML>=3.12 # MIT
advanced-descriptors>=1.0 # Apache-2.0
typing >= 3.6 ; python_version < "3.8"
typing >= 3.6 ; python_version < "3.7"
psutil >= 5.0
12 changes: 10 additions & 2 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ deps =
pytest-cov
pytest-html
pytest-sugar
py{34,35,36,37}-nocov: Cython
py{36,37}-nocov: Cython
-r{toxinidir}/CI_REQUIREMENTS.txt

commands =
Expand Down Expand Up @@ -89,8 +89,16 @@ exclude =
ignore =
E203,
W503
D401,
D202,
D203,
D213
# whitespace before ':'
# line break before binary operator
# First line should be in imperative mood; try rephrasing
# No blank lines allowed after function docstring
# 1 blank line required before class docstring
# Multi-line docstring summary should start at the second line
show-pep8 = True
show-source = True
count = True
Expand Down Expand Up @@ -131,7 +139,7 @@ commands = pipdeptree

[testenv:mypy]
deps =
mypy>=0.660
mypy>=0.670
lxml
-r{toxinidir}/CI_REQUIREMENTS.txt
commands = mypy --strict --xslt-html-report mypy_report -p exec_helpers

0 comments on commit c6effd4

Please sign in to comment.