Skip to content

Use GTest to structure unit tests. #207

Use GTest to structure unit tests.

Use GTest to structure unit tests. #207

Workflow file for this run

name: test-windows
on:
push:
branches: [ dev, main ]
# Run tests once a week on Sunday.
schedule:
- cron: "0 6 * * 0"
permissions:
contents: read
env:
CMAKE_BUILD_TYPE: Release
CMAKE_GENERATOR: Visual Studio 17 2022
CMAKE_GENERATOR_PLATFORM: x64
CMAKE_TOOLCHAIN_FILE: C:/vcpkg/scripts/buildsystems/vcpkg.cmake
CTEST_OUTPUT_ON_FAILURE: True
VCPKG_DEFAULT_TRIPLET: x64-windows
# Avoid the just-in-time debugger where possible when running tests.
ARCH_AVOID_JIT: True
jobs:
test-windows:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Create Build Environment
run: |
vcpkg install gtest
cmake -E make_directory ${{github.workspace}}/build
- name: Configure
working-directory: ${{github.workspace}}/build
run: cmake -D "BUILD_DOCS=OFF" -D "ENABLE_PRECOMPILED_HEADERS=ON" ..
- name: Build
working-directory: ${{github.workspace}}/build
run: cmake --build . --config Release
- name: Test
working-directory: ${{github.workspace}}/build
run: ctest -VV -C Release