This folder contains a base docker file which you can use to test and build the ros packges.
Example Azure DevOps Pipeline CI
- stage: tests
jobs:
- job: tests
displayName: Ros2 and Colcon Tests
steps:
- task: Docker@2
displayName: Login to ACR
inputs:
command: login
containerRegistry: $(containerRegistry)
- script: |
python -m pip install flake8
make lint-all
displayName: 'Run flake8 lint tests'
- script: |
make ci-test-all
displayName: 'Ros2 and colcon tests'
- task: PublishTestResults@2
condition: succeededOrFailed()
inputs:
testResultsFiles: '**/test-results/*result*.xml'
testRunTitle: 'Publish test results for ROS modules'
failTaskOnFailedTests: true
- task: PublishCodeCoverageResults@1
condition: succeededOrFailed()
inputs:
codeCoverageTool: Cobertura
summaryFileLocation: '**/test-results/*coverage*.xml'
pathToSources: "$(Build.Repository.LocalPath)/src/ros/workspace"
failIfCoverageEmpty: false
To Run the CI build you can do
./build/package/prepare.sh ${nextRelease.version}
Once built, the image is tagged and stored in a container repository. You can then use it with any container orchestration engine of your choice.