Skip to content

Commit

Permalink
Use arity-1 struct_like matcher
Browse files Browse the repository at this point in the history
  • Loading branch information
mtrudel committed Jan 30, 2025
1 parent 5879549 commit fcd80bc
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 23 deletions.
2 changes: 1 addition & 1 deletion mix.lock
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"finch": {:hex, :finch, "0.19.0", "c644641491ea854fc5c1bbaef36bfc764e3f08e7185e1f084e35e0672241b76d", [:mix], [{:mime, "~> 1.0 or ~> 2.0", [hex: :mime, repo: "hexpm", optional: false]}, {:mint, "~> 1.6.2 or ~> 1.7", [hex: :mint, repo: "hexpm", optional: false]}, {:nimble_options, "~> 0.4 or ~> 1.0", [hex: :nimble_options, repo: "hexpm", optional: false]}, {:nimble_pool, "~> 1.1", [hex: :nimble_pool, repo: "hexpm", optional: false]}, {:telemetry, "~> 0.4 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "fc5324ce209125d1e2fa0fcd2634601c52a787aff1cd33ee833664a5af4ea2b6"},
"hpax": {:hex, :hpax, "1.0.2", "762df951b0c399ff67cc57c3995ec3cf46d696e41f0bba17da0518d94acd4aac", [:mix], [], "hexpm", "2f09b4c1074e0abd846747329eaa26d535be0eb3d189fa69d812bfb8bfefd32f"},
"jason": {:hex, :jason, "1.4.4", "b9226785a9aa77b6857ca22832cffa5d5011a667207eb2a0ad56adb5db443b8a", [:mix], [{:decimal, "~> 1.0 or ~> 2.0", [hex: :decimal, repo: "hexpm", optional: true]}], "hexpm", "c5eb0cab91f094599f94d55bc63409236a8ec69a21a67814529e8d5f6cc90b3b"},
"machete": {:hex, :machete, "0.3.6", "7adaae842c122880da08707b8f0cc45b392fbe26080b29c495f4f462754c2a72", [:mix], [{:jason, "~> 1.4", [hex: :jason, repo: "hexpm", optional: false]}], "hexpm", "b8f9bf890131d259a18594aef5f64aa92c615e518d2bc3bf200d1d2ecfdd0886"},
"machete": {:hex, :machete, "0.3.7", "4af5d4098fb550af27d35512c6addb76ca679d08b5e9f6240313c661a0a18e69", [:mix], [{:jason, "~> 1.4", [hex: :jason, repo: "hexpm", optional: false]}], "hexpm", "a762ea518da51b3d18063886689262024252876648c8e21c16bc41cbf5ed890c"},
"makeup": {:hex, :makeup, "1.2.1", "e90ac1c65589ef354378def3ba19d401e739ee7ee06fb47f94c687016e3713d1", [:mix], [{:nimble_parsec, "~> 1.4", [hex: :nimble_parsec, repo: "hexpm", optional: false]}], "hexpm", "d36484867b0bae0fea568d10131197a4c2e47056a6fbe84922bf6ba71c8d17ce"},
"makeup_elixir": {:hex, :makeup_elixir, "1.0.1", "e928a4f984e795e41e3abd27bfc09f51db16ab8ba1aebdba2b3a575437efafc2", [:mix], [{:makeup, "~> 1.0", [hex: :makeup, repo: "hexpm", optional: false]}, {:nimble_parsec, "~> 1.2.3 or ~> 1.3", [hex: :nimble_parsec, repo: "hexpm", optional: false]}], "hexpm", "7284900d412a3e5cfd97fdaed4f5ed389b8f2b4cb49efc0eb3bd10e2febf9507"},
"makeup_erlang": {:hex, :makeup_erlang, "1.0.1", "c7f58c120b2b5aa5fd80d540a89fdf866ed42f1f3994e4fe189abebeab610839", [:mix], [{:makeup, "~> 1.0", [hex: :makeup, repo: "hexpm", optional: false]}], "hexpm", "8a89a1eeccc2d798d6ea15496a6e4870b75e014d1af514b1b71fa33134f57814"},
Expand Down
22 changes: 11 additions & 11 deletions test/bandit/http1/plug_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -404,7 +404,7 @@ defmodule HTTP1PlugTest do
~> %{
connection_telemetry_span_context: reference(),
telemetry_span_context: reference(),
conn: struct_like(Plug.Conn, []),
conn: struct_like(Plug.Conn),
plug: {__MODULE__, []}
}
end
Expand All @@ -428,7 +428,7 @@ defmodule HTTP1PlugTest do
~> %{
connection_telemetry_span_context: reference(),
telemetry_span_context: reference(),
conn: struct_like(Plug.Conn, []),
conn: struct_like(Plug.Conn),
plug: {__MODULE__, []}
}
end
Expand Down Expand Up @@ -456,7 +456,7 @@ defmodule HTTP1PlugTest do
~> %{
connection_telemetry_span_context: reference(),
telemetry_span_context: reference(),
conn: struct_like(Plug.Conn, []),
conn: struct_like(Plug.Conn),
plug: {__MODULE__, []}
}
end
Expand Down Expand Up @@ -488,7 +488,7 @@ defmodule HTTP1PlugTest do
~> %{
connection_telemetry_span_context: reference(),
telemetry_span_context: reference(),
conn: struct_like(Plug.Conn, []),
conn: struct_like(Plug.Conn),
plug: {__MODULE__, []}
}
end
Expand Down Expand Up @@ -516,7 +516,7 @@ defmodule HTTP1PlugTest do
~> %{
connection_telemetry_span_context: reference(),
telemetry_span_context: reference(),
conn: struct_like(Plug.Conn, []),
conn: struct_like(Plug.Conn),
plug: {__MODULE__, []}
}
end
Expand Down Expand Up @@ -550,7 +550,7 @@ defmodule HTTP1PlugTest do
~> %{
connection_telemetry_span_context: reference(),
telemetry_span_context: reference(),
conn: struct_like(Plug.Conn, []),
conn: struct_like(Plug.Conn),
plug: {__MODULE__, []}
}
end
Expand All @@ -574,7 +574,7 @@ defmodule HTTP1PlugTest do
~> %{
connection_telemetry_span_context: reference(),
telemetry_span_context: reference(),
conn: struct_like(Plug.Conn, []),
conn: struct_like(Plug.Conn),
plug: {__MODULE__, []}
}
end
Expand Down Expand Up @@ -607,7 +607,7 @@ defmodule HTTP1PlugTest do
~> %{
connection_telemetry_span_context: reference(),
telemetry_span_context: reference(),
conn: struct_like(Plug.Conn, []),
conn: struct_like(Plug.Conn),
plug: {__MODULE__, []}
}
end
Expand Down Expand Up @@ -670,7 +670,7 @@ defmodule HTTP1PlugTest do
~> %{
connection_telemetry_span_context: reference(),
telemetry_span_context: reference(),
conn: struct_like(Plug.Conn, []),
conn: struct_like(Plug.Conn),
plug: {__MODULE__, []},
kind: :exit,
exception: %RuntimeError{message: "boom"},
Expand All @@ -695,7 +695,7 @@ defmodule HTTP1PlugTest do
~> %{
connection_telemetry_span_context: reference(),
telemetry_span_context: reference(),
conn: struct_like(Plug.Conn, []),
conn: struct_like(Plug.Conn),
plug: {__MODULE__, []},
kind: :throw,
exception: "thrown",
Expand All @@ -720,7 +720,7 @@ defmodule HTTP1PlugTest do
~> %{
connection_telemetry_span_context: reference(),
telemetry_span_context: reference(),
conn: struct_like(Plug.Conn, []),
conn: struct_like(Plug.Conn),
plug: {__MODULE__, []},
kind: :exit,
exception: "exited",
Expand Down
20 changes: 10 additions & 10 deletions test/bandit/http2/plug_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -788,7 +788,7 @@ defmodule HTTP2PlugTest do
~> %{
connection_telemetry_span_context: reference(),
telemetry_span_context: reference(),
conn: struct_like(Plug.Conn, []),
conn: struct_like(Plug.Conn),
plug: {__MODULE__, []}
}
end
Expand Down Expand Up @@ -816,7 +816,7 @@ defmodule HTTP2PlugTest do
~> %{
connection_telemetry_span_context: reference(),
telemetry_span_context: reference(),
conn: struct_like(Plug.Conn, []),
conn: struct_like(Plug.Conn),
plug: {__MODULE__, []}
}
end
Expand Down Expand Up @@ -844,7 +844,7 @@ defmodule HTTP2PlugTest do
~> %{
connection_telemetry_span_context: reference(),
telemetry_span_context: reference(),
conn: struct_like(Plug.Conn, []),
conn: struct_like(Plug.Conn),
plug: {__MODULE__, []}
}
end
Expand Down Expand Up @@ -876,7 +876,7 @@ defmodule HTTP2PlugTest do
~> %{
connection_telemetry_span_context: reference(),
telemetry_span_context: reference(),
conn: struct_like(Plug.Conn, []),
conn: struct_like(Plug.Conn),
plug: {__MODULE__, []}
}
end
Expand Down Expand Up @@ -910,7 +910,7 @@ defmodule HTTP2PlugTest do
~> %{
connection_telemetry_span_context: reference(),
telemetry_span_context: reference(),
conn: struct_like(Plug.Conn, []),
conn: struct_like(Plug.Conn),
plug: {__MODULE__, []}
}
end
Expand All @@ -934,7 +934,7 @@ defmodule HTTP2PlugTest do
~> %{
connection_telemetry_span_context: reference(),
telemetry_span_context: reference(),
conn: struct_like(Plug.Conn, []),
conn: struct_like(Plug.Conn),
plug: {__MODULE__, []}
}
end
Expand All @@ -958,7 +958,7 @@ defmodule HTTP2PlugTest do
~> %{
connection_telemetry_span_context: reference(),
telemetry_span_context: reference(),
conn: struct_like(Plug.Conn, []),
conn: struct_like(Plug.Conn),
plug: {__MODULE__, []}
}
end
Expand Down Expand Up @@ -999,7 +999,7 @@ defmodule HTTP2PlugTest do
~> %{
connection_telemetry_span_context: reference(),
telemetry_span_context: reference(),
conn: struct_like(Plug.Conn, []),
conn: struct_like(Plug.Conn),
plug: {__MODULE__, []},
kind: :exit,
exception: %RuntimeError{message: "boom"},
Expand All @@ -1023,7 +1023,7 @@ defmodule HTTP2PlugTest do
~> %{
connection_telemetry_span_context: reference(),
telemetry_span_context: reference(),
conn: struct_like(Plug.Conn, []),
conn: struct_like(Plug.Conn),
plug: {__MODULE__, []},
kind: :throw,
exception: "thrown",
Expand All @@ -1047,7 +1047,7 @@ defmodule HTTP2PlugTest do
~> %{
connection_telemetry_span_context: reference(),
telemetry_span_context: reference(),
conn: struct_like(Plug.Conn, []),
conn: struct_like(Plug.Conn),
plug: {__MODULE__, []},
kind: :exit,
exception: "exited",
Expand Down
2 changes: 1 addition & 1 deletion test/bandit/websocket/upgrade_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ defmodule WebSocketUpgradeTest do
~> %{
connection_telemetry_span_context: reference(),
telemetry_span_context: reference(),
conn: struct_like(Plug.Conn, []),
conn: struct_like(Plug.Conn),
plug: {__MODULE__, []}
}
end
Expand Down

0 comments on commit fcd80bc

Please sign in to comment.