Skip to content

Tests-Mac

Tests-Mac #55

Workflow file for this run

name: Tests-Mac
on:
push:
branches:
- main
pull_request: {}
schedule:
- cron: '0 23 * * SUN-THU'
workflow_dispatch:
jobs:
tests:
runs-on: macos-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Upgrade homebrew
run: |
brew update
continue-on-error: true
- name: Install llvm
run: |
brew install llvm
continue-on-error: true
- name: Install cmake
run: |
brew install cmake
continue-on-error: true
- name: Install ninja
run: |
brew install ninja
continue-on-error: true
- name: Cmake and Compile
run: |
cmake -B build -S . -DARGO_TESTS_ENABLE=true -GNinja
cmake --build build
env:
CC: /usr/local/opt/llvm/bin/clang
CXX: /usr/local/opt/llvm/bin/clang++
LDFLAGS: -L/usr/local/opt/llvm/lib -L/usr/local/opt/llvm/lib/c++ -Wl,-rpath,/usr/local/opt/llvm/lib/c++
CPPFLAGS: -I/usr/local/opt/llvm/include
- name: Test Release
run: |
./build/test-argo-release
- name: Test Debug with codecov
run: |
LLVM_PROFILE_FILE=./build/test-argo-debug.profraw ./build/test-argo-debug
/usr/local/opt/llvm/bin/llvm-profdata merge -sparse ./build/test-argo-debug.profraw -o ./build/coverage.profdata
/usr/local/opt/llvm/bin/llvm-cov show ./build/test-argo-debug -instr-profile=./build/coverage.profdata -ignore-filename-regex="tests*" -ignore-filename-regex="Argo/ArgoExceptions.cc" > ./build/coverage.txt
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
with:
files: ./build/coverage.txt
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}