Skip to content
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 46 additions & 0 deletions .github/workflows/cmake-windows.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
# Build on Windows with CMake and execute tests

name: CMake building Windows

on:
# Triggers the workflow on push or pull request events but only for the master branch
push:
# branches: [master]
# pull_request:
# branches: [master]

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

jobs:
cmake_windows:
runs-on: windows-latest
strategy:
fail-fast: false
matrix:
include:
- args: "-DCMAKE_BUILD_TYPE=Debug -DENABLE_TOOLS=ON"
- args: "-DCMAKE_BUILD_TYPE=Debug -DTINYCBOR_FREESTANDING_BUILD_ENABLED=ON -DENABLE_TOOLS=ON"
- args: "-DCMAKE_BUILD_TYPE=Debug -DUSE_SHARED_TINYCBOR_LIBRARY=ON -DENABLE_TOOLS=ON"
- args: "-DCMAKE_BUILD_TYPE=Debug -DUSE_SHARED_TINYCBOR_LIBRARY=ON -DUSE_STATIC_TINYCBOR_LIBRARY=OFF -DENABLE_TOOLS=ON"
- args: "-DCMAKE_BUILD_TYPE=Release -DENABLE_TOOLS=ON"

steps:
- name: Checkout repository
uses: actions/checkout@v3

# - name: Install Qt5 for tests
# uses: jurplel/install-qt-action/@v3

- name: Configure for MSVC
run: ilammy/msvc-dev-cmd@v1

- name: Build unit tests
run: |
cmake -B build -G Ninja -DCMAKE_VERBOSE_MAKEFILE=ON -DENABLE_TESTING=ON ..
cmake --build build

- name: Run unit tests
run: |
cd build
ctest --verbose