diff --git a/lib/benchee/profile.ex b/lib/benchee/profile.ex index 17a057c9..a1c94162 100644 --- a/lib/benchee/profile.ex +++ b/lib/benchee/profile.ex @@ -26,8 +26,10 @@ defmodule Benchee.Profile do @builtin_profilers [:cprof, :eprof, :fprof] # https://hexdocs.pm/mix/1.17.0/Mix.Tasks.Profile.Tprof.html # Tprof was introduced in elixir 1.17.0 and requires OTP 27 - # Elixir errors out fine, but our test kind of put their trust into `builtin_profilers` being runnable. - if Version.match?(System.version(), ">= 1.17.0") && String.to_integer(System.otp_release()) >= 27 do + # Elixir errors out fine, but our test kind of put their trust into `builtin_profilers` + # being runnable. + if Version.match?(System.version(), ">= 1.17.0") && + String.to_integer(System.otp_release()) >= 27 do @builtin_profilers [:tprof | @builtin_profilers] end diff --git a/test/benchee_test.exs b/test/benchee_test.exs index c04e0eab..f39ba816 100644 --- a/test/benchee_test.exs +++ b/test/benchee_test.exs @@ -925,8 +925,7 @@ defmodule BencheeTest do assert output =~ end_of_profiling_regex(Profile.default_profiler()) end - @profilers [:cprof, :eprof, :fprof] - for profiler <- @profilers do + for profiler <- Benchee.Profile.builtin_profilers() do @profiler profiler test "integration profiling runs #{inspect(@profiler)} profiler" do output =