-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathunitc_dev.c
45 lines (35 loc) · 1.28 KB
/
unitc_dev.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
/** unitc_dev.c
* Implementation of unitc_dev.c.
* The definitions of uc_* are to come from unitc.c not the installed library.
*/
#include <stdint.h>
#include <stdbool.h>
#include "unitc.h"
#include "unitc_dev.h"
dev_uc_suite dev_uc_init(const uint_least8_t options, const char *name,
const char *comment) {
return (dev_uc_suite)uc_init(options, name, comment);
}
void dev_uc_free(dev_uc_suite suite) {
uc_free((struct uc_suite *)suite);
}
void dev_uc_check(dev_uc_suite suite, const bool cond, const char *comment) {
uc_check((struct uc_suite *)suite, cond, comment);
}
void dev_uc_add_test(dev_uc_suite suite, void (*test_func)(dev_uc_suite suite),
const char *name, const char *comment) {
uc_add_test((struct uc_suite *)suite,
(void (*)(uc_suite suite))test_func, name, comment);
}
void dev_uc_run_tests(dev_uc_suite suite) {
uc_run_tests((struct uc_suite *)suite);
}
bool dev_uc_all_tests_passed(dev_uc_suite suite) {
return uc_all_tests_passed((struct uc_suite *)suite);
}
void dev_uc_report_basic(dev_uc_suite suite) {
uc_report_basic((struct uc_suite *)suite);
}
void dev_uc_report_standard(dev_uc_suite suite) {
uc_report_standard((struct uc_suite *)suite);
}