]> git.ipfire.org Git - thirdparty/strongswan.git/blame - src/libstrongswan/tests/suites/test_vectors.c
identification: Support prefixes in string constructors for an explicit type
[thirdparty/strongswan.git] / src / libstrongswan / tests / suites / test_vectors.c
CommitLineData
cb1745f7 1/*
636076d4
TB
2 * Copyright (C) 2014 Tobias Brunner
3 * Hochschule fuer Technik Rapperswil
4 *
cb1745f7
MW
5 * Copyright (C) 2013 Martin Willi
6 * Copyright (C) 2013 revosec AG
7 *
8 * This program is free software; you can redistribute it and/or modify it
9 * under the terms of the GNU General Public License as published by the
10 * Free Software Foundation; either version 2 of the License, or (at your
11 * option) any later version. See <http://www.fsf.org/copyleft/gpl.txt>.
12 *
13 * This program is distributed in the hope that it will be useful, but
14 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
15 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
16 * for more details.
17 */
18
19#include "test_suite.h"
20
636076d4
TB
21#include <utils/test.h>
22
23IMPORT_FUNCTION_FOR_TESTS(crypto, verify_registered_algorithms, u_int,
24 crypto_factory_t *factory);
cb1745f7
MW
25
26START_TEST(test_vectors)
27{
636076d4
TB
28 u_int failed = TEST_FUNCTION(crypto, verify_registered_algorithms,
29 lib->crypto);
b74b8add 30 fail_if(failed > 0, "%u test vectors failed", failed);
cb1745f7
MW
31}
32END_TEST
33
34
35Suite *vectors_suite_create()
36{
37 Suite *s;
38 TCase *tc;
39
40 s = suite_create("vectors");
41
42 tc = tcase_create("failures");
43 tcase_add_test(tc, test_vectors);
44 suite_add_tcase(s, tc);
45
46 return s;
47}