aboutsummaryrefslogtreecommitdiffstats
path: root/lib/snmp/test/snmp_agent_test.erl
diff options
context:
space:
mode:
authorMicael Karlberg <[email protected]>2010-06-08 14:23:02 +0000
committerErlang/OTP <[email protected]>2010-06-08 14:23:02 +0000
commit1db9890d2d52e37ea134545453319a748fd84e10 (patch)
tree4aa81560091a5443a545394ce459f6f5f061e01a /lib/snmp/test/snmp_agent_test.erl
parentaf15e8bd5bdf976b232e6515cf3cca4200b6120b (diff)
downloadotp-1db9890d2d52e37ea134545453319a748fd84e10.tar.gz
otp-1db9890d2d52e37ea134545453319a748fd84e10.tar.bz2
otp-1db9890d2d52e37ea134545453319a748fd84e10.zip
OTP-8478: Added support for multiple SNMPv3 EngineIDs in a single agent.
Diffstat (limited to 'lib/snmp/test/snmp_agent_test.erl')
-rw-r--r--lib/snmp/test/snmp_agent_test.erl30
1 files changed, 29 insertions, 1 deletions
diff --git a/lib/snmp/test/snmp_agent_test.erl b/lib/snmp/test/snmp_agent_test.erl
index 2534147769..9d2e9969c4 100644
--- a/lib/snmp/test/snmp_agent_test.erl
+++ b/lib/snmp/test/snmp_agent_test.erl
@@ -5260,7 +5260,35 @@ otp_1131_2(X) -> ?P(otp_1131_2), otp_1131(X).
otp_1131_3(X) ->
%% <CONDITIONAL-SKIP>
- Skippable = [{unix, [darwin]}],
+ %% This is intended to catch Montavista Linux 4.0/ppc (2.6.5)
+ %% Montavista Linux looks like a Debian distro (/etc/issue)
+ LinuxVersionVerify =
+ fun() ->
+ case os:cmd("uname -m") of
+ "ppc" ++ _ ->
+ case file:read_file_info("/etc/issue") of
+ {ok, _} ->
+ case os:cmd("grep -i montavista /etc/issue") of
+ Info when (is_list(Info) andalso
+ (length(Info) > 0)) ->
+ case os:version() of
+ {2, 6, 10} ->
+ true;
+ _ ->
+ false
+ end;
+ _ -> % Maybe plain Debian or Ubuntu
+ false
+ end;
+ _ ->
+ %% Not a Debian based distro
+ false
+ end;
+ _ ->
+ false
+ end
+ end,
+ Skippable = [{unix, [darwin, {linux, LinuxVersionVerify}]}],
Condition = fun() -> ?OS_BASED_SKIP(Skippable) end,
?NON_PC_TC_MAYBE_SKIP(X, Condition),
%% </CONDITIONAL-SKIP>