1111 - name : install libraries
1212 run : sudo apt-get update && sudo apt-get install -y libbrotli-dev libcurl4-openssl-dev
1313 - name : build and run tests
14- run : cd test && make -j4
14+ run : cd test && make
1515 - name : run fuzz test target
1616 run : cd test && make fuzz_test
1717
@@ -21,23 +21,45 @@ jobs:
2121 - name : checkout
2222 uses : actions/checkout@v4
2323 - name : build and run tests
24- run : |
25- cd test && make -j2
24+ run : cd test && make
25+ - name : run fuzz test target
26+ run : cd test && make fuzz_test
2627
2728 windows :
2829 runs-on : windows-latest
2930 steps :
30- - name : prepare git for checkout on windows
31+ - name : Prepare Git for Checkout on Windows
3132 run : |
3233 git config --global core.autocrlf false
3334 git config --global core.eol lf
34- - name : checkout
35+ - name : Checkout
3536 uses : actions/checkout@v4
36- - name : setup msbuild on windows
37+ - name : Export GitHub Actions cache environment variables
38+ uses : actions/github-script@v7
39+ with :
40+ script : |
41+ core.exportVariable('ACTIONS_CACHE_URL', process.env.ACTIONS_CACHE_URL || '');
42+ core.exportVariable('ACTIONS_RUNTIME_TOKEN', process.env.ACTIONS_RUNTIME_TOKEN || '');
43+ - name : Setup msbuild on windows
3744 uses : microsoft/setup-msbuild@v2
38- - name : make-windows
45+ - name : Install libraries
3946 run : |
40- cd test
41- msbuild.exe test.sln /verbosity:minimal /t:Build "/p:Configuration=Release;Platform=x64"
42- x64\Release\test.exe
47+ vcpkg install gtest curl zlib brotli
48+ choco install openssl
49+
50+ - name : Configure CMake with SSL
51+ run : cmake -B build -S . -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE=${{ env.VCPKG_ROOT }}/scripts/buildsystems/vcpkg.cmake -DHTTPLIB_TEST=ON -DHTTPLIB_REQUIRE_OPENSSL=ON -DHTTPLIB_REQUIRE_ZLIB=ON -DHTTPLIB_REQUIRE_BROTLI=ON
52+ - name : Build with with SSL
53+ run : cmake --build build --config Release
54+ - name : Run tests with SSL
55+ run : ctest --output-on-failure --test-dir build -C Release
4356
57+ - name : Configure CMake without SSL
58+ run : cmake -B build-no-ssl -S . -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE=${{ env.VCPKG_ROOT }}/scripts/buildsystems/vcpkg.cmake -DHTTPLIB_TEST=ON -DHTTPLIB_REQUIRE_OPENSSL=ON -DHTTPLIB_REQUIRE_ZLIB=ON -DHTTPLIB_REQUIRE_BROTLI=ON
59+ - name : Build without SSL
60+ run : cmake --build build-no-ssl --config Release
61+ - name : Run tests without SSL
62+ run : ctest --output-on-failure --test-dir build-no-ssl -C Release
63+ env :
64+ VCPKG_ROOT : " C:/vcpkg"
65+ VCPKG_BINARY_SOURCES : " clear;x-gha,readwrite"
0 commit comments