Skip to content

Commit 97a8550

Browse files
authored
Using docker images to execut the github actions for testing (#335)
Introduce github action-based test workflow for Ubuntu.
1 parent c9521a8 commit 97a8550

File tree

1 file changed

+47
-0
lines changed

1 file changed

+47
-0
lines changed
Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: Build and Test - Linux Docker
2+
3+
on: [ push, pull_request ]
4+
5+
jobs:
6+
build:
7+
8+
# ubuntu-latest will be shortly upgrading to this
9+
runs-on: ubuntu-20.04
10+
11+
strategy:
12+
fail-fast: false
13+
matrix:
14+
python: [ python, python3 ]
15+
cxx: [ g++, clang++ ]
16+
std: [ c++98, c++11]
17+
include:
18+
# Add the appropriate docker image for each compiler.
19+
# The images from teeks99/boost-python-test already have boost::python
20+
# pre-reqs installed, see:
21+
# https://github.com/teeks99/boost-python-test-docker
22+
- cxx: clang++
23+
docker-img: teeks99/boost-python-test:clang-11_1.66.0
24+
- cxx: g++
25+
docker-img: teeks99/boost-python-test:gcc-9_1.66.0
26+
27+
container:
28+
image: ${{ matrix.docker-img }}
29+
30+
steps:
31+
- uses: actions/checkout@v2
32+
33+
- name: Test
34+
run: |
35+
${{ matrix.python }} --version
36+
${{ matrix.cxx }} --version
37+
faber -v
38+
ls -l ${BOOST_PY_DEPS}
39+
40+
sed -e "s/\$PYTHON/${{ matrix.python }}/g" .ci/faber > ~/.faber
41+
42+
faber \
43+
--with-boost-include=${BOOST_PY_DEPS} \
44+
--builddir=build test.report \
45+
cxx.name=${{ matrix.cxx }} \
46+
cxxflags=-std=${{ matrix.std }} \
47+
-j`nproc`

0 commit comments

Comments
 (0)