Skip to content

PR Validation

PR Validation #19

Workflow file for this run

name: PR Validation
on:
pull_request:
branches:
- main
workflow_dispatch:
permissions:
contents: read
concurrency:
group: pr-validation-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
env:
APP_TEST_PROJECT: tests/PrompterOne.Web.Tests/PrompterOne.Web.Tests.csproj
CORE_TEST_PROJECT: tests/PrompterOne.Core.Tests/PrompterOne.Core.Tests.csproj
PLAYWRIGHT_CLI: tests/PrompterOne.Web.UITests/bin/Debug/net10.0/.playwright/package/cli.js
SOLUTION_FILE: PrompterOne.slnx
UI_TEST_PROJECT: tests/PrompterOne.Web.UITests/PrompterOne.Web.UITests.csproj
jobs:
build_and_test_supporting:
name: Validate Supporting Suites
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Setup .NET
uses: actions/setup-dotnet@v5
with:
global-json-file: global.json
- name: Build solution
run: dotnet build "$SOLUTION_FILE" -warnaserror
- name: Test supporting suites
run: |
dotnet test --project "$CORE_TEST_PROJECT"
dotnet test --project "$APP_TEST_PROJECT"
build_and_test_browser:
name: Validate Browser Suite
runs-on: macos-latest
timeout-minutes: 30
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Setup .NET
uses: actions/setup-dotnet@v5
with:
global-json-file: global.json
- name: Build solution
run: dotnet build "$SOLUTION_FILE" -warnaserror
- name: Install Playwright browser
run: node "$PLAYWRIGHT_CLI" install chromium
- name: Test browser suite
run: dotnet test --project "$UI_TEST_PROJECT"