From c8f1324386ffa9a379763b5f14ab763a6c63f49a Mon Sep 17 00:00:00 2001 From: Gonzalo <456459+grzuy@users.noreply.github.com> Date: Sat, 18 Jan 2025 12:17:57 -0300 Subject: [PATCH 1/2] test: avoids arithmetic warning in test --- test/bandit/http1/plug_test.exs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/bandit/http1/plug_test.exs b/test/bandit/http1/plug_test.exs index d22173dd..01231567 100644 --- a/test/bandit/http1/plug_test.exs +++ b/test/bandit/http1/plug_test.exs @@ -58,7 +58,7 @@ defmodule HTTP1PlugTest do end def unknown_crasher(_conn) do - 1 / 0 + 1 + self() end @tag :capture_log From 8e66874976df06d4f13574e2849cc19c147b0588 Mon Sep 17 00:00:00 2001 From: Gonzalo <456459+grzuy@users.noreply.github.com> Date: Mon, 20 Jan 2025 15:59:17 -0300 Subject: [PATCH 2/2] test: avoids compiler warning about obvious match error --- test/bandit/http1/plug_test.exs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/bandit/http1/plug_test.exs b/test/bandit/http1/plug_test.exs index 01231567..ee62b43c 100644 --- a/test/bandit/http1/plug_test.exs +++ b/test/bandit/http1/plug_test.exs @@ -112,7 +112,7 @@ defmodule HTTP1PlugTest do get "/" do # Quiet the compiler _ = conn - 1 = 0 + 1 = self() end end