aboutsummaryrefslogtreecommitdiffstats
path: root/lib/asn1
diff options
context:
space:
mode:
authorSimon Cornish <[email protected]>2019-02-22 17:09:26 -0800
committerSimon Cornish <[email protected]>2019-02-25 21:27:36 -0800
commitf82ce9edf8726e5bd6e6ed24c4535b1b16f67a3a (patch)
treedd8f5b743b5c162fb5b33cb999fbcabd9c650f76 /lib/asn1
parent0657dc8546cafd26c609ed2e474ff15fc6ac6c65 (diff)
downloadotp-f82ce9edf8726e5bd6e6ed24c4535b1b16f67a3a.tar.gz
otp-f82ce9edf8726e5bd6e6ed24c4535b1b16f67a3a.tar.bz2
otp-f82ce9edf8726e5bd6e6ed24c4535b1b16f67a3a.zip
Test compiling value of CHOICE with extensions
Diffstat (limited to 'lib/asn1')
-rw-r--r--lib/asn1/test/asn1_SUITE_data/ChoExtension.asn12
-rw-r--r--lib/asn1/test/testChoExtension.erl1
2 files changed, 3 insertions, 0 deletions
diff --git a/lib/asn1/test/asn1_SUITE_data/ChoExtension.asn1 b/lib/asn1/test/asn1_SUITE_data/ChoExtension.asn1
index 18473bae30..c488704196 100644
--- a/lib/asn1/test/asn1_SUITE_data/ChoExtension.asn1
+++ b/lib/asn1/test/asn1_SUITE_data/ChoExtension.asn1
@@ -41,4 +41,6 @@ ChoExt4 ::= CHOICE
str OCTET STRING
}
+choExt1 ChoExt1 ::= int : 1
+
END
diff --git a/lib/asn1/test/testChoExtension.erl b/lib/asn1/test/testChoExtension.erl
index 4c632aab81..cfb28be5c7 100644
--- a/lib/asn1/test/testChoExtension.erl
+++ b/lib/asn1/test/testChoExtension.erl
@@ -28,6 +28,7 @@
extension(_Rules) ->
roundtrip('ChoExt1', {bool,true}),
roundtrip('ChoExt1', {int,33}),
+ {int, 1} = 'ChoExtension':choExt1(),
%% A trick to encode with another compatible CHOICE type to test reception
%% extension alternative