diff --git a/.github/workflows/releases-validation.yml b/.github/workflows/releases-validation.yml new file mode 100644 index 0000000..36c83be --- /dev/null +++ b/.github/workflows/releases-validation.yml @@ -0,0 +1,38 @@ +name: Validate 'versions-manifest.json' file +on: + push: + branches: + - master + paths: + - 'versions-manifest.json' + +jobs: + setup-versions-from-manifest: + name: Setup ${{ matrix.python }} ${{ matrix.os }} + runs-on: ${{ matrix.os }} + strategy: + fail-fast: false + matrix: + os: [macos-latest, windows-latest, ubuntu-16.04, ubuntu-18.04, ubuntu-20.04] + python: [3.5.4, 3.6.7, 3.7.5, 3.8.1] + steps: + - name: Checkout + uses: actions/checkout@v2 + + - name: setup-python ${{ matrix.python }} + uses: actions/setup-python@v2 + with: + python-version: ${{ matrix.python }} + + - name: Validate version + run: | + $pythonVersion = (python --version) + if ("Python ${{ matrix.python }}" -ne "$pythonVersion"){ + Write-Host "The current version is $pythonVersion; expected version is ${{ matrix.python }}" + exit 1 + } + $pythonVersion + shell: pwsh + + - name: Run simple code + run: python -c 'import math; print(math.factorial(5))' \ No newline at end of file diff --git a/azure-pipelines/run-ci-builds.yml b/azure-pipelines/run-ci-builds.yml index bf1ca43..d58e2e7 100644 --- a/azure-pipelines/run-ci-builds.yml +++ b/azure-pipelines/run-ci-builds.yml @@ -29,6 +29,10 @@ jobs: -AzureDevOpsProjectName $(System.TeamProject) ` -AzureDevOpsAccessToken $(System.AccessToken) ` -SourceBranch $(Build.SourceBranch) ` + -DefinitionId $(DEFINITION_ID) ` -SourceVersion $(Build.SourceVersion) ` + -ManifestLink $(MANIFEST_LINK) ` + -WaitForBuilds $(WAIT_FOR_BUILDS) ` -ToolVersions "$(PYTHON_VERSIONS)" ` - -DefinitionId $(DEFINITION_ID) \ No newline at end of file + -RetryIntervalSec $(RETRY_INTERVAL_SEC) ` + -RetryCount $(RETRY_COUNT) \ No newline at end of file