aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrent Cook <busterb@gmail.com>2020-05-07 09:04:42 -0500
committerBrent Cook <busterb@gmail.com>2020-05-07 09:04:42 -0500
commit442a969ed4f82005b343517e80e19120f1fa56db (patch)
tree7ee84a54929c95d9d0119aa7c946119804a2a4d5
parent049c874d76e2579e5b36d9700423ef18b8200348 (diff)
parent1fe779234937c7194ef5a11f383136eb005370d5 (diff)
downloadportable-442a969ed4f82005b343517e80e19120f1fa56db.tar.gz
portable-442a969ed4f82005b343517e80e19120f1fa56db.tar.bz2
portable-442a969ed4f82005b343517e80e19120f1fa56db.zip
Land #586, Enable handshake_table regression test
-rw-r--r--patches/handshake_table.c.patch18
-rw-r--r--tests/CMakeLists.txt7
-rw-r--r--tests/Makefile.am3
3 files changed, 27 insertions, 1 deletions
diff --git a/patches/handshake_table.c.patch b/patches/handshake_table.c.patch
new file mode 100644
index 0000000..46f2adb
--- /dev/null
+++ b/patches/handshake_table.c.patch
@@ -0,0 +1,18 @@
1--- tests/handshake_table.c.orig Mon May 4 23:28:43 2020
2+++ tests/handshake_table.c Mon May 4 23:29:50 2020
3@@ -477,6 +477,7 @@
4 unsigned int depth = 0;
5 int ch, graphviz = 0, print = 0;
6
7+#ifndef _MSC_VER
8 while ((ch = getopt(argc, argv, "Cg")) != -1) {
9 switch (ch) {
10 case 'C':
11@@ -494,6 +495,7 @@
12
13 if (argc != 0)
14 usage();
15+#endif
16
17 if (graphviz && print)
18 usage();
diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt
index 80b785d..ed63f06 100644
--- a/tests/CMakeLists.txt
+++ b/tests/CMakeLists.txt
@@ -225,6 +225,13 @@ add_executable(gost2814789t gost2814789t.c)
225target_link_libraries(gost2814789t ${OPENSSL_LIBS}) 225target_link_libraries(gost2814789t ${OPENSSL_LIBS})
226add_test(gost2814789t gost2814789t) 226add_test(gost2814789t gost2814789t)
227 227
228# handshake_table
229if(NOT BUILD_SHARED_LIBS)
230 add_executable(handshake_table handshake_table.c)
231 target_link_libraries(handshake_table ${OPENSSL_LIBS})
232 add_test(handshake_table handshake_table)
233endif()
234
228# hkdf_test 235# hkdf_test
229add_executable(hkdf_test hkdf_test.c) 236add_executable(hkdf_test hkdf_test.c)
230target_link_libraries(hkdf_test ${OPENSSL_LIBS}) 237target_link_libraries(hkdf_test ${OPENSSL_LIBS})
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 7463f26..86db040 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -228,7 +228,8 @@ check_PROGRAMS += gost2814789t
228gost2814789t_SOURCES = gost2814789t.c 228gost2814789t_SOURCES = gost2814789t.c
229 229
230# handshake_table 230# handshake_table
231noinst_PROGRAMS = handshake_table 231TESTS += handshake_table
232check_PROGRAMS += handshake_table
232handshake_table_SOURCES = handshake_table.c 233handshake_table_SOURCES = handshake_table.c
233 234
234# hkdf_test 235# hkdf_test