summaryrefslogtreecommitdiff
path: root/regress/unittests/test_helper/test_helper.c
diff options
context:
space:
mode:
Diffstat (limited to 'regress/unittests/test_helper/test_helper.c')
-rw-r--r--regress/unittests/test_helper/test_helper.c28
1 files changed, 24 insertions, 4 deletions
diff --git a/regress/unittests/test_helper/test_helper.c b/regress/unittests/test_helper/test_helper.c
index 4cc70852c..6200ccd58 100644
--- a/regress/unittests/test_helper/test_helper.c
+++ b/regress/unittests/test_helper/test_helper.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: test_helper.c,v 1.8 2018/02/08 08:46:20 djm Exp $ */ 1/* $OpenBSD: test_helper.c,v 1.9 2018/10/17 23:28:05 djm Exp $ */
2/* 2/*
3 * Copyright (c) 2011 Damien Miller <djm@mindrot.org> 3 * Copyright (c) 2011 Damien Miller <djm@mindrot.org>
4 * 4 *
@@ -115,6 +115,8 @@ static test_onerror_func_t *test_onerror = NULL;
115static void *onerror_ctx = NULL; 115static void *onerror_ctx = NULL;
116static const char *data_dir = NULL; 116static const char *data_dir = NULL;
117static char subtest_info[512]; 117static char subtest_info[512];
118static int fast = 0;
119static int slow = 0;
118 120
119int 121int
120main(int argc, char **argv) 122main(int argc, char **argv)
@@ -134,8 +136,14 @@ main(int argc, char **argv)
134 } 136 }
135 } 137 }
136 138
137 while ((ch = getopt(argc, argv, "vqd:")) != -1) { 139 while ((ch = getopt(argc, argv, "Ffvqd:")) != -1) {
138 switch (ch) { 140 switch (ch) {
141 case 'F':
142 slow = 1;
143 break;
144 case 'f':
145 fast = 1;
146 break;
139 case 'd': 147 case 'd':
140 data_dir = optarg; 148 data_dir = optarg;
141 break; 149 break;
@@ -167,17 +175,29 @@ main(int argc, char **argv)
167} 175}
168 176
169int 177int
170test_is_verbose() 178test_is_verbose(void)
171{ 179{
172 return verbose_mode; 180 return verbose_mode;
173} 181}
174 182
175int 183int
176test_is_quiet() 184test_is_quiet(void)
177{ 185{
178 return quiet_mode; 186 return quiet_mode;
179} 187}
180 188
189int
190test_is_fast(void)
191{
192 return fast;
193}
194
195int
196test_is_slow(void)
197{
198 return slow;
199}
200
181const char * 201const char *
182test_data_file(const char *name) 202test_data_file(const char *name)
183{ 203{