From e7d3b22b4629fa0a66a5ffb6e0f515c94f3a0559 Mon Sep 17 00:00:00 2001 From: Paulus Schoutsen Date: Fri, 29 Mar 2019 09:18:25 -0700 Subject: [PATCH] Add lint task to Azure Pipelines [skip ci] --- azure-pipelines.yml | 26 ++++++++++++++++++++++++-- 1 file changed, 24 insertions(+), 2 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 7ce469f2175..0fdd8152679 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -8,6 +8,26 @@ trigger: jobs: +- job: 'Lint' + pool: + vmImage: 'Ubuntu-16.04' + + steps: + - task: UsePythonVersion@0 + inputs: + versionSpec: '3.5.3' + architecture: 'x64' + + - script: python -m pip install --upgrade pip && pip install -r requirements_all.txt -r requirements_test.txt -c homeassistant/package_constraints.txt + displayName: 'Install dependencies' + + - script: | + python script/gen_requirements_all.py validate + flake8 + pydocstyle tests + pylint homeassistant + displayName: 'lint' + - job: 'Test' pool: vmImage: 'Ubuntu-16.04' @@ -27,11 +47,10 @@ jobs: versionSpec: '$(python.version)' architecture: 'x64' - - script: python -m pip install --upgrade pip && pip install -r requirements_all.txt + - script: python -m pip install --upgrade pip && pip install -r requirements_test_all.txt -c homeassistant/package_constraints.txt displayName: 'Install dependencies' - script: | - pip install pytest pytest tests displayName: 'pytest' @@ -52,5 +71,8 @@ jobs: versionSpec: '3.x' architecture: 'x64' + - script: python -m pip install --upgrade pip && pip install wheel + displayName: 'Install dependencies' + - script: python setup.py sdist displayName: 'Build sdist'