mirror of
https://github.com/servo/servo.git
synced 2025-09-30 00:29:14 +01:00
Import WPT tests every week instead of every day
We often have multiple imports stacked up which makes it more confusing to land each one. In addition, giving a week to do the import will give us more margin to triage failing tests and hopefully to be able to use intermittent expectations for flaky tests.
This commit is contained in:
parent
15de7b99b7
commit
728021d69e
2 changed files with 4 additions and 4 deletions
87
.github/workflows/scheduled-wpt-import.yml
vendored
Normal file
87
.github/workflows/scheduled-wpt-import.yml
vendored
Normal file
|
@ -0,0 +1,87 @@
|
|||
name: Scheduled WPT import
|
||||
|
||||
on:
|
||||
schedule:
|
||||
# Run this job every Sunday at 00:00.
|
||||
- cron: "0 0 * * 0"
|
||||
|
||||
# Allows you to run this workflow manually from the Actions tab
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
linux:
|
||||
# This job is only useful when run on upstream servo.
|
||||
if: github.repository == 'servo/servo' || github.event_name == 'workflow_dispatch'
|
||||
name: Linux
|
||||
uses: ./.github/workflows/linux.yml
|
||||
with:
|
||||
layout: '2013'
|
||||
wpt: 'sync'
|
||||
unit-tests: false
|
||||
|
||||
linux-layout-2020:
|
||||
# This job is only useful when run on upstream servo.
|
||||
if: github.repository == 'servo/servo' || github.event_name == 'workflow_dispatch'
|
||||
name: Linux (layout-2020)
|
||||
uses: ./.github/workflows/linux.yml
|
||||
with:
|
||||
layout: '2020'
|
||||
wpt: 'sync'
|
||||
unit-tests: false
|
||||
|
||||
sync:
|
||||
# This job is only useful when run on upstream servo.
|
||||
if: github.repository == 'servo/servo' || github.event_name == 'workflow_dispatch'
|
||||
name: Synchronize WPT Nightly
|
||||
runs-on: ubuntu-latest
|
||||
needs:
|
||||
- "linux"
|
||||
- "linux-layout-2020"
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
fetch-depth: 2
|
||||
# Download all artifacts
|
||||
- uses: actions/download-artifact@v3
|
||||
- name: Prep environment
|
||||
run: |
|
||||
python3 -m pip install --upgrade pip virtualenv
|
||||
sudo apt update
|
||||
python3 ./mach bootstrap
|
||||
- name: Add upstream remote
|
||||
run: |
|
||||
git config --local user.email "josh+wptsync@joshmatthews.net"
|
||||
git config --local user.name "WPT Sync Bot"
|
||||
git remote add upstream https://github.com/servo/servo.git
|
||||
git fetch --unshallow upstream
|
||||
- name: Fetch upstream changes before syncing
|
||||
run: |
|
||||
./etc/ci/update-wpt-checkout fetch-upstream-changes
|
||||
- name: Run WPT Update
|
||||
env:
|
||||
MAX_CHUNK_ID: 20
|
||||
WPT_SYNC_TOKEN: ${{ secrets.WPT_SYNC_TOKEN }}
|
||||
run: |
|
||||
export CURRENT_DATE=$(date +"%d-%m-%Y")
|
||||
echo $CURRENT_DATE
|
||||
echo "CURRENT_DATE=$CURRENT_DATE" >> $GITHUB_ENV
|
||||
./etc/ci/wpt-scheduled-update.sh
|
||||
- name: Push changes
|
||||
uses: ad-m/github-push-action@master
|
||||
with:
|
||||
branch: wpt_update_${{ env.CURRENT_DATE }}
|
||||
- name: Open PR
|
||||
env:
|
||||
GH_TOKEN: ${{ secrets.WPT_SYNC_TOKEN }}
|
||||
UPDATE_BRANCH: wpt_update_${{ env.CURRENT_DATE }}
|
||||
run: |
|
||||
BODY=$(cat <<EOF
|
||||
Automated downstream sync of changes from upstream as of ${{ env.CURRENT_DATE }}
|
||||
[no-wpt-sync]
|
||||
r? @servo-wpt-sync
|
||||
EOF
|
||||
)
|
||||
gh pr create \
|
||||
--title "Sync WPT with upstream (${{ env.CURRENT_DATE }})" \
|
||||
--body "$BODY" --head ${{ env.UPDATE_BRANCH }} | xargs gh pr comment $1 --body "@bors-servo r+"
|
Loading…
Add table
Add a link
Reference in a new issue