ci: Update swift-code-coverage.yml and drop swift 5.8 build #563
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: Address sanitizer | |
on: | |
workflow_dispatch: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main, next ] | |
jobs: | |
address-sanitizer: | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [macos-14] | |
runs-on: ${{ matrix.os }} | |
timeout-minutes: 60 | |
steps: | |
- name: Homebrew Mac | |
if: ${{ runner.os == 'Macos' }} | |
run: | | |
echo "/opt/homebrew/bin:/usr/local/bin" >> $GITHUB_PATH | |
echo BENCHMARK_DISABLE_JEMALLOC=true >> $GITHUB_ENV | |
brew install jemalloc | |
- name: Ubuntu deps | |
if: ${{ runner.os == 'Linux' }} | |
run: | | |
sudo apt-get install -y libjemalloc-dev | |
- uses: actions/checkout@v4 | |
- name: Start consul | |
uses: ./.github/actions/consul-start | |
- name: Swift version | |
run: swift --version | |
# Required to clean build directory before sanitizer! | |
- name: Clean before debug build sanitizier | |
run: swift package clean | |
- name: Run address sanitizer | |
run: swift test --sanitize=address | |
- name: Clean before release build sanitizier | |
run: swift package clean | |
- name: Run address sanitizer on release build | |
run: swift test --sanitize=address -c release -Xswiftc -enable-testing |