Skip to content

Enable address sanitizer in debug builds #161

Enable address sanitizer in debug builds

Enable address sanitizer in debug builds #161

Workflow file for this run

# Copyright (c) Team CharLS.
# SPDX-License-Identifier: BSD-3-Clause
name: Build and test
on: [push]
env:
# Path to the solution file relative to the root of the project.
SOLUTION_FILE_PATH: .
jobs:
build:
runs-on: windows-2022
strategy:
matrix:
buildPlatform: [x64, x86]
buildConfiguration: [Release, Debug]
steps:
- uses: actions/checkout@v4
- name: Add MSBuild to PATH
uses: microsoft/setup-msbuild@v2
- name: Setup VSTest path
uses: darenm/Setup-VSTest@v1
- name: Restore NuGet packages
working-directory: ${{env.GITHUB_WORKSPACE}}
run: nuget restore ${{env.SOLUTION_FILE_PATH}}
- name: Build
working-directory: ${{env.GITHUB_WORKSPACE}}
run: msbuild /v:m /m /p:Configuration=${{matrix.buildConfiguration}} /p:Platform=${{matrix.buildPlatform}} ${{env.SOLUTION_FILE_PATH}} /p:NETPBM_WIC_CODEC_ALL_WARNINGS=true
- name: Test
working-directory: .\build\binaries\${{matrix.buildPlatform}}\${{matrix.buildConfiguration}}\
run: vstest.console.exe /Platform:${{matrix.buildPlatform}} test.dll