GH actions: split CI and coveralls

This commit is contained in:
Michele Caini
2019-09-24 11:41:22 +02:00
parent 84d468333a
commit f5c231aa80
3 changed files with 39 additions and 33 deletions

View File

@@ -29,38 +29,6 @@ jobs:
CTEST_OUTPUT_ON_FAILURE: 1
run: ctest --timeout 5 -C Debug -j4
coveralls:
timeout-minutes: 5
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Compile tests
working-directory: build
env:
CXXFLAGS: "-O0 --coverage -fno-inline -fno-inline-small-functions -fno-default-inline"
CXX: g++
run: |
cmake -DBUILD_TESTING=ON -DBUILD_LIB=ON ..
make -j4
- name: Run tests
working-directory: build
env:
CTEST_OUTPUT_ON_FAILURE: 1
run: ctest --timeout 5 -C Debug -j4
- name: Setup Python
uses: actions/setup-python@master
with:
version: 3.7
- name: Update coveralls
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
run: |
pip install --upgrade wheel
pip install cpp-coveralls
coveralls --gcov gcov-7 --gcov-options '\-lp' -r . -b ./build -x cpp -x hpp -e ./deps -i ./src
windows:
timeout-minutes: 5

37
.github/workflows/coveralls.yml vendored Normal file
View File

@@ -0,0 +1,37 @@
name: coveralls
on: [push, pull_request]
jobs:
coveralls:
timeout-minutes: 5
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Compile tests
working-directory: build
env:
CXXFLAGS: "-O0 --coverage -fno-inline -fno-inline-small-functions -fno-default-inline"
CXX: g++
run: |
cmake -DBUILD_TESTING=ON -DBUILD_LIB=ON ..
make -j4
- name: Run tests
working-directory: build
env:
CTEST_OUTPUT_ON_FAILURE: 1
run: ctest --timeout 5 -C Debug -j4
- name: Setup Python
uses: actions/setup-python@master
with:
version: 3.7
- name: Update coveralls
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
run: |
pip install --upgrade wheel
pip install cpp-coveralls
coveralls --gcov gcov-7 --gcov-options '\-lp' -r . -b ./build -x cpp -x hpp -e ./deps -i ./src

View File

@@ -222,7 +222,8 @@ endif()
add_custom_target(
entt_aob
SOURCES
.github/workflows/main.yml
.github/workflows/ci.yml
.github/workflows/coveralls.yml
.github/FUNDING.yml
appveyor.yml
AUTHORS