aboutsummaryrefslogtreecommitdiffstats
path: root/lib/snmp/test/snmp_compiler_test.erl
diff options
context:
space:
mode:
Diffstat (limited to 'lib/snmp/test/snmp_compiler_test.erl')
-rw-r--r--lib/snmp/test/snmp_compiler_test.erl62
1 files changed, 57 insertions, 5 deletions
diff --git a/lib/snmp/test/snmp_compiler_test.erl b/lib/snmp/test/snmp_compiler_test.erl
index 9b3c2bfd2c..0a7b729d1f 100644
--- a/lib/snmp/test/snmp_compiler_test.erl
+++ b/lib/snmp/test/snmp_compiler_test.erl
@@ -1,7 +1,7 @@
%%
%% %CopyrightBegin%
%%
-%% Copyright Ericsson AB 2003-2017. All Rights Reserved.
+%% Copyright Ericsson AB 2003-2018. 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.
@@ -57,8 +57,9 @@
otp_8595/1,
otp_10799/1,
otp_10808/1,
- otp_14145/1
-
+ otp_14145/1,
+ otp_13014/1,
+ otp_14196/1
]).
%%----------------------------------------------------------------------
@@ -137,7 +138,8 @@ all() ->
groups() ->
[{tickets, [],
- [otp_6150, otp_8574, otp_8595, otp_10799, otp_10808, otp_14145]}].
+ [otp_6150, otp_8574, otp_8595, otp_10799, otp_10808, otp_14145,
+ otp_13014, otp_14196]}].
init_per_group(_GroupName, Config) ->
Config.
@@ -436,7 +438,7 @@ otp_10808(Config) when is_list(Config) ->
otp_14145(suite) ->
[];
otp_14145(Config) when is_list(Config) ->
- put(tname, otp10808),
+ put(tname, otp14145),
p("starting with Config: ~p~n", [Config]),
Dir = ?config(case_top_dir, Config),
@@ -457,6 +459,56 @@ otp_14145(Config) when is_list(Config) ->
%%======================================================================
+otp_13014(suite) ->
+ [];
+otp_13014(Config) when is_list(Config) ->
+ put(tname, otp13014),
+ p("starting with Config: ~p~n", [Config]),
+
+ Dir = ?config(case_top_dir, Config),
+ MibDir = ?config(mib_dir, Config),
+ MibName = "Test-LLDP-MIB",
+ MibFile = join(MibDir, MibName++".mib"),
+ ?line {ok, MibBin} =
+ snmpc:compile(MibFile, [{outdir, Dir},
+ {verbosity, log},
+ {group_check, false},
+ module_compliance]),
+ p("Mib: ~n~p~n", [MibBin]),
+ #mib{mes = MEs} = read_mib(MibBin),
+ Oid = [1,0,8802,1,1,2,1,1,7],
+ #me{
+ entrytype = table,
+ aliasname = lldpConfigManAddrTable,
+ assocList = [{table_info,TableInfo}]} =
+ lists:keyfind(Oid, #me.oid, MEs),
+ #table_info{
+ nbr_of_cols = 1,
+ first_accessible = 1,
+ not_accessible = [],
+ index_types = {augments,{lldpLocManAddrEntry,undefined}}} =
+ TableInfo,
+ ok.
+
+%%======================================================================
+
+otp_14196(suite) ->
+ [];
+otp_14196(Config) when is_list(Config) ->
+ put(tname, otp14196),
+ p("starting with Config: ~p~n", [Config]),
+
+ Dir = ?config(case_top_dir, Config),
+ MibDir = ?config(mib_dir, Config),
+ MibFile = join(MibDir, "OTP14196-MIB.mib"),
+ ?line {ok, Mib} =
+ snmpc:compile(MibFile, [{outdir, Dir}, {verbosity, trace}]),
+ p("Mib: ~n~p~n", [Mib]),
+ ok.
+
+
+%%======================================================================
+
augments_extra_info(suite) ->
[];
augments_extra_info(Config) when is_list(Config) ->