mirror of
https://github.com/servo/servo.git
synced 2025-06-06 16:45:39 +00:00
* Run main and try jobs with debug assertions * use single quotes in workflow expressions * set force-debug-assertions in main.yml * set force-debug-assertions as part of decision job * fix typo in MachCommands.build * fix more hardcoded profile names * fix tidy * split cargo_profile_option on windows * Fix running servoshell and unit tests through a symlink * rename steps to make them less confusing * fix more hardcoded cargo profile options * fix missing inputs in linux-wpt and mac-wpt * make filename an inherent method of Resource * rework release-with-debug-assertions profile to production profile * rework resource logic to eliminate std_test_override * set production flag in nightly release builds * clean up servobuild.example and windows.yml * oops forgot to check in embedder_traits/build.rs * fix mach test-unit behaviour through symlink * unit tests only need current_dir and ancestors * fix macOS package smoketest breakage * expect css/css-color/currentcolor-003 to crash under layout 2013 * fix more references to {force,release-with}-debug-assertions * fix local build failures under --profile production
103 lines
3.5 KiB
YAML
103 lines
3.5 KiB
YAML
---
|
|
name: Mac WPT Tests
|
|
on:
|
|
workflow_call:
|
|
inputs:
|
|
production:
|
|
required: false
|
|
type: boolean
|
|
layout:
|
|
required: true
|
|
type: string
|
|
|
|
env:
|
|
cargo_profile_option: ${{ inputs.production && '--profile production' || '--release' }}
|
|
RUST_BACKTRACE: 1
|
|
SHELL: /bin/bash
|
|
WPT_COMMAND_LINE_ARG: "${{ inputs.layout == 'layout-2013' && '--legacy-layout' || '' }}"
|
|
|
|
jobs:
|
|
mac-wpt:
|
|
name: WPT ${{ inputs.layout }}
|
|
runs-on: macos-13
|
|
env:
|
|
max_chunk_id: 5
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
chunk_id: [1, 2, 3, 4, 5]
|
|
steps:
|
|
- uses: actions/checkout@v3
|
|
if: github.event_name != 'issue_comment'
|
|
with:
|
|
fetch-depth: 2
|
|
# This is necessary to checkout the pull request if this run was triggered
|
|
# via an `issue_comment` action on a pull request.
|
|
- uses: actions/checkout@v3
|
|
if: github.event_name == 'issue_comment'
|
|
with:
|
|
ref: refs/pull/${{ github.event.issue.number }}/head
|
|
fetch-depth: 2
|
|
- uses: actions/download-artifact@v3
|
|
with:
|
|
name: release-binary-macos
|
|
- name: Prep test environment
|
|
run: |
|
|
gtar -xzf target.tar.gz
|
|
python3 -m pip install --upgrade pip virtualenv
|
|
python3 ./mach bootstrap
|
|
- name: Smoketest
|
|
run: python3 ./mach smoketest ${cargo_profile_option}
|
|
- name: Run tests
|
|
run: |
|
|
python3 ./mach test-wpt $WPT_COMMAND_LINE_ARG \
|
|
${cargo_profile_option} --processes $(sysctl -n hw.logicalcpu) --timeout-multiplier 8 \
|
|
--total-chunks ${{ env.max_chunk_id }} --this-chunk ${{ matrix.chunk_id }} \
|
|
--log-raw test-wpt.${{ matrix.chunk_id }}.log \
|
|
--log-raw-unexpected unexpected-test-wpt.${{ matrix.chunk_id }}.log \
|
|
--filter-intermittents filtered-test-wpt.${{ matrix.chunk_id }}.json
|
|
- name: Archive filtered results
|
|
uses: actions/upload-artifact@v3
|
|
if: always()
|
|
with:
|
|
name: wpt-filtered-results-mac-${{ inputs.layout }}
|
|
path: |
|
|
filtered-test-wpt.${{ matrix.chunk_id }}.json
|
|
unexpected-test-wpt.${{ matrix.chunk_id }}.log
|
|
- name: Archive logs
|
|
uses: actions/upload-artifact@v3
|
|
if: failure()
|
|
with:
|
|
name: wpt-logs-mac-${{ inputs.layout }}
|
|
path: |
|
|
test-wpt.${{ matrix.chunk_id }}.log
|
|
filtered-wpt-results.${{ matrix.chunk_id }}.json
|
|
|
|
report-test-results:
|
|
name: Reporting test results
|
|
runs-on: ubuntu-latest
|
|
if: ${{ always() && !cancelled() }}
|
|
needs: [ mac-wpt ]
|
|
steps:
|
|
- uses: actions/checkout@v3
|
|
with:
|
|
fetch-depth: 2
|
|
- uses: actions/download-artifact@v3
|
|
with:
|
|
name: wpt-filtered-results-mac-${{ inputs.layout }}
|
|
path: wpt-filtered-results-mac
|
|
- name: Create aggregated unexpected results
|
|
run: cat wpt-filtered-results-mac/*.log > unexpected-test-wpt.log
|
|
- name: Archive aggregate results
|
|
uses: actions/upload-artifact@v3
|
|
with:
|
|
name: wpt-filtered-results-mac-${{ inputs.layout }}
|
|
path: |
|
|
unexpected-test-wpt.log
|
|
- name: Comment on PR with results
|
|
run: etc/ci/report_aggregated_expected_results.py --tag="mac-wpt-${{ inputs.layout }}"
|
|
wpt-filtered-results-mac/*.json
|
|
env:
|
|
GITHUB_CONTEXT: ${{ toJson(github) }}
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
RESULTS: ${{ toJson(needs.*.result) }}
|