summaryrefslogtreecommitdiffstats
path: root/test/d2i_test.c
diff options
context:
space:
mode:
authorShane Lontis <shane.lontis@oracle.com>2018-08-16 12:36:01 +1000
committerRichard Levitte <levitte@openssl.org>2019-02-11 15:31:51 +0100
commita43ce58f5569a160272c492c680f2e42d38ec769 (patch)
treeacfaac32bee9b8e5dd832fbb49f95709c3b9741e /test/d2i_test.c
parent9d5560331d86c6463e965321f774e4eed582ce0b (diff)
Updated test command line parsing to support commmon commands
Reviewed-by: Paul Dale <paul.dale@oracle.com> Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/6975)
Diffstat (limited to 'test/d2i_test.c')
-rw-r--r--test/d2i_test.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/test/d2i_test.c b/test/d2i_test.c
index 13f6c0ca22..3ce38485bd 100644
--- a/test/d2i_test.c
+++ b/test/d2i_test.c
@@ -106,6 +106,8 @@ static int test_bad_asn1(void)
return ret;
}
+OPT_TEST_DECLARE_USAGE("item_name expected_error test_file.der\n")
+
/*
* Usage: d2i_test <name> <type> <file>, e.g.
* d2i_test generalname bad_generalname.der
@@ -127,10 +129,8 @@ int setup_tests(void)
if (!TEST_ptr(test_type_name = test_get_argument(0))
|| !TEST_ptr(expected_error_string = test_get_argument(1))
- || !TEST_ptr(test_file = test_get_argument(2))) {
- TEST_note("Usage: d2i_test item_name expected_error file.der");
+ || !TEST_ptr(test_file = test_get_argument(2)))
return 0;
- }
item_type = ASN1_ITEM_lookup(test_type_name);