CI #411
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: | |
| pull_request: | |
| push: | |
| branches: | |
| - main | |
| paths-ignore: | |
| - '**.md' | |
| workflow_dispatch: | |
| jobs: | |
| ci: | |
| runs-on: ${{ matrix. os }} | |
| name: ${{ matrix.name }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - name: Windows | |
| os: windows-latest | |
| - name: Linux | |
| os: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v6 | |
| - name: Run | |
| uses: ./ | |
| with: | |
| connection-string-name: MongoDBConnectionString | |
| mongodb-port: 27018 | |
| mongodb-replica-set: "tr0" | |
| - name: Check result | |
| if: runner.os == 'Windows' | |
| shell: pwsh | |
| run: | | |
| $connstr = $Env:MongoDBConnectionString | |
| Write-Host "Connection String: $connstr" | |
| $result = mongosh "$connstr" | |
| echo $result | |
| - name: Setup .NET SDK | |
| uses: actions/setup-dotnet@v5.2.0 | |
| with: | |
| dotnet-version: 8.0.x | |
| - name: Build | |
| run: dotnet build src --configuration Release | |
| - name: Run tests | |
| uses: Particular/run-tests-action@v1.7.0 |