Skip to content

Nightly job to update internal WPT dashboard #689

Nightly job to update internal WPT dashboard

Nightly job to update internal WPT dashboard #689

Workflow file for this run

name: Nightly job to update internal WPT dashboard
on:
# Run an 2.5 hours after servo nightly job
schedule:
- cron: '0 8 * * *'
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
permissions:
contents: write
pages: write
id-token: write
env:
RUST_BACKTRACE: 1
SHELL: /bin/bash
jobs:
wpt-for-layout-2013:
uses: ./.github/workflows/run-wpt.yml
with:
layout-engine: 2013
artifact-name: wpt-chunks
wpt-for-layout-2020:
uses: ./.github/workflows/run-wpt.yml
with:
layout-engine: 2020
artifact-name: wpt-chunks-2020
process-new-run:
name: Process all chunks and update metrics
runs-on: ubuntu-22.04
needs:
- wpt-for-layout-2013
- wpt-for-layout-2020
steps:
- name: Checkout dashboard repo
uses: actions/checkout@v3
with:
ref: main
- name: Download wpt results for 2013
uses: actions/download-artifact@v3
with:
name: wpt-chunks
path: wpt-chunks
- name: Download wpt results for 2020
uses: actions/download-artifact@v3
with:
name: wpt-chunks-2020
path: wpt-chunks-2020
- uses: actions/setup-node@v3
with:
node-version: 16
- run: npm ci
- name: Process new test results
run: |
CURRENT_DATE=$(date +"%Y-%m-%d")
mkdir -p runs
mkdir -p runs-2020
node index.js --add wpt-chunks wpt-chunks-2020 "$CURRENT_DATE"
git config user.name github-actions
git config user.email [email protected]
git add runs/${CURRENT_DATE}.xz
git add runs-2020/${CURRENT_DATE}.xz
git commit -m "Add runs for $CURRENT_DATE"
git push
- name: Setup Pages
uses: actions/configure-pages@v3
- name: Upload Pages artifact
uses: actions/upload-pages-artifact@v1
with:
path: 'site'
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v1