Skip to content

compile-and-test

compile-and-test #3

name: "compile-and-test"
permissions:
actions: write
contents: read
on:
workflow_dispatch:
push:
branches: [ "feature/*" ]
paths:
- 'frontend/**'
- 'catalog/**'
- 'ordering/**'
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: 6.0.x
- name: Restore dependencies
run: dotnet restore
- name: Build
run: dotnet build --no-restore
- name: add markdown report logger for frontend project
run: dotnet add unittests/unittests.csproj package LiquidTestReports.Markdown
- name: Test
run: dotnet test --no-build --logger "liquid.md;logfilename=testResults.md" unittests/unittests.csproj
- name: Output the results to the actions jobsummary
if: always()
run: cat $(find . -name testResults.md) >> $GITHUB_STEP_SUMMARY