Skip to content

Commit 6d9c1f4

Browse files
committed
Replace Travis CI with GitHub Actions CI
The coverage matrix is roughly the same: some additional configurations, some removed ones depending on what's available in the new virtual environments. On good side effect is the removal of valgrind-osx.supp from the project's sources.
1 parent b872175 commit 6d9c1f4

File tree

6 files changed

+200
-208
lines changed

6 files changed

+200
-208
lines changed

.github/workflows/build-macos.yml

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
# Copyright (c) 2021 Morwenn
2+
# SPDX-License-Identifier: MIT
3+
4+
name: MacOS Builds
5+
6+
on:
7+
push:
8+
paths:
9+
- '.github/workflows/build-macos.yml'
10+
- 'CMakeLists.txt'
11+
- 'cmake/**'
12+
- 'include/gfx/timsort.hpp'
13+
- 'tests/*'
14+
pull_request:
15+
paths:
16+
- '.github/workflows/build-macos.yml'
17+
- 'CMakeLists.txt'
18+
- 'cmake/**'
19+
- 'include/gfx/timsort.hpp'
20+
- 'tests/*'
21+
22+
jobs:
23+
build:
24+
runs-on: macos-10.15
25+
26+
strategy:
27+
fail-fast: false
28+
matrix:
29+
cxx:
30+
- g++-9
31+
- $(brew --prefix llvm)/bin/clang++ # Clang 11
32+
config:
33+
# Release build
34+
- build_type: Release
35+
# Debug builds
36+
- build_type: Debug
37+
sanitize: address
38+
- build_type: Debug
39+
sanitize: undefined
40+
41+
steps:
42+
- uses: actions/checkout@v2
43+
- uses: seanmiddleditch/gha-setup-ninja@master
44+
45+
- name: Configure CMake
46+
working-directory: ${{runner.workspace}}
47+
run: |
48+
export CXX=${{matrix.cxx}}
49+
cmake -H${{github.event.repository.name}} -Bbuild \
50+
-DCMAKE_CONFIGURATION_TYPES=${{matrix.config.build_type}} \
51+
-DCMAKE_BUILD_TYPE=${{matrix.config.build_type}} \
52+
-DGFX_TIMSORT_SANITIZE=${{matrix.config.sanitize}} \
53+
-GNinja \
54+
-DBUILD_BENCHMARKS=ON
55+
56+
- name: Build the test suite
57+
shell: bash
58+
working-directory: ${{runner.workspace}}/build
59+
run: cmake --build . --config ${{matrix.config.build_type}} -j 2
60+
61+
- name: Run the test suite
62+
env:
63+
CTEST_OUTPUT_ON_FAILURE: 1
64+
working-directory: ${{runner.workspace}}/build
65+
run: ctest -C ${{matrix.config.build_type}}

.github/workflows/build-ubuntu.yml

Lines changed: 82 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,82 @@
1+
# Copyright (c) 2021 Morwenn
2+
# SPDX-License-Identifier: MIT
3+
4+
name: Ubuntu Builds
5+
6+
on:
7+
push:
8+
paths:
9+
- '.github/workflows/build-ubuntu.yml'
10+
- 'CMakeLists.txt'
11+
- 'cmake/**'
12+
- 'include/gfx/timsort.hpp'
13+
- 'tests/*'
14+
pull_request:
15+
paths:
16+
- '.github/workflows/build-ubuntu.yml'
17+
- 'CMakeLists.txt'
18+
- 'cmake/**'
19+
- 'include/gfx/timsort.hpp'
20+
- 'tests/*'
21+
22+
jobs:
23+
build:
24+
runs-on: ubuntu-16.04
25+
26+
strategy:
27+
fail-fast: false
28+
matrix:
29+
cxx:
30+
- g++-5
31+
- clang++-6.0
32+
config:
33+
# Release build
34+
- build_type: Release
35+
# Debug builds
36+
- build_type: Debug
37+
valgrind: ON
38+
- build_type: Debug
39+
sanitize: address
40+
- build_type: Debug
41+
sanitize: undefined
42+
43+
steps:
44+
- uses: actions/checkout@v2
45+
46+
- name: Install Valgrind
47+
if: ${{matrix.config.valgrind == 'ON'}}
48+
run: sudo apt install -y valgrind
49+
50+
- name: Configure CMake
51+
working-directory: ${{runner.workspace}}
52+
env:
53+
CXX: ${{matrix.cxx}}
54+
run: |
55+
cmake -H${{github.event.repository.name}} -Bbuild \
56+
-DCMAKE_CONFIGURATION_TYPES=${{matrix.config.build_type}} \
57+
-DCMAKE_BUILD_TYPE=${{matrix.config.build_type}} \
58+
-DGFX_TIMSORT_SANITIZE=${{matrix.config.sanitize}} \
59+
-DGFX_TIMSORT_USE_VALGRIND=${{matrix.config.valgrind}} \
60+
-G"Unix Makefiles" \
61+
-DBUILD_BENCHMARKS=ON
62+
63+
- name: Build the test suite
64+
shell: bash
65+
working-directory: ${{runner.workspace}}/build
66+
run: cmake --build . --config ${{matrix.config.build_type}} -j 2
67+
68+
- name: Run the test suite
69+
if: ${{matrix.config.valgrind != 'ON'}}
70+
env:
71+
CTEST_OUTPUT_ON_FAILURE: 1
72+
working-directory: ${{runner.workspace}}/build
73+
run: ctest -C ${{matrix.config.build_type}}
74+
75+
- name: Run the test suite with Memcheck
76+
if: ${{matrix.config.valgrind == 'ON'}}
77+
env:
78+
CTEST_OUTPUT_ON_FAILURE: 1
79+
working-directory: ${{runner.workspace}}/build
80+
run: |
81+
ctest -T memcheck -C ${{matrix.config.build_type}} -j 2
82+
find ./Testing/Temporary -name "MemoryChecker.*.log" -size +1300c | xargs cat;
Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
# Copyright (c) 2021 Morwenn
2+
# SPDX-License-Identifier: MIT
3+
4+
name: Windows Builds
5+
6+
on:
7+
push:
8+
paths:
9+
- '.github/workflows/build-windows.yml'
10+
- 'CMakeLists.txt'
11+
- 'cmake/**'
12+
- 'include/gfx/timsort.hpp'
13+
- 'tests/*'
14+
pull_request:
15+
paths:
16+
- '.github/workflows/build-windows.yml'
17+
- 'CMakeLists.txt'
18+
- 'cmake/**'
19+
- 'include/gfx/timsort.hpp'
20+
- 'tests/*'
21+
22+
jobs:
23+
build:
24+
runs-on: windows-2016
25+
26+
strategy:
27+
fail-fast: false
28+
matrix:
29+
build_type: [Debug, Release]
30+
cmake_generator: ['MinGW Makefiles', 'Visual Studio 15 2017 Win64']
31+
32+
steps:
33+
- uses: actions/checkout@v2
34+
35+
- name: Configure CMake
36+
shell: pwsh
37+
working-directory: ${{runner.workspace}}
38+
run: |
39+
cmake -H${{github.event.repository.name}} -Bbuild `
40+
-DCMAKE_CONFIGURATION_TYPES=${{matrix.build_type}} `
41+
-DCMAKE_BUILD_TYPE=${{matrix.build_type}} `
42+
-G"${{matrix.cmake_generator}}" `
43+
-DBUILD_BENCHMARKS=ON
44+
45+
- name: Build the test suite
46+
working-directory: ${{runner.workspace}}/build
47+
run: cmake --build . --config ${{matrix.build_type}} -j 2
48+
49+
- name: Run the test suite
50+
env:
51+
CTEST_OUTPUT_ON_FAILURE: 1
52+
working-directory: ${{runner.workspace}}/build
53+
run: ctest -C ${{matrix.build_type}}

.travis.yml

Lines changed: 0 additions & 178 deletions
This file was deleted.

README.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
[![Latest Release](https://img.shields.io/badge/release-cpp--TimSort%2F2.0.1-blue.svg)](https://github.com/timsort/cpp-TimSort/releases/tag/v2.0.1)
22
[![Conan Package](https://img.shields.io/badge/conan-2.0.1-blue.svg)](https://conan.io/center/timsort?version=2.0.1)
3-
[![Build Status](https://travis-ci.org/timsort/cpp-TimSort.svg?branch=master)](https://travis-ci.org/timsort/cpp-TimSort)
43
[![License](https://img.shields.io/:license-mit-yellow.svg)](https://doge.mit-license.org)
54

65
## TimSort

0 commit comments

Comments
 (0)