Skip to content

Commit

Permalink
Unify Linux and Windows
Browse files Browse the repository at this point in the history
  • Loading branch information
kaylangan committed Nov 12, 2018
1 parent e4974c7 commit 086655e
Show file tree
Hide file tree
Showing 4 changed files with 54 additions and 71 deletions.
33 changes: 0 additions & 33 deletions _azure-pipelines/template-linux.yml

This file was deleted.

36 changes: 0 additions & 36 deletions _azure-pipelines/template-windows.yml

This file was deleted.

46 changes: 46 additions & 0 deletions _azure-pipelines/template.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
jobs:
- job: ${{ parameters.name }}
pool:
vmImage: ${{ parameters.vmImage }}
strategy:
matrix:
Python27:
PYTHON_VERSION: '2.7'
Python34:
PYTHON_VERSION: '3.4'
Python35:
PYTHON_VERSION: '3.5'
Python36:
PYTHON_VERSION: '3.6'
Python37:
PYTHON_VERSION: '3.7'
steps:
- task: UsePythonVersion@0
inputs:
versionSpec: $(PYTHON_VERSION)
architecture: 'x64'
displayName: 'Install Python'
- script: |
make
pipenv install -e .[socks] --skip-lock
displayName: 'Set up'
- ${{ if eq(parameters.name, 'Linux') }}:
- script: |
make test-readme
make ci
displayName: 'Test and CI'
- task: PublishTestResults@2
displayName: 'Publish test results'
inputs:
testResultsFiles: 'report.xml'
testRunTitle: Python $(PYTHON_VERSION)

- ${{ if eq(parameters.name, 'Windows') }}:
- script: |
make coverage
displayName: 'Coverage'
- script: |
pipenv run codecov -f coverage.xml
displayName: 'Run codecov'
10 changes: 8 additions & 2 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
jobs:
- template: _azure-pipelines/template-linux.yml
- template: _azure-pipelines/template.yml
parameters:
name: Linux
vmImage: Ubuntu-16.04

- template: _azure-pipelines/template-windows.yml
- template: _azure-pipelines/template.yml
parameters:
name: Windows
vmImage: vs2017-win2016

0 comments on commit 086655e

Please sign in to comment.