Skip to content

Commit

Permalink
Update tox.yaml for Azure Pipelines
Browse files Browse the repository at this point in the history
  • Loading branch information
Gabriel Borg committed Oct 8, 2024
1 parent c1a5841 commit 1f2b3a9
Showing 1 changed file with 29 additions and 39 deletions.
68 changes: 29 additions & 39 deletions .azure-pipelines/tox.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,42 +7,32 @@ trigger:
pool:
name: k8s

steps:

- script: |
apt-get update
apt-get install -y libgl1-mesa-glx
displayName: 'Install OpenCV system dependencies'
# Install uv using pip
- script: |
python3 -m pip install --upgrade pip
pip3 install uv
displayName: 'Install uv using pip'
# Set up Python 3.12 using uv
- script: |
uv python install 3.12
displayName: 'Set up Python 3.12 using uv'
# Install project dependencies using uv
- script: |
uv sync --dev
displayName: 'Install project dependencies with uv'
# Install tox using uv
- script: |
uv tool install tox --with tox-uv
displayName: 'Install tox using uv'
# Run tox environments using 'uv tool run'
- script: |
uv tool run tox -v
displayName: 'Run tox environments for Python 3.12, 3.11, and 3.10 using uv'
# Publish test results
- task: PublishTestResults@2
inputs:
testResultsFiles: '**/TEST-*.xml'
condition: succeededOrFailed()
displayName: 'Publish Test Results'
resources:
repositories:
- repository: tox
type: github
endpoint: github
name: tox-dev/azure-pipelines-template
ref: refs/tags/0.2

jobs:
- template: run-tox-env.yml@tox
parameters:
tox_version: ""
jobs:
py312:
image: [linux]

py311:
image: [linux]

py310:
image: [linux]

# Publish test results for this job
steps:
- task: PublishTestResults@2
inputs:
testResultsFiles: '**/TEST-*.xml'
condition: succeededOrFailed()
displayName: 'Publish Test Results'

0 comments on commit 1f2b3a9

Please sign in to comment.