Browse Source

Fix GitHub Actions errors

yhirose 1 year ago
parent
commit
4c2a608a0c
3 changed files with 4 additions and 4 deletions
  1. 2 2
      .github/workflows/test.yaml
  2. 1 1
      test/Makefile
  3. 1 1
      test/test.cc

+ 2 - 2
.github/workflows/test.yaml

@@ -8,8 +8,8 @@ jobs:
     steps:
       - name: checkout
         uses: actions/checkout@v4
-      - name: install brotli
-        run: sudo apt-get update && sudo apt-get install -y libbrotli-dev
+      - name: install libraries
+        run: sudo apt-get update && sudo apt-get install -y libbrotli-dev libcurl4-openssl-dev
       - name: build and run tests
         run: cd test && make -j4
       - name: run fuzz test target

+ 1 - 1
test/Makefile

@@ -18,7 +18,7 @@ ZLIB_SUPPORT = -DCPPHTTPLIB_ZLIB_SUPPORT -lz
 BROTLI_DIR = $(PREFIX)/opt/brotli
 BROTLI_SUPPORT = -DCPPHTTPLIB_BROTLI_SUPPORT -I$(BROTLI_DIR)/include -L$(BROTLI_DIR)/lib -lbrotlicommon -lbrotlienc -lbrotlidec
 
-TEST_ARGS = gtest/gtest-all.cc gtest/gtest_main.cc $(OPENSSL_SUPPORT) $(ZLIB_SUPPORT) $(BROTLI_SUPPORT) -pthread
+TEST_ARGS = gtest/gtest-all.cc gtest/gtest_main.cc $(OPENSSL_SUPPORT) $(ZLIB_SUPPORT) $(BROTLI_SUPPORT) -pthread -lcurl
 
 # By default, use standalone_fuzz_target_runner.
 # This runner does no fuzzing, but simply executes the inputs

+ 1 - 1
test/test.cc

@@ -7614,7 +7614,7 @@ TEST(Expect100ContinueTest, ServerClosesConnection) {
 
   Server svr;
 
-  svr.set_expect_100_continue_handler([](const Request &req, Response &res) {
+  svr.set_expect_100_continue_handler([](const Request &/*req*/, Response &res) {
     res.status = StatusCode::Unauthorized_401;
     res.set_content(reject, "text/plain");
     return res.status;