From fc05153fb11b6e5755eb12dfe3f59dc4f079d82d Mon Sep 17 00:00:00 2001 From: tracyboehrer Date: Mon, 24 Feb 2020 08:55:33 -0600 Subject: [PATCH 01/10] Update ci-pr-pipeline.yml for Azure Pipelines Run pytest using Python 3.6, 3.7, and 3.8 --- ci-pr-pipeline.yml | 42 ++++++++++++++++++++++++++++++++++++++---- 1 file changed, 38 insertions(+), 4 deletions(-) diff --git a/ci-pr-pipeline.yml b/ci-pr-pipeline.yml index 13d622d1c..0e358e9bf 100644 --- a/ci-pr-pipeline.yml +++ b/ci-pr-pipeline.yml @@ -6,7 +6,10 @@ variables: COVERALLS_GIT_COMMIT: $(Build.SourceVersion) COVERALLS_SERVICE_JOB_ID: $(Build.BuildId) COVERALLS_SERVICE_NAME: python-ci - python.version: 3.7.6 + python.36: 3.6.9 + python.37: 3.7.6 + pythin.38: 3.8.1 + python.version: $(python.37) jobs: @@ -53,8 +56,39 @@ jobs: pip install pytest pip install pytest-cov pip install coveralls - pytest --junitxml=junit/test-results.xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html - displayName: Pytest + displayName: PyTest + + - task: UsePythonVersion@0 + displayName: 'Use Python $(python.36)' + inputs: + versionSpec: '$(python.36)' + + - script: + pytest --junitxml=junit/test-results.36.xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html + displayName: Pytest.36 + + - task: UsePythonVersion@0 + displayName: 'Use Python $(python.37)' + inputs: + versionSpec: '$(python.37)' + + - script: + pytest --junitxml=junit/test-results.37.xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html + displayName: Pytest.37 + + - task: UsePythonVersion@0 + displayName: 'Use Python $(python.38)' + inputs: + versionSpec: '$(python.38)' + + - script: + pytest --junitxml=junit/test-results.38.xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html + displayName: Pytest.38 + + - task: UsePythonVersion@0 + displayName: 'Use Python $(python.version)' + inputs: + versionSpec: '$(python.version)' - script: 'black --check libraries' displayName: 'Check Black compliant' @@ -65,7 +99,7 @@ jobs: - task: PublishTestResults@2 displayName: 'Publish Test Results **/test-results.xml' inputs: - testResultsFiles: '**/test-results.xml' + testResultsFiles: '**/test-results*.xml' testRunTitle: 'Python $(python.version)' - script: 'COVERALLS_REPO_TOKEN=$(COVERALLS_TOKEN) coveralls' From e4795ec9f9ac9fc02167752568f5d15e77dad0c6 Mon Sep 17 00:00:00 2001 From: tracyboehrer Date: Mon, 24 Feb 2020 09:03:58 -0600 Subject: [PATCH 02/10] Update ci-pr-pipeline.yml for Azure Pipelines --- ci-pr-pipeline.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci-pr-pipeline.yml b/ci-pr-pipeline.yml index 0e358e9bf..da36a7a9c 100644 --- a/ci-pr-pipeline.yml +++ b/ci-pr-pipeline.yml @@ -6,7 +6,7 @@ variables: COVERALLS_GIT_COMMIT: $(Build.SourceVersion) COVERALLS_SERVICE_JOB_ID: $(Build.BuildId) COVERALLS_SERVICE_NAME: python-ci - python.36: 3.6.9 + python.36: 3.6.10 python.37: 3.7.6 pythin.38: 3.8.1 python.version: $(python.37) From dc3ecab5c1031c3a8cc57f74fa8da8d5af8ba7e0 Mon Sep 17 00:00:00 2001 From: tracyboehrer Date: Mon, 24 Feb 2020 09:26:41 -0600 Subject: [PATCH 03/10] Update ci-pr-pipeline.yml for Azure Pipelines --- ci-pr-pipeline.yml | 26 +++++++++++++++++++------- 1 file changed, 19 insertions(+), 7 deletions(-) diff --git a/ci-pr-pipeline.yml b/ci-pr-pipeline.yml index da36a7a9c..923cfba50 100644 --- a/ci-pr-pipeline.yml +++ b/ci-pr-pipeline.yml @@ -56,7 +56,7 @@ jobs: pip install pytest pip install pytest-cov pip install coveralls - displayName: PyTest + displayName: PyTestSetup - task: UsePythonVersion@0 displayName: 'Use Python $(python.36)' @@ -67,6 +67,12 @@ jobs: pytest --junitxml=junit/test-results.36.xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html displayName: Pytest.36 + - task: PublishTestResults@2 + displayName: 'Publish Test Results **/test-results.36.xml' + inputs: + testResultsFiles: '**/test-results.36.xml' + testRunTitle: 'Python $(python.36)' + - task: UsePythonVersion@0 displayName: 'Use Python $(python.37)' inputs: @@ -76,6 +82,12 @@ jobs: pytest --junitxml=junit/test-results.37.xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html displayName: Pytest.37 + - task: PublishTestResults@2 + displayName: 'Publish Test Results **/test-results.37.xml' + inputs: + testResultsFiles: '**/test-results.37.xml' + testRunTitle: 'Python $(python.37)' + - task: UsePythonVersion@0 displayName: 'Use Python $(python.38)' inputs: @@ -85,6 +97,12 @@ jobs: pytest --junitxml=junit/test-results.38.xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html displayName: Pytest.38 + - task: PublishTestResults@2 + displayName: 'Publish Test Results **/test-results.38.xml' + inputs: + testResultsFiles: '**/test-results.38.xml' + testRunTitle: 'Python $(python.38)' + - task: UsePythonVersion@0 displayName: 'Use Python $(python.version)' inputs: @@ -96,12 +114,6 @@ jobs: - script: 'pylint --rcfile=.pylintrc libraries' displayName: Pylint - - task: PublishTestResults@2 - displayName: 'Publish Test Results **/test-results.xml' - inputs: - testResultsFiles: '**/test-results*.xml' - testRunTitle: 'Python $(python.version)' - - script: 'COVERALLS_REPO_TOKEN=$(COVERALLS_TOKEN) coveralls' displayName: 'Push test results to coveralls https://coveralls.io/github/microsoft/botbuilder-python' continueOnError: true From 77a37ba2438a01c3ef5df42234b092e60d265eae Mon Sep 17 00:00:00 2001 From: tracyboehrer Date: Mon, 24 Feb 2020 09:41:26 -0600 Subject: [PATCH 04/10] Update ci-pr-pipeline.yml for Azure Pipelines --- ci-pr-pipeline.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci-pr-pipeline.yml b/ci-pr-pipeline.yml index 923cfba50..c2350bc3e 100644 --- a/ci-pr-pipeline.yml +++ b/ci-pr-pipeline.yml @@ -91,7 +91,7 @@ jobs: - task: UsePythonVersion@0 displayName: 'Use Python $(python.38)' inputs: - versionSpec: '$(python.38)' + versionSpec: '3.8.1' - script: pytest --junitxml=junit/test-results.38.xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html From 97b18d18da6d478c42df90c504bf894434decd22 Mon Sep 17 00:00:00 2001 From: tracyboehrer Date: Mon, 24 Feb 2020 09:56:17 -0600 Subject: [PATCH 05/10] Update ci-pr-pipeline.yml for Azure Pipelines --- ci-pr-pipeline.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/ci-pr-pipeline.yml b/ci-pr-pipeline.yml index c2350bc3e..f68888837 100644 --- a/ci-pr-pipeline.yml +++ b/ci-pr-pipeline.yml @@ -8,7 +8,7 @@ variables: COVERALLS_SERVICE_NAME: python-ci python.36: 3.6.10 python.37: 3.7.6 - pythin.38: 3.8.1 + python.38: 3.8.1 python.version: $(python.37) @@ -64,7 +64,7 @@ jobs: versionSpec: '$(python.36)' - script: - pytest --junitxml=junit/test-results.36.xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html + python -m pytest --junitxml=junit/test-results.36.xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html displayName: Pytest.36 - task: PublishTestResults@2 @@ -79,7 +79,7 @@ jobs: versionSpec: '$(python.37)' - script: - pytest --junitxml=junit/test-results.37.xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html + python -m pytest --junitxml=junit/test-results.37.xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html displayName: Pytest.37 - task: PublishTestResults@2 @@ -91,10 +91,10 @@ jobs: - task: UsePythonVersion@0 displayName: 'Use Python $(python.38)' inputs: - versionSpec: '3.8.1' + versionSpec: '$(python.38)' - script: - pytest --junitxml=junit/test-results.38.xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html + python -m pytest --junitxml=junit/test-results.38.xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html displayName: Pytest.38 - task: PublishTestResults@2 From a7d516901936c15f152f0845522f01e321e7cc5d Mon Sep 17 00:00:00 2001 From: tracyboehrer Date: Mon, 24 Feb 2020 10:02:50 -0600 Subject: [PATCH 06/10] Update ci-pr-pipeline.yml for Azure Pipelines --- ci-pr-pipeline.yml | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/ci-pr-pipeline.yml b/ci-pr-pipeline.yml index f68888837..dcd84e4ba 100644 --- a/ci-pr-pipeline.yml +++ b/ci-pr-pipeline.yml @@ -52,18 +52,15 @@ jobs: pip install black displayName: 'Install dependencies' - - script: | - pip install pytest - pip install pytest-cov - pip install coveralls - displayName: PyTestSetup - - task: UsePythonVersion@0 displayName: 'Use Python $(python.36)' inputs: versionSpec: '$(python.36)' - script: + pip install pytest + pip install pytest-cov + pip install coveralls python -m pytest --junitxml=junit/test-results.36.xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html displayName: Pytest.36 @@ -79,6 +76,9 @@ jobs: versionSpec: '$(python.37)' - script: + pip install pytest + pip install pytest-cov + pip install coveralls python -m pytest --junitxml=junit/test-results.37.xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html displayName: Pytest.37 @@ -94,6 +94,9 @@ jobs: versionSpec: '$(python.38)' - script: + pip install pytest + pip install pytest-cov + pip install coveralls python -m pytest --junitxml=junit/test-results.38.xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html displayName: Pytest.38 From 463bdc7893dc683f43e362c6bb6fc596d5510d41 Mon Sep 17 00:00:00 2001 From: tracyboehrer Date: Mon, 24 Feb 2020 10:12:32 -0600 Subject: [PATCH 07/10] Update ci-pr-pipeline.yml for Azure Pipelines --- ci-pr-pipeline.yml | 73 +++++++++++----------------------------------- 1 file changed, 17 insertions(+), 56 deletions(-) diff --git a/ci-pr-pipeline.yml b/ci-pr-pipeline.yml index dcd84e4ba..540176901 100644 --- a/ci-pr-pipeline.yml +++ b/ci-pr-pipeline.yml @@ -9,7 +9,6 @@ variables: python.36: 3.6.10 python.37: 3.7.6 python.38: 3.8.1 - python.version: $(python.37) jobs: @@ -18,18 +17,26 @@ jobs: #Multi-configuration and multi-agent job options are not exported to YAML. Configure these options using documentation guidance: https://docs.microsoft.com/vsts/pipelines/process/phases pool: name: Hosted Ubuntu 1604 - #Your build pipeline references the ‘python.version’ variable, which you’ve selected to be settable at queue time. Create or edit the build pipeline for this YAML file, define the variable on the Variables tab, and then select the option to make it settable at queue time. See https://go.microsoft.com/fwlink/?linkid=865971 - #Your build pipeline references the ‘python.version’ variable, which you’ve selected to be settable at queue time. Create or edit the build pipeline for this YAML file, define the variable on the Variables tab, and then select the option to make it settable at queue time. See https://go.microsoft.com/fwlink/?linkid=865971 steps: - powershell: | Get-ChildItem env:* | sort-object name | Format-Table -Autosize -Wrap | Out-String -Width 120 displayName: 'Get environment vars' + strategy: + matrix: + Python35: + PYTHON_VERSION: '$(python.36)' + Python36: + PYTHON_VERSION: '$(python.37)' + Python37: + PYTHON_VERSION: '$(python.38)' + maxParallel: 2 + - task: UsePythonVersion@0 - displayName: 'Use Python $(python.version)' + displayName: 'Use Python $(PYTHON_VERSION)' inputs: - versionSpec: '$(python.version)' + versionSpec: '$(PYTHON_VERSION)' - script: 'sudo ln -s /opt/hostedtoolcache/Python/3.6.9/x64/lib/libpython3.6m.so.1.0 /usr/lib/libpython3.6m.so' displayName: libpython3.6m @@ -52,64 +59,18 @@ jobs: pip install black displayName: 'Install dependencies' - - task: UsePythonVersion@0 - displayName: 'Use Python $(python.36)' - inputs: - versionSpec: '$(python.36)' - - - script: - pip install pytest - pip install pytest-cov - pip install coveralls - python -m pytest --junitxml=junit/test-results.36.xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html - displayName: Pytest.36 - - - task: PublishTestResults@2 - displayName: 'Publish Test Results **/test-results.36.xml' - inputs: - testResultsFiles: '**/test-results.36.xml' - testRunTitle: 'Python $(python.36)' - - - task: UsePythonVersion@0 - displayName: 'Use Python $(python.37)' - inputs: - versionSpec: '$(python.37)' - - script: pip install pytest pip install pytest-cov pip install coveralls - python -m pytest --junitxml=junit/test-results.37.xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html - displayName: Pytest.37 + python -m pytest --junitxml=junit/test-results.$(PYTHON_VERSION).xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html + displayName: Pytest - task: PublishTestResults@2 - displayName: 'Publish Test Results **/test-results.37.xml' - inputs: - testResultsFiles: '**/test-results.37.xml' - testRunTitle: 'Python $(python.37)' - - - task: UsePythonVersion@0 - displayName: 'Use Python $(python.38)' - inputs: - versionSpec: '$(python.38)' - - - script: - pip install pytest - pip install pytest-cov - pip install coveralls - python -m pytest --junitxml=junit/test-results.38.xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html - displayName: Pytest.38 - - - task: PublishTestResults@2 - displayName: 'Publish Test Results **/test-results.38.xml' - inputs: - testResultsFiles: '**/test-results.38.xml' - testRunTitle: 'Python $(python.38)' - - - task: UsePythonVersion@0 - displayName: 'Use Python $(python.version)' + displayName: 'Publish Test Results **/test-results.$(PYTHON_VERSION).xml' inputs: - versionSpec: '$(python.version)' + testResultsFiles: '**/test-results.$(PYTHON_VERSION).xml' + testRunTitle: 'Python $(PYTHON_VERSION)' - script: 'black --check libraries' displayName: 'Check Black compliant' From 330388cdf3d0caa26b1002f374818ab0905882b8 Mon Sep 17 00:00:00 2001 From: tracyboehrer Date: Mon, 24 Feb 2020 10:14:05 -0600 Subject: [PATCH 08/10] Update ci-pr-pipeline.yml for Azure Pipelines --- ci-pr-pipeline.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/ci-pr-pipeline.yml b/ci-pr-pipeline.yml index 540176901..95e1d1444 100644 --- a/ci-pr-pipeline.yml +++ b/ci-pr-pipeline.yml @@ -18,11 +18,6 @@ jobs: pool: name: Hosted Ubuntu 1604 - steps: - - powershell: | - Get-ChildItem env:* | sort-object name | Format-Table -Autosize -Wrap | Out-String -Width 120 - displayName: 'Get environment vars' - strategy: matrix: Python35: @@ -33,6 +28,11 @@ jobs: PYTHON_VERSION: '$(python.38)' maxParallel: 2 + steps: + - powershell: | + Get-ChildItem env:* | sort-object name | Format-Table -Autosize -Wrap | Out-String -Width 120 + displayName: 'Get environment vars' + - task: UsePythonVersion@0 displayName: 'Use Python $(PYTHON_VERSION)' inputs: From 8de379c5a663bef5b93fec57f4b0a89d61217d05 Mon Sep 17 00:00:00 2001 From: tracyboehrer Date: Mon, 24 Feb 2020 10:16:55 -0600 Subject: [PATCH 09/10] Update ci-pr-pipeline.yml for Azure Pipelines --- ci-pr-pipeline.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ci-pr-pipeline.yml b/ci-pr-pipeline.yml index 95e1d1444..6f1fd0789 100644 --- a/ci-pr-pipeline.yml +++ b/ci-pr-pipeline.yml @@ -20,11 +20,11 @@ jobs: strategy: matrix: - Python35: - PYTHON_VERSION: '$(python.36)' Python36: - PYTHON_VERSION: '$(python.37)' + PYTHON_VERSION: '$(python.36)' Python37: + PYTHON_VERSION: '$(python.37)' + Python38: PYTHON_VERSION: '$(python.38)' maxParallel: 2 @@ -63,7 +63,7 @@ jobs: pip install pytest pip install pytest-cov pip install coveralls - python -m pytest --junitxml=junit/test-results.$(PYTHON_VERSION).xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html + pytest --junitxml=junit/test-results.$(PYTHON_VERSION).xml --cov-config=.coveragerc --cov --cov-report=xml --cov-report=html displayName: Pytest - task: PublishTestResults@2 From 4b737f6f55915cc08b97ecc8d5fdfa3e8723bf8c Mon Sep 17 00:00:00 2001 From: tracyboehrer Date: Mon, 24 Feb 2020 10:20:49 -0600 Subject: [PATCH 10/10] Update ci-pr-pipeline.yml for Azure Pipelines --- ci-pr-pipeline.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ci-pr-pipeline.yml b/ci-pr-pipeline.yml index 6f1fd0789..28a803d69 100644 --- a/ci-pr-pipeline.yml +++ b/ci-pr-pipeline.yml @@ -26,7 +26,7 @@ jobs: PYTHON_VERSION: '$(python.37)' Python38: PYTHON_VERSION: '$(python.38)' - maxParallel: 2 + maxParallel: 3 steps: - powershell: | @@ -59,7 +59,7 @@ jobs: pip install black displayName: 'Install dependencies' - - script: + - script: | pip install pytest pip install pytest-cov pip install coveralls