diff options
author | Björn Gustavsson <[email protected]> | 2014-12-18 08:23:58 +0100 |
---|---|---|
committer | Björn Gustavsson <[email protected]> | 2015-01-12 12:22:59 +0100 |
commit | 09cd07962f7c64ec0ccef2ad655bf9977c154bf0 (patch) | |
tree | 62b067db0fbbac22c9b65c6152cf2b983bf7c6ea /lib/asn1/test | |
parent | ac5c60b0de2ef93a99f6c39f3e251f526f303964 (diff) | |
download | otp-09cd07962f7c64ec0ccef2ad655bf9977c154bf0.tar.gz otp-09cd07962f7c64ec0ccef2ad655bf9977c154bf0.tar.bz2 otp-09cd07962f7c64ec0ccef2ad655bf9977c154bf0.zip |
Improve error handling for illegal object definitions
Diffstat (limited to 'lib/asn1/test')
-rw-r--r-- | lib/asn1/test/error_SUITE.erl | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/lib/asn1/test/error_SUITE.erl b/lib/asn1/test/error_SUITE.erl index c6b6e9dffc..a9893b91cc 100644 --- a/lib/asn1/test/error_SUITE.erl +++ b/lib/asn1/test/error_SUITE.erl @@ -285,6 +285,9 @@ objects(Config) -> " InvalidSet CL ::= { obj1 }\n" " obj5 CL ::= {}\n" " ErrSet ::= PT{ {PT{inst}}}\n" + " obj6 CL ::= 7\n" + " obj7 CL ::= int\n" + " obj8 NON-CLASS ::= { &id 1 }\n" " CL ::= CLASS {\n" " &code INTEGER UNIQUE,\n" @@ -303,6 +306,9 @@ objects(Config) -> " PT{SMALL:Small} ::= SEQUENCE { a SMALL.&code ({Small}) }\n" " inst SMALL ::= {&code 42, &i 4711}\n" + + " int INTEGER ::= 42\n" + " NON-CLASS ::= SEQUENCE { a BOOLEAN }\n" "END\n">>}, {error, [ @@ -321,7 +327,10 @@ objects(Config) -> {missing_mandatory_fields, ['Data','Set','VarTypeValue',code,enum,object, vartypevalue],obj5}}, - {structured_error,{M,8},asn1ct_check,invalid_objectset} + {structured_error,{M,8},asn1ct_check,invalid_objectset}, + {structured_error,{M,9},asn1ct_check,illegal_object}, + {structured_error,{M,10},asn1ct_check,illegal_object}, + {structured_error,{M,11},asn1ct_check,illegal_object} ] } = run(P, Config), ok. |