summaryrefslogtreecommitdiff
path: root/lib/snmp/test/snmp_test_lib.hrl
diff options
context:
space:
mode:
Diffstat (limited to 'lib/snmp/test/snmp_test_lib.hrl')
-rw-r--r--lib/snmp/test/snmp_test_lib.hrl11
1 files changed, 7 insertions, 4 deletions
diff --git a/lib/snmp/test/snmp_test_lib.hrl b/lib/snmp/test/snmp_test_lib.hrl
index ea7732eba8..f57f2b0e35 100644
--- a/lib/snmp/test/snmp_test_lib.hrl
+++ b/lib/snmp/test/snmp_test_lib.hrl
@@ -1,7 +1,7 @@
%%
%% %CopyrightBegin%
%%
-%% Copyright Ericsson AB 2002-2021. All Rights Reserved.
+%% Copyright Ericsson AB 2002-2022. All Rights Reserved.
%%
%% Licensed under the Apache License, Version 2.0 (the "License");
%% you may not use this file except in compliance with the License.
@@ -103,9 +103,6 @@
-define(PING(N), ?LIB:ping(N)).
-define(LNODES(), ?LIB:local_nodes()).
-define(NODES(H), ?LIB:nodes_on(H)).
--define(START_NODE(N,A), ?LIB:start_node(N,A)).
--define(STOP_NODE(N), ?LIB:stop_node(N)).
-
%% - Application and Crypto utility macros -
@@ -158,3 +155,9 @@
-define(FTS(), snmp_misc:formated_timestamp()).
-define(FTS(TS), snmp_misc:format_timestamp(TS)).
+%% This needs to be a macro-definition to capture ?FUNCTION_NAME and ?MODULE.
+-define (START_PEER(Kind), ?CT_PEER(#{
+ name => ?CT_PEER_NAME(atom_to_list(?FUNCTION_NAME) ++ Kind),
+ args => ["-s", "snmp_test_sys_monitor", "start", "-s", "global", "sync"]
+})).
+-define(STOP_PEER(__P__), peer:stop(__P__)).