Skip to content

Use MSTest SDK

Use MSTest SDK #302

Workflow file for this run

# SPDX-FileCopyrightText: 2022 Frans van Dorsselaer
#
# SPDX-License-Identifier: MIT
---
# yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json
name: Build
on:
push:
branches: [master]
pull_request:
branches: [master]
permissions: read-all
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup .NET
uses: actions/setup-dotnet@v4
- name: Cache
uses: actions/cache@v4
with:
path: ~/.nuget/packages
key: ${{ runner.os }}-nuget-${{ hashFiles('global.json', **/Directory.Packages.props') }}

Check failure on line 35 in .github/workflows/dotnet.yml

View workflow run for this annotation

GitHub Actions / Build

Invalid workflow file

The workflow is not valid. .github/workflows/dotnet.yml (Line: 35, Col: 16): The expression is not closed. An unescaped ${{ sequence was found, but the closing }} sequence was not found.
- name: Restore dependencies
run: |
dotnet restore
- name: Build
run: |
dotnet build --configuration Release --no-restore
- name: Test
run: |
dotnet test --configuration Release --no-build \
-p:TestingPlatformCommandLineArguments="--report-trx --coverage --coverage-output-format cobertura --coverage-output coverage.cobertura.xml"
- name: Package
run: |
dotnet pack --configuration Release --no-build
- name: Publish Test Results
uses: EnricoMi/publish-unit-test-result-action@v2
if: always()
with:
files: |
**/TestResults/*.trx
- name: Upload Package Artifact
uses: actions/upload-artifact@v4
with:
name: nuget-package
path: |
**/*.nupkg
**/*.snupkg
- name: Codecov
uses: codecov/codecov-action@v5
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}