summaryrefslogtreecommitdiff
path: root/erts/emulator/test/statistics_SUITE.erl
diff options
context:
space:
mode:
authorLukas Larsson <lukas@erlang.org>2022-01-10 11:52:13 +0100
committerLukas Larsson <lukas@erlang.org>2022-01-10 11:52:13 +0100
commit33959fa295fc09af1acaabf34363ac57b3672a5c (patch)
tree00a00997f54aadcdc2f5f4c0cf0a7cfae26ea76b /erts/emulator/test/statistics_SUITE.erl
parenta18a7f4ec7d8e37f1011eb1fdecabcacc9ffa9e4 (diff)
parent63900d18f5d8d4a41a6c8b4eaa70ccf327ccdbaf (diff)
downloaderlang-33959fa295fc09af1acaabf34363ac57b3672a5c.tar.gz
Merge branch 'lukas/24/test-fixes' into maint
* lukas/24/test-fixes: gh: Do not build deps for windows erts: Fix disable of MSACC
Diffstat (limited to 'erts/emulator/test/statistics_SUITE.erl')
-rw-r--r--erts/emulator/test/statistics_SUITE.erl11
1 files changed, 11 insertions, 0 deletions
diff --git a/erts/emulator/test/statistics_SUITE.erl b/erts/emulator/test/statistics_SUITE.erl
index 0682b097f5..501bd7eb88 100644
--- a/erts/emulator/test/statistics_SUITE.erl
+++ b/erts/emulator/test/statistics_SUITE.erl
@@ -23,6 +23,7 @@
%% Tests the statistics/1 bif.
-export([all/0, suite/0, groups/0,
+ init_per_testcase/2,
wall_clock_sanity/1,
wall_clock_zero_diff/1, wall_clock_update/1,
runtime_sanity/1,
@@ -61,6 +62,16 @@ groups() ->
[runtime_sanity, runtime_zero_diff, runtime_update, runtime_diff]},
{run_queue, [], [run_queue_one]}].
+init_per_testcase(msacc, Config) ->
+ try erlang:statistics(microstate_accounting) of
+ _ ->
+ Config
+ catch _:_ ->
+ {skip, "Microstate accouning not available"}
+ end;
+init_per_testcase(_, Config) ->
+ Config.
+
wall_clock_sanity(Config) when is_list(Config) ->
erlang:yield(),
{WallClock, _} = statistics(wall_clock),