Merge d968e63280956b3a636d2c2e52e9132a246b411e into 04995f68e470a18d1fc99f86fa326c2a87bab4f2

This commit is contained in:
Jozef Koval 2026-11-02 23:42:20 +01:00 committed by GitHub
commit 68215507e6
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 24 additions and 16 deletions

View File

@ -6,6 +6,12 @@ on:
- main
pull_request:
# A new push to a PR cancels the PR's older run. Other events get the run id
# as a unique group, so a run on main is never cancelled.
concurrency:
group: dead-code-${{ github.event.pull_request.number || github.run_id }}
cancel-in-progress: true
jobs:
periphery:
name: Periphery scan

View File

@ -6,6 +6,12 @@ on:
- main
pull_request:
# A new push to a PR cancels the PR's older run. Other events get the run id
# as a unique group, so a run on main is never cancelled.
concurrency:
group: build-and-test-${{ github.event.pull_request.number || github.run_id }}
cancel-in-progress: true
jobs:
test:
name: Run Swift Tests (${{ matrix.name }})
@ -36,24 +42,16 @@ jobs:
# the runner image. A standalone swift.org toolchain (setup-swift) broke
# whenever the image's Xcode moved ahead of it ("this SDK is not
# supported by the compiler").
- name: Note toolchain version (cache key)
id: swift-version
run: echo "version=$(swift --version 2>/dev/null | head -1 | shasum | cut -c1-12)" >> "$GITHUB_OUTPUT"
- name: Cache build artifacts
uses: actions/cache@v4
with:
path: ${{ matrix.path }}/.build
key: ${{ runner.os }}-${{ steps.swift-version.outputs.version }}-${{ matrix.name }}-${{ hashFiles(format('{0}/**/*.swift', matrix.path), format('{0}/**/Package.resolved', matrix.path)) }}
restore-keys: |
${{ runner.os }}-${{ steps.swift-version.outputs.version }}-${{ matrix.name }}-${{ hashFiles(format('{0}/**/Package.resolved', matrix.path)) }}
${{ runner.os }}-${{ steps.swift-version.outputs.version }}-${{ matrix.name }}-
- name: Show toolchain version
run: swift --version
# No .build cache: on a hit, SwiftPM still recompiled every module, and
# restoring and saving the cache took about 35 s in the app job.
- name: Build tests
# Built separately so the hang watchdog below times only test
# execution: a cold-cache coverage build on a slow runner can
# execution: a cold coverage build on a slow runner can
# legitimately take several minutes, and is already bounded by the
# 15-minute job timeout.
# 25-minute job timeout.
run: swift build --build-tests --enable-code-coverage --package-path ${{ matrix.path }}
- name: Run Tests
@ -253,6 +251,8 @@ jobs:
echo "Using iPhone simulator destination id: $destination_id"
echo "id=$destination_id" >> "$GITHUB_OUTPUT"
# Coverage and the index store are off, because no step reads them. The
# SwiftPM job already gates the benchmarks, so they are skipped here.
- name: Run iOS tests
run: |
set -o pipefail
@ -261,6 +261,9 @@ jobs:
-sdk iphonesimulator \
-destination "platform=iOS Simulator,id=${{ steps.destination.outputs.id }}" \
-parallel-testing-enabled NO \
-enableCodeCoverage NO \
-skip-testing:bitchatTests_iOS/PerformanceBaselineTests \
COMPILER_INDEX_STORE_ENABLE=NO \
CODE_SIGNING_ALLOWED=NO \
test

View File

@ -18,8 +18,7 @@ on:
permissions:
contents: read
# A superseded run has nothing left to report; the sibling PR workflows do not
# set this, so drop it if the repo prefers them uniform.
# A superseded run has nothing left to report.
concurrency:
group: validate-georelays-${{ github.ref }}
cancel-in-progress: true