Add indexer support #18
Workflow file for this run
This file contains 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: Build and Test | |
on: | |
pull_request: | |
branches: [ main, dev ] | |
jobs: | |
build_and_pack: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Code | |
uses: actions/checkout@v4 | |
- name: Setup .NET 8 | |
uses: actions/setup-dotnet@v3 | |
with: | |
dotnet-version: '8.0.x' | |
- name: Restore Dependencies | |
run: dotnet restore | |
- name: Build | |
run: dotnet build --configuration Release --no-restore | |
- name: Pack NuGet Packages | |
# run: dotnet pack --configuration Release --no-build --output ./packages --version 0.0.1-dev.$GITHUB_RUN_ID | |
run: dotnet pack --configuration Release --no-build --output ./packages /p:Version=0.0.1-dev | |
- name: Upload NuGet Packages | |
uses: actions/upload-artifact@v4 | |
with: | |
name: nuget-packages | |
path: ./packages | |
- name: Test And Collect CodeCov | |
run: dotnet test ./tests/MockMe.Tests.slnf --no-build -c Release --verbosity normal /p:CollectCoverage=true /p:CoverletOutputFormat=lcov | |
- name: Generate report | |
uses: danielpalme/ReportGenerator-GitHub-Action@5.3.11 | |
with: | |
reports: './tests/**/*.info' | |
targetdir: './tests/TestResults' | |
reporttypes: 'lcov' | |
filefilters: '-*\*.g.cs' | |
- name: Coveralls | |
uses: coverallsapp/github-action@master | |
with: | |
github-token: ${{ secrets.COVERALLS_REPO_TOKEN }} | |
path-to-lcov: ./tests/TestResults/lcov.info | |
test_linux: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
dotnet: | |
- '6.0' | |
- '7.0' | |
- '8.0' | |
- '9.0' | |
env: | |
ContinuousIntegrationBuild: true | |
LATEST_DOTNET_VERSION: '9.0' | |
needs: build_and_pack | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup .NET | |
uses: actions/setup-dotnet@v3 | |
with: | |
dotnet-version: ${{ matrix.dotnet }} | |
- name: Download NuGet Packages | |
uses: actions/download-artifact@v4 | |
with: | |
name: nuget-packages | |
path: ./packages | |
- name: Create local package feed | |
run: dotnet nuget add source ${{ github.workspace }}/packages --name localNuGet | |
- name: Print NuGet Sources | |
run: dotnet nuget list source | |
- name: Restore dependencies | |
run: dotnet restore /p:MockMeNugetPackageVersion="0.0.1-dev" | |
- name: Build | |
run: dotnet build ./tests/MockMe.Tests.slnf --no-restore -c Release /p:MockMeNugetPackageVersion="0.0.1-dev" | |
- name: Test | |
run: dotnet test ./tests/MockMe.Tests.slnf --no-build -c Release --verbosity normal | |
# test-windows: | |
# runs-on: windows-latest | |
# strategy: | |
# matrix: | |
# dotnet: | |
# - '6.0' | |
# - '7.0' | |
# - '8.0' | |
# - '9.0' | |
# needs: build_and_pack | |
# steps: | |
# - name: Checkout Code | |
# uses: actions/checkout@v4 | |
# - name: Setup .NET ${{ matrix.dotnet }} | |
# uses: actions/setup-dotnet@v3 | |
# with: | |
# dotnet-version: ${{ matrix.dotnet }} | |
# - name: Download NuGet Packages | |
# uses: actions/download-artifact@v4 | |
# with: | |
# name: nuget-packages | |
# path: ./packages | |
# - name: Create local package feed | |
# run: dotnet nuget add source ${{ github.workspace }}/packages --name localNuGet | |
# - name: Print NuGet Sources | |
# run: dotnet nuget list source | |
# - name: Restore dependencies | |
# run: dotnet restore /p:MockMeNugetPackageVersion="0.0.1-dev" | |
# - name: Build | |
# run: dotnet build ./tests/MockMe.Tests.slnf --no-restore -c Release /p:MockMeNugetPackageVersion="0.0.1-dev" | |
# - name: Test | |
# run: dotnet test ./tests/MockMe.Tests.slnf --no-build -c Release --verbosity normal /p:CollectCoverage=true /p:CoverletOutputFormat=openCover |