diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 92c74f8b..3fbc395f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -22,8 +22,8 @@ jobs: PLUG_CRYPTO_2_0: "false" # Latest-supported Elixir/Erlang pair. - - elixir: "1.17" - otp: "27.0" + - elixir: "1.18" + otp: "27.2" lint: lint PLUG_CRYPTO_2_0: "true" diff --git a/test/plug/debugger_test.exs b/test/plug/debugger_test.exs index 81a9fafe..e77bdcf4 100644 --- a/test/plug/debugger_test.exs +++ b/test/plug/debugger_test.exs @@ -54,7 +54,8 @@ defmodule Plug.DebuggerTest do get "/bad_match" do _ = conn - bad_match(:six, :one) + # Code.eval_quoted/2 to avoid typing violations at compile time. + Code.eval_quoted(quote do: unquote(__MODULE__).bad_match(:six, :one)) end get "/send_and_wrapped" do @@ -77,14 +78,18 @@ defmodule Plug.DebuggerTest do raise ActionableError end - defp returns_nil, do: nil + # Code.eval_quoted/2 to avoid typing violations at compile time. + defp returns_nil do + {result, _bindings} = Code.eval_quoted(quote do: nil) + result + end defp add_csp(conn, _opts), do: Plug.Conn.put_resp_header(conn, "content-security-policy", "abcdef") - defp bad_match(:one, :two), do: :ok - defp bad_match(:three, :four), do: :ok - defp bad_match(:five, :six), do: :ok + def bad_match(:one, :two), do: :ok + def bad_match(:three, :four), do: :ok + def bad_match(:five, :six), do: :ok end defmodule StyledRouter do