1 | /*
|
---|
2 | * Copyright 2017-2018 The OpenSSL Project Authors. All Rights Reserved.
|
---|
3 | *
|
---|
4 | * Licensed under the Apache License 2.0 (the "License"). You may not use
|
---|
5 | * this file except in compliance with the License. You can obtain a copy
|
---|
6 | * in the file LICENSE in the source distribution or at
|
---|
7 | * https://www.openssl.org/source/license.html
|
---|
8 | */
|
---|
9 |
|
---|
10 | #include <stdlib.h> /* size_t */
|
---|
11 | #include <openssl/bn.h>
|
---|
12 | #include <openssl/bio.h>
|
---|
13 | #include "../testutil.h"
|
---|
14 |
|
---|
15 | #define TEST_SKIP_CODE 123
|
---|
16 |
|
---|
17 | int subtest_level(void);
|
---|
18 | int openssl_error_cb(const char *str, size_t len, void *u);
|
---|
19 | const BIO_METHOD *BIO_f_tap(void);
|
---|
20 |
|
---|
21 | void test_fail_message_prefix(const char *prefix, const char *file,
|
---|
22 | int line, const char *type,
|
---|
23 | const char *left, const char *right,
|
---|
24 | const char *op);
|
---|
25 |
|
---|
26 | void test_fail_string_message(const char *prefix, const char *file,
|
---|
27 | int line, const char *type,
|
---|
28 | const char *left, const char *right,
|
---|
29 | const char *op, const char *m1, size_t l1,
|
---|
30 | const char *m2, size_t l2);
|
---|
31 |
|
---|
32 | void test_fail_bignum_message(const char *prefix, const char *file,
|
---|
33 | int line, const char *type,
|
---|
34 | const char *left, const char *right,
|
---|
35 | const char *op,
|
---|
36 | const BIGNUM *bn1, const BIGNUM *bn2);
|
---|
37 | void test_fail_bignum_mono_message(const char *prefix, const char *file,
|
---|
38 | int line, const char *type,
|
---|
39 | const char *left, const char *right,
|
---|
40 | const char *op, const BIGNUM *bn);
|
---|
41 |
|
---|
42 | void test_fail_memory_message(const char *prefix, const char *file,
|
---|
43 | int line, const char *type,
|
---|
44 | const char *left, const char *right,
|
---|
45 | const char *op,
|
---|
46 | const unsigned char *m1, size_t l1,
|
---|
47 | const unsigned char *m2, size_t l2);
|
---|
48 |
|
---|
49 | __owur int setup_test_framework(int argc, char *argv[]);
|
---|
50 | __owur int pulldown_test_framework(int ret);
|
---|
51 |
|
---|
52 | __owur int run_tests(const char *test_prog_name);
|
---|
53 | void set_test_title(const char *title);
|
---|
54 |
|
---|
55 | typedef enum OPTION_choice_default {
|
---|
56 | OPT_ERR = -1,
|
---|
57 | OPT_EOF = 0,
|
---|
58 | OPT_TEST_ENUM
|
---|
59 | } OPTION_CHOICE_DEFAULT;
|
---|
60 | void opt_check_usage(void);
|
---|
61 |
|
---|