From 1209878a23a534013358bbc3c3e9cea1baec1410 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Eric=20Meadows-J=C3=B6nsson?= Date: Mon, 28 Sep 2026 14:30:19 +0200 Subject: [PATCH] Run mid-scenario requests in the HTTP/1 fuzz property Client operations are {index, :body, ref_index, chunk} or {index, :request, {method, body}}, but the comprehension that picks the operations for the current chunk only matched four-element tuples, so request operations were dropped and no request was ever issued in the middle of a scenario. Operations are now matched on their index whatever their size. --- test/mint/http1/fuzz_test.exs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/mint/http1/fuzz_test.exs b/test/mint/http1/fuzz_test.exs index 21a7cf66..b061dc42 100644 --- a/test/mint/http1/fuzz_test.exs +++ b/test/mint/http1/fuzz_test.exs @@ -308,9 +308,9 @@ defmodule Mint.HTTP1.FuzzTest do defp run_client_ops(conn, state) do ops = - for {index, op, arg1, arg2} <- state.scenario.ops, - index == state.index, - do: {op, arg1, arg2} + for op <- state.scenario.ops, + elem(op, 0) == state.index, + do: Tuple.delete_at(op, 0) Enum.reduce_while(ops, {:open, conn, state}, fn op, {:open, conn, state} -> state = %{state | log: state.log ++ [{:client, op}]}