Skip to content

Commit 9a89229

Browse files
committed
Add zstd to CI tests
1 parent 290eb0a commit 9a89229

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

.github/workflows/test.yaml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ jobs:
5151
- name: checkout
5252
uses: actions/checkout@v4
5353
- name: install libraries
54-
run: sudo apt-get update && sudo apt-get install -y libbrotli-dev libcurl4-openssl-dev
54+
run: sudo apt-get update && sudo apt-get install -y libbrotli-dev libcurl4-openssl-dev libzstd-dev
5555
- name: build and run tests
5656
run: cd test && make
5757
- name: run fuzz test target
@@ -103,7 +103,7 @@ jobs:
103103
- name: Setup msbuild on windows
104104
uses: microsoft/setup-msbuild@v2
105105
- name: Install vcpkg dependencies
106-
run: vcpkg install gtest curl zlib brotli
106+
run: vcpkg install gtest curl zlib brotli zstd
107107
- name: Install OpenSSL
108108
if: ${{ matrix.config.with_ssl }}
109109
run: choco install openssl
@@ -115,6 +115,7 @@ jobs:
115115
-DHTTPLIB_TEST=ON
116116
-DHTTPLIB_REQUIRE_ZLIB=ON
117117
-DHTTPLIB_REQUIRE_BROTLI=ON
118+
-DHTTPLIB_REQUIRE_ZSTD=ON
118119
-DHTTPLIB_REQUIRE_OPENSSL=${{ matrix.config.with_ssl && 'ON' || 'OFF' }}
119120
- name: Build ${{ matrix.config.name }}
120121
run: cmake --build build --config Release -- /v:m /clp:ShowCommandLine

test/Makefile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,9 @@ ZLIB_SUPPORT = -DCPPHTTPLIB_ZLIB_SUPPORT -lz
1818
BROTLI_DIR = $(PREFIX)/opt/brotli
1919
BROTLI_SUPPORT = -DCPPHTTPLIB_BROTLI_SUPPORT -I$(BROTLI_DIR)/include -L$(BROTLI_DIR)/lib -lbrotlicommon -lbrotlienc -lbrotlidec
2020

21-
TEST_ARGS = gtest/gtest-all.cc gtest/gtest_main.cc $(OPENSSL_SUPPORT) $(ZLIB_SUPPORT) $(BROTLI_SUPPORT) -pthread -lcurl
21+
ZSTD_SUPPORT = -DCPPHTTPLIB_ZSTD_SUPPORT -lzstd
22+
23+
TEST_ARGS = gtest/gtest-all.cc gtest/gtest_main.cc $(OPENSSL_SUPPORT) $(ZLIB_SUPPORT) $(BROTLI_SUPPORT) $(ZSTD_SUPPORT) -pthread -lcurl
2224

2325
# By default, use standalone_fuzz_target_runner.
2426
# This runner does no fuzzing, but simply executes the inputs

0 commit comments

Comments
 (0)