Skip to content

Target netstandard2.0 for libraries, target net8 for tests, and switch to github actions for CI #3

Target netstandard2.0 for libraries, target net8 for tests, and switch to github actions for CI

Target netstandard2.0 for libraries, target net8 for tests, and switch to github actions for CI #3

Workflow file for this run

# yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json
name: dotnet
on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
workflow_dispatch:
inputs:
version:
description: 'Release version to tag and create'
required: false
env:
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1
DOTNET_NOLOGO: true
jobs:
build:
strategy:
matrix:
os: [windows-latest]
configuration: [Debug, Release]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
- name: Setup .NET
uses: actions/setup-dotnet@v3
with:
global-json-file: global.json
- name: Restore dependencies
run: dotnet restore
- name: Build
run: dotnet build -c ${{ matrix.configuration }} --no-restore
- name: Test
run: dotnet test -c ${{ matrix.configuration }} --no-build --verbosity normal --collect:"XPlat Code Coverage"
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
with:
flags: ${{ matrix.os }},${{ matrix.configuration }}