Bump MartinCostello.Logging.XUnit.v3 from 0.5.0 to 0.5.1 #2559
Workflow file for this run
This file contains 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: lighthouse | |
on: | |
pull_request: | |
branches: | |
- main | |
- dotnet-vnext | |
- dotnet-nightly | |
workflow_dispatch: | |
permissions: | |
contents: read | |
env: | |
APPLICATION_URL: 'https://localhost:50001' | |
DOTNET_CLI_TELEMETRY_OPTOUT: true | |
DOTNET_NOLOGO: true | |
DOTNET_SYSTEM_CONSOLE_ALLOW_ANSI_COLOR_REDIRECTION: 1 | |
NUGET_XMLDOC_MODE: skip | |
TERM: xterm | |
jobs: | |
lighthouse: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
- name: Setup .NET SDK | |
uses: actions/setup-dotnet@3e891b0cb619bf60e2c25674b222b8940e2c1c25 # v4.1.0 | |
- name: Start website | |
shell: pwsh | |
env: | |
APPLICATION_URL: ${{ env.APPLICATION_URL }} | |
ConnectionStrings__AzureCosmos: 'AccountKey=C2y6yDjf5/R+ob0N8A7Cgv30VRDJIWEHLM+4QDU5DE2nQ9nDuVTqobD4b8mGGyPMbIZnqyMsEcaGQy67XIw/Jw==;AccountEndpoint=https://localhost:8081;DisableServerCertificateValidation=True;' | |
Logging__LogLevel__Azure: 'None' | |
run: | | |
Push-Location (Join-Path "src" "LondonTravel.Site") | |
npm ci | |
npm run build | |
Pop-Location | |
Start-Process nohup 'dotnet run --project ./src/LondonTravel.Site/LondonTravel.Site.csproj --configuration Release /p:EnableNETAnalyzers=false /p:EnforceCodeStyleInBuild=false' | |
$StatusCode = 0 | |
$Attempts = 0 | |
While ($Attempts -lt 10) { | |
$Response = Try { | |
Invoke-WebRequest ${env:APPLICATION_URL} -SkipCertificateCheck | |
} catch { | |
$_.Exception.Response | |
} | |
$StatusCode = $Response.StatusCode | |
If ($StatusCode -eq 200) { | |
break | |
} | |
$Attempts++ | |
Start-Sleep -Seconds 10 | |
} | |
If ($StatusCode -ne 200) { | |
throw "Failed to successfully connect to website after $Attempts attempts." | |
} | |
New-Item -Path "${env:GITHUB_WORKSPACE}/artifacts/lighthouse" -ItemType Directory | Out-Null | |
- name: Lighthouse | |
uses: foo-software/lighthouse-check-action@a80267da2e0244b8a2e457a8575fc47590615852 # v12.0.1 | |
id: lighthouse | |
with: | |
device: 'all' | |
gitHubAccessToken: ${{ secrets.LIGHTHOUSE_ACCESS_TOKEN }} | |
outputDirectory: ${{ github.workspace }}/artifacts/lighthouse | |
prCommentEnabled: true | |
urls: ${{ env.APPLICATION_URL }} | |
wait: true | |
- name: Check Lighthouse scores | |
uses: foo-software/lighthouse-check-status-action@2b9d5101f7a0de86ddb153a0d77ad7046aac1052 # v3.0.1 | |
with: | |
lighthouseCheckResults: ${{ steps.lighthouse.outputs.lighthouseCheckResults }} | |
minAccessibilityScore: '90' | |
minBestPracticesScore: '83' | |
minPerformanceScore: '71' | |
minProgressiveWebAppScore: '85' | |
minSeoScore: '100' | |
- name: Publish artifacts | |
uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0 | |
if: ${{ !cancelled() }} | |
with: | |
name: lighthouse | |
path: ${{ github.workspace }}/artifacts/lighthouse | |
if-no-files-found: ignore |