[SPIKE] Updated CI to run all tests against LavinMQ - DO NOT MERGE #2479
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
push: | |
branches: | |
- master | |
- release-* | |
pull_request: | |
workflow_dispatch: | |
env: | |
DOTNET_NOLOGO: true | |
defaults: | |
run: | |
shell: pwsh | |
jobs: | |
build: | |
name: ${{ matrix.name }}-${{ matrix.test-category }} | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [ windows-2022, ubuntu-22.04 ] | |
test-category: [ RabbitMQ, LavinMQ ] | |
include: | |
- os: ubuntu-22.04 | |
name: Linux | |
test-category: LavinMQ | |
exclude: | |
- os: windows-2022 | |
- test-category: RabbitMQ | |
fail-fast: false | |
steps: | |
- name: Check for secrets | |
env: | |
SECRETS_AVAILABLE: ${{ secrets.SECRETS_AVAILABLE }} | |
run: exit $(If ($env:SECRETS_AVAILABLE -eq 'true') { 0 } Else { 1 }) | |
- name: Checkout | |
uses: actions/checkout@v4.2.2 | |
with: | |
fetch-depth: 0 | |
- name: Setup .NET SDK | |
uses: actions/setup-dotnet@v4.3.0 | |
with: | |
dotnet-version: | | |
9.0.x | |
8.0.x | |
- name: Build | |
run: dotnet build src --configuration Release | |
- name: Upload packages | |
if: matrix.name == 'SKIP' | |
uses: actions/upload-artifact@v4.6.1 | |
with: | |
name: NuGet packages | |
path: nugets/ | |
retention-days: 7 | |
- name: Azure login | |
if: matrix.os == 'windows-2022' | |
uses: azure/login@v2.2.0 | |
with: | |
creds: ${{ secrets.AZURE_ACI_CREDENTIALS }} | |
enable-AzPSSession: true | |
- name: Setup LavinMQ | |
uses: ./.github/actions/setup-lavinmq-action | |
if: matrix.test-category == 'LavinMQ' | |
with: | |
connection-string-name: LavinMQTransport_ConnectionString | |
tag: LavinMQTransport | |
registry-username: ${{ secrets.DOCKERHUB_USERNAME }} | |
registry-password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: Run tests | |
uses: Particular/run-tests-action@v1.7.0 | |
with: | |
reset-script: dotnet run --project src/targets |