From 81cdcee4aef15e54d712ea4b3a72df77f5e14414 Mon Sep 17 00:00:00 2001 From: Andrew Dryga Date: Fri, 17 May 2024 11:30:29 -0600 Subject: [PATCH] Replace other Logger.levels() usages --- test/logger_json/formatters/basic_test.exs | 2 +- test/logger_json/formatters/datadog_test.exs | 2 +- test/logger_json/formatters/google_cloud_test.exs | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/test/logger_json/formatters/basic_test.exs b/test/logger_json/formatters/basic_test.exs index 7836ab4..d07f13c 100644 --- a/test/logger_json/formatters/basic_test.exs +++ b/test/logger_json/formatters/basic_test.exs @@ -38,7 +38,7 @@ defmodule LoggerJSON.Formatters.BasicTest do end test "logs message of a given level" do - for level <- Logger.levels() do + for level <- [:error, :info, :debug, :emergency, :alert, :critical, :warning, :notice] do log = capture_log(level, fn -> Logger.log(level, "Hello") diff --git a/test/logger_json/formatters/datadog_test.exs b/test/logger_json/formatters/datadog_test.exs index bf05c8d..020e7e0 100644 --- a/test/logger_json/formatters/datadog_test.exs +++ b/test/logger_json/formatters/datadog_test.exs @@ -38,7 +38,7 @@ defmodule LoggerJSON.Formatters.DatadogTest do end test "logs an LogEntry of a given level" do - for level <- Logger.levels() do + for level <- [:error, :info, :debug, :emergency, :alert, :critical, :warning, :notice] do log = capture_log(level, fn -> Logger.log(level, "Hello") diff --git a/test/logger_json/formatters/google_cloud_test.exs b/test/logger_json/formatters/google_cloud_test.exs index dceac87..f809480 100644 --- a/test/logger_json/formatters/google_cloud_test.exs +++ b/test/logger_json/formatters/google_cloud_test.exs @@ -35,7 +35,7 @@ defmodule LoggerJSON.Formatters.GoogleCloudTest do end test "logs an LogEntry of a given level" do - for level <- Logger.levels() do + for level <- [:error, :info, :debug, :emergency, :alert, :critical, :warning, :notice] do log_entry = capture_log(level, fn -> Logger.log(level, "Hello")