Skip to content

Merge pull request #200 from EvotecIT/add-generatecalendarevent-metho… #444

Merge pull request #200 from EvotecIT/add-generatecalendarevent-metho…

Merge pull request #200 from EvotecIT/add-generatecalendarevent-metho… #444

Workflow file for this run

name: Test .NET
on:
push:
branches:
- master
paths-ignore:
- '*.md'
- 'Docs/**'
- 'Examples/**'
- '.gitignore'
pull_request:
branches:
- master
workflow_dispatch:
env:
DOTNET_VERSION: '8.x'
BUILD_CONFIGURATION: 'Release'
jobs:
test-windows:
name: 'Windows'
runs-on: windows-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: ${{ env.DOTNET_VERSION }}
- name: Restore dependencies
run: dotnet restore Sources/ImagePlayground.sln
- name: Build solution
run: dotnet build Sources/ImagePlayground.sln --configuration ${{ env.BUILD_CONFIGURATION }} --no-restore
- name: Run tests
run: dotnet test Sources/ImagePlayground.Tests/ImagePlayground.Tests.csproj --configuration ${{ env.BUILD_CONFIGURATION }} --framework net8.0 --no-build --verbosity normal --logger trx --collect:"XPlat Code Coverage"
- name: Upload test results
uses: actions/upload-artifact@v4
if: always()
with:
name: test-results-windows
path: '**/*.trx'
- name: Upload coverage reports
uses: actions/upload-artifact@v4
if: always()
with:
name: coverage-reports-windows
path: '**/coverage.cobertura.xml'
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
with:
files: '**/coverage.cobertura.xml'
test-ubuntu:
name: 'Ubuntu'
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: ${{ env.DOTNET_VERSION }}
- name: Restore dependencies
run: dotnet restore Sources/ImagePlayground.sln
- name: Build solution
run: dotnet build Sources/ImagePlayground.sln --configuration ${{ env.BUILD_CONFIGURATION }} --no-restore
- name: Run tests
run: dotnet test Sources/ImagePlayground.Tests/ImagePlayground.Tests.csproj --configuration ${{ env.BUILD_CONFIGURATION }} --framework net8.0 --no-build --verbosity normal --logger trx --collect:"XPlat Code Coverage"
- name: Upload test results
uses: actions/upload-artifact@v4
if: always()
with:
name: test-results-ubuntu
path: '**/*.trx'
- name: Upload coverage reports
uses: actions/upload-artifact@v4
if: always()
with:
name: coverage-reports-ubuntu
path: '**/coverage.cobertura.xml'
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
with:
files: '**/coverage.cobertura.xml'
test-macos:
name: 'macOS'
runs-on: macos-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: ${{ env.DOTNET_VERSION }}
- name: Restore dependencies
run: dotnet restore Sources/ImagePlayground.sln
- name: Build solution
run: dotnet build Sources/ImagePlayground.sln --configuration ${{ env.BUILD_CONFIGURATION }} --no-restore
- name: Run tests
run: dotnet test Sources/ImagePlayground.Tests/ImagePlayground.Tests.csproj --configuration ${{ env.BUILD_CONFIGURATION }} --framework net8.0 --no-build --verbosity normal --logger trx --collect:"XPlat Code Coverage"
- name: Upload test results
uses: actions/upload-artifact@v4
if: always()
with:
name: test-results-macos
path: '**/*.trx'
- name: Upload coverage reports
uses: actions/upload-artifact@v4
if: always()
with:
name: coverage-reports-macos
path: '**/coverage.cobertura.xml'
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
with:
files: '**/coverage.cobertura.xml'