Feature: Introduce an OpenAPI-based HTTP client code generator with Kiota #41
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: | |
| pull_request: | |
| env: | |
| WORKING_DIR: ${{ github.workspace }} | |
| SOLUTION_PATH: '${{ github.workspace }}\CompilerPlatform.slnx' | |
| jobs: | |
| build: | |
| runs-on: windows-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| configuration: [CSharp, VisualBasic] | |
| project: [Analyzers, CodeFixers, Extensions, HighPerformance, SourceGenerators, DynamicCast, Swagger] | |
| exclude: | |
| - configuration: VisualBasic | |
| project: DynamicCast | |
| - configuration: VisualBasic | |
| project: Swagger | |
| env: | |
| PROJECT: ${{ matrix.project }} | |
| CONFIGURATION: ${{ matrix.configuration }} | |
| steps: | |
| - name: Checkout the repository | |
| uses: actions/checkout@v4 | |
| - name: Setup MSBuild | |
| uses: microsoft/setup-msbuild@v2 | |
| - name: Setup NuGet | |
| uses: NuGet/setup-nuget@v2 | |
| - name: Setup .NET | |
| uses: actions/setup-dotnet@v4 | |
| with: | |
| dotnet-version: 10.x | |
| - name: Restore | |
| run: | | |
| msbuild $env:SOLUTION_PATH /t:Restore /p:Configuration=$env:CONFIGURATION | |
| - name: Resolve project directory | |
| shell: pwsh | |
| run: | | |
| $roslynProjects = @('Analyzers', 'CodeFixers', 'Extensions', 'HighPerformance', 'SourceGenerators') | |
| if ($roslynProjects -contains '${{ matrix.project }}') { | |
| $projectFolder = 'roslyn' | |
| $projectPrefix = 'Riverside.CompilerPlatform' | |
| } | |
| else { | |
| $projectFolder = 'features' | |
| $projectPrefix = 'Riverside.CompilerPlatform.Features' | |
| } | |
| "PROJECT_DIR=${{ github.workspace }}\src\$projectFolder\$projectPrefix.${{ matrix.project }}" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append | |
| - name: Build | |
| run: | | |
| msbuild $env:PROJECT_DIR /t:Build /p:Configuration=$env:CONFIGURATION | |
| test: | |
| needs: [build] | |
| runs-on: windows-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| configuration: [CSharp, VisualBasic] | |
| env: | |
| CONFIGURATION: ${{ matrix.configuration }} | |
| PROJECT_DIR: ${{ github.workspace }}\tests\Riverside.CompilerPlatform.${{ matrix.configuration }}.Tests | |
| steps: | |
| - name: Checkout the repository | |
| uses: actions/checkout@v4 | |
| - name: Setup MSBuild | |
| uses: microsoft/setup-msbuild@v2 | |
| - name: Setup NuGet | |
| uses: NuGet/setup-nuget@v2 | |
| - name: Setup .NET | |
| uses: actions/setup-dotnet@v4 | |
| with: | |
| dotnet-version: 9.x | |
| - name: Restore | |
| run: | | |
| msbuild $env:SOLUTION_PATH /t:Restore /p:Configuration=$env:CONFIGURATION | |
| - name: Build | |
| run: | | |
| msbuild $env:SOLUTION_PATH /t:Build /p:Configuration=$env:CONFIGURATION | |
| - name: Test | |
| run: | | |
| dotnet test $env:PROJECT_DIR --configuration $env:CONFIGURATION --no-build |