Adding tests for success exit codes. #131
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Windows Build | |
on: [push, pull_request] | |
jobs: | |
tests: | |
runs-on: windows-2019 | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
submodules: true | |
- uses: ilammy/msvc-dev-cmd@v1 | |
- run: cmake --version | |
- run: nuget ? | |
# cache | |
- name: Cache CMakeCache.txt and Nuget packages | |
uses: actions/cache@v2 | |
with: | |
path: | | |
CMakeCache.txt | |
~/.nuget/packages | |
key: ${{ runner.os }}-cache | |
# install | |
- run: mkdir -Force libs | |
- name: Install dependencies and prepare directory structure for cmake | |
working-directory: libs | |
run: | | |
nuget install boost -ExcludeVersion -Version 1.74.0 | |
mv -Force ./boost/lib/native/include/ ./boost/ | |
nuget install boost_system-vc142 -ExcludeVersion -Version 1.74.0 | |
mv -Force ./boost_system-vc142/lib/native/* ./boost/lib/ | |
nuget install boost_program_options-vc142 -ExcludeVersion -Version 1.74.0 | |
mv -Force ./boost_program_options-vc142/lib/native/* ./boost/lib/ | |
nuget install rmt_zlib -ExcludeVersion -Version 1.2.8.7 | |
nuget install rmt_libssh2 -ExcludeVersion -Version 1.8.0 | |
nuget install rmt_curl -ExcludeVersion -Version 7.51.0 | |
mkdir -Force curl | |
cd curl | |
mkdir -Force include/curl | |
mkdir -Force lib | |
cd .. | |
mv -Force ./rmt_curl/build/native/include/v140/x64/Release/dynamic/* ./curl/include/curl/ | |
mv -Force ./rmt_curl/build/native/lib/v140/x64/Release/dynamic/* ./curl/lib/ | |
nuget install libzmq_vc140 -ExcludeVersion -Version 4.3.2 | |
mkdir -Force libzmq | |
cd libzmq | |
mkdir -Force lib | |
cd .. | |
mv -Force ./libzmq_vc140/build/native/include ./libzmq/ | |
mv -Force ./libzmq_vc140/build/native/bin/libzmq-x64-v140-mt-4_3_2_0.imp.lib ./libzmq/lib/libzmq.lib | |
- working-directory: libs | |
run: Invoke-WebRequest -Uri 'https://curl.haxx.se/ca/cacert.pem' -Outfile "curl-ca-bundle.crt" | |
# build | |
- run: cmake -G "Visual Studio 16 2019" "-DBOOST_ROOT=$Env:GITHUB_WORKSPACE\libs\boost" "-DCURL_LIBRARY=$Env:GITHUB_WORKSPACE\libs\curl\lib\libcurl_imp.lib" "-DCURL_INCLUDE_DIR=$Env:GITHUB_WORKSPACE\libs\curl\include" "-DZMQ_LIBRARY_DIR=$Env:GITHUB_WORKSPACE\libs\libzmq\lib" "-DZMQ_INCLUDE_DIR=$Env:GITHUB_WORKSPACE\libs\libzmq\include" . | |
- run: msbuild "ALL_BUILD.vcxproj" /p:Configuration=Release /m /verbosity:quiet | |
# before_test | |
- name: Move DLLs of libraries to test folder | |
working-directory: libs | |
run: | | |
mv -Force libzmq_vc140/build/native/bin/libzmq-x64-v140-mt-4_3_2_0.dll $Env:GITHUB_WORKSPACE\tests\Release\libzmq.dll | |
mv -Force rmt_curl/build/native/bin/v140/x64/Release/dynamic/* $Env:GITHUB_WORKSPACE\tests\Release\ | |
mv -Force rmt_libssh2/build/native/bin/v140/x64/Release/dynamic/* $Env:GITHUB_WORKSPACE\tests\Release\ | |
mv -Force rmt_zlib/build/native/bin/v140/x64/Release/dynamic/* $Env:GITHUB_WORKSPACE\tests\Release\ | |
mv -Force curl-ca-bundle.crt $Env:GITHUB_WORKSPACE\tests\ | |
# tests | |
- run: ctest -C Release -E tool_ --output-on-failure | |
working-directory: tests | |
- run: ctest -C Release -R tool_ --output-on-failure | |
continue-on-error: true | |
working-directory: tests |