Skip to content

Fixed copy semantic for non composed layouts (#243) #1523

Fixed copy semantic for non composed layouts (#243)

Fixed copy semantic for non composed layouts (#243) #1523

Workflow file for this run

name: Windows
on:
workflow_dispatch:
pull_request:
push:
branches: [main]
concurrency:
group: ${{ github.workflow }}-${{ github.job }}-${{ github.ref }}
cancel-in-progress: true
defaults:
run:
shell: bash -e -l {0}
jobs:
build:
runs-on: ${{ matrix.runs-on }}
name: ${{ matrix.sys.compiler }} / ${{ matrix.build-system }} / ${{ matrix.config.name }} / date-polyfill ${{ matrix.sys.date-polyfill}}
strategy:
fail-fast: false
matrix:
runs-on: [windows-latest]
sys:
- { compiler: msvc, date-polyfill: 'ON' }
- { compiler: msvc, date-polyfill: 'OFF' }
- { compiler: clang, date-polyfill: 'ON' }
- { compiler: clang, date-polyfill: 'OFF' }
config:
- { name: Debug }
- { name: Release }
build-system:
- "Visual Studio 17 2022"
- "Ninja"
steps:
- name: Setup MSVC
if: matrix.sys.compiler == 'msvc' && matrix.build-system != 'Visual Studio 17 2022'
uses: ilammy/msvc-dev-cmd@v1
- name: Install LLVM and Clang
if: matrix.sys.compiler == 'clang'
uses: egor-tensin/setup-clang@v1
with:
version: ${{matrix.sys.version}}
platform: x64
- name: Setup clang
if: matrix.sys.compiler == 'clang'
run: |
echo "CC=clang" >> $GITHUB_ENV
echo "CXX=clang++" >> $GITHUB_ENV
- name: Checkout code
uses: actions/checkout@v4
- name: Set conda environment
uses: mamba-org/setup-micromamba@main
with:
environment-name: myenv
environment-file: environment-dev.yml
init-shell: bash
cache-downloads: true
create-args: |
ninja
- name: Configure using CMake
run: cmake -Bbuild -DCMAKE_BUILD_TYPE:STRING=${{matrix.config.name}} -DCMAKE_INSTALL_PREFIX=$CONDA_PREFIX -DBUILD_TESTS=ON -DBUILD_EXAMPLES=ON -DUSE_DATE_POLYFILL=${{matrix.sys.date-polyfill}} -G "${{matrix.build-system}}"
- name: Build library
working-directory: build
run: cmake --build . --config ${{matrix.config.name}} --target sparrow --parallel 8
- name: Install
working-directory: build
run: cmake --install . --config ${{matrix.config.name}}
- name: Build tests
working-directory: build
run: cmake --build . --config ${{matrix.config.name}} --target test_sparrow_lib --parallel 8
- name: Run tests
working-directory: build
run: cmake --build . --config ${{matrix.config.name}} --target run_tests_with_junit_report
- name: Upload test results
uses: actions/upload-artifact@v4
if: success() || failure()
with:
name: test_sparrow_lib_report_Windows_${{ matrix.sys.compiler }}_${{ matrix.build-system }}_${{ matrix.config.name }}_date-polyfill_${{ matrix.sys.date-polyfill}}
path: '**/test_sparrow_lib_report.xml'
- name: Run all examples
working-directory: build
run: cmake --build . --config ${{matrix.config.name}} --target run_examples