CI #54
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| schedule: | |
| - cron: "0 3 * * *" | |
| push: | |
| branches: [ main ] | |
| pull_request: | |
| branches: [ main ] | |
| workflow_dispatch: | |
| jobs: | |
| build-and-test: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| - name: Setup .NET 10 | |
| uses: actions/setup-dotnet@v4 | |
| with: | |
| dotnet-version: '10.0.x' | |
| - name: Restore dependencies | |
| run: dotnet restore | |
| - name: Build | |
| run: dotnet build --configuration Release --no-restore | |
| - name: Install Playwright CLI | |
| run: dotnet tool install --global Microsoft.Playwright.CLI | |
| - name: Add .NET tools to PATH | |
| run: echo "$HOME/.dotnet/tools" >> $GITHUB_PATH | |
| # ✅ This is what your runner is missing (e.g. libwayland-server0, etc). | |
| # It installs the correct Linux deps for Playwright browsers on ubuntu-latest. | |
| - name: Install Playwright OS dependencies | |
| run: sudo env "PATH=$PATH" playwright install-deps | |
| - name: Install Playwright Browsers | |
| run: playwright install | |
| - name: Test (NUnit) | |
| run: dotnet test Playwright.NUnit.Testing/Playwright.NUnit.Testing.csproj --configuration Release --no-build | |
| - name: Test (TUnit) | |
| run: dotnet run --configuration Release --project Playwright.TUnit.Testing/Playwright.TUnit.Testing.csproj |