Skip to content

Start working

Start working #21

Workflow file for this run

name: C++ Tests
on:
push:
branches: [ main, master ]
pull_request:
jobs:
cpp-tests:
name: C++ tests (gcc)
runs-on: ubuntu-latest
container:
image: fedora:43
env:
SERIAL_TEST_PORT: /tmp/ttyCI_A
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install build dependencies (gcc)
run: |
dnf -y update
dnf -y install cmake ninja-build gcc-c++ socat git
- name: Configure CMake
env:
CXX: g++
run: |
cmake -S . -B build -G Ninja -DCMAKE_BUILD_TYPE=Release
- name: Build
run: |
cmake --build build --config Release
- name: Start virtual serial echo (socat)
run: |
socat -d -d pty,raw,echo=0,link=/tmp/ttyCI_A,mode=666 pty,raw,echo=0,link=/tmp/ttyCI_B,mode=666 &
sleep 2
stdbuf -i0 -o0 cat < /tmp/ttyCI_B > /tmp/ttyCI_B &
sleep 1
- name: Run C++ unit/integration tests
working-directory: build
env:
SERIAL_TEST_PORT: /tmp/ttyCI_A
run: |
./cpp_bindings_linux_tests --gtest_color=yes