Skip to content

start working on docs #38

start working on docs

start working on docs #38

Workflow file for this run

name: Windows MSVC Tests
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
build-and-test:
runs-on: windows-2025-vs2026
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Clone vcpkg
run: git clone https://github.com/microsoft/vcpkg.git vcpkg
- name: Bootstrap vcpkg
run: .\vcpkg\bootstrap-vcpkg.bat
- name: Get MSVC version
id: msvc
shell: pwsh
run: |
$vswhere = "${env:ProgramFiles(x86)}\Microsoft Visual Studio\Installer\vswhere.exe"
$installPath = & $vswhere -latest -products * -requires Microsoft.VisualStudio.Component.VC.Tools.x86.x64 -property installationPath
if (-not $installPath) {
throw "Visual Studio with C++ tools not found"
}
$msvcDir = Join-Path $installPath "VC\Tools\MSVC"
$version = (Get-ChildItem $msvcDir | Sort-Object Name -Descending | Select-Object -First 1).Name
"version=$version" >> $env:GITHUB_OUTPUT
- name: Cache vcpkg
uses: actions/cache@v4
with:
path: |
${{ github.workspace }}/vcpkg_installed
key: vcpkg-${{ runner.os }}-${{ steps.msvc.outputs.version }}-${{ hashFiles('vcpkg.json') }}
restore-keys: |
vcpkg-${{ runner.os }}-${{ steps.msvc.outputs.version }}-
vcpkg-${{ runner.os }}-
- name: Configure VCPKG_ROOT env var
run: echo "VCPKG_ROOT=${{ github.workspace }}\vcpkg" >> $env:GITHUB_ENV
- name: Set up MSBuild
uses: microsoft/setup-msbuild@v2
- name: Build solution
run: msbuild dataforge.slnx /p:Configuration=Release
- name: Run tests
run: |
cd x64/Release
$env:PATH += ";${{ github.workspace }}\vcpkg_installed\x64-windows\bin"
.\dataforge_tests.exe