summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--tests/Test_encoding.asn1
-rw-r--r--tests/Test_encoding.c8
2 files changed, 9 insertions, 0 deletions
diff --git a/tests/Test_encoding.asn b/tests/Test_encoding.asn
index de7b93f..040c88f 100644
--- a/tests/Test_encoding.asn
+++ b/tests/Test_encoding.asn
@@ -14,6 +14,7 @@ Koko ::= SEQUENCE {
a [1] OCTET STRING,
b [10] OCTET STRING,
c [100] OCTET STRING,
+ exp [3] EXPLICIT OCTET STRING OPTIONAL,
str OCTET STRING
}
diff --git a/tests/Test_encoding.c b/tests/Test_encoding.c
index e693ed7..8e8c702 100644
--- a/tests/Test_encoding.c
+++ b/tests/Test_encoding.c
@@ -133,6 +133,14 @@ main (int argc, char *argv[])
exit (1);
}
+ result = asn1_write_value (asn1_element, "exp", "string4", 7);
+ if (result != ASN1_SUCCESS)
+ {
+ fprintf (stderr, "asn1_write_value(): str ");
+ asn1_perror (result);
+ exit (1);
+ }
+
/* Clear the definition structures */
asn1_delete_structure (&definitions);