aboutsummaryrefslogtreecommitdiff
path: root/tests/fst_tests.h
blob: 2e110692b0350dd3b17501795e4fa38f8184f4c6 (plain)
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
46
47
48
49
50
51
52
53
54
55
56
57
#ifndef FST_TESTS_H
#define FST_TESTS_H

#include "../src/fst.h"
#include "test.h"

bool testmethod_fst_is_consistent(void *);
bool testmethod_cube_to_fst_to_cube(void *);
bool testmethod_fst_move(void *);
bool testmethod_fst_inverse(void *);

extern char *algs[];

Test test_fst_is_consistent = {
	.name  = "Consitency of FST (converted from cube)",
	.t     = testmethod_fst_is_consistent,
	.cases = (void **)algs,
};
Test test_cube_to_fst_to_cube = {
	.name  = "Cube to FST to cube",
	.t     = testmethod_cube_to_fst_to_cube,
	.cases = (void **)algs,
};
Test test_fst_move = {
	.name  = "FST move",
	.t     = testmethod_fst_move,
	.cases = (void **)algs,
};
Test test_fst_inverse = {
	.name  = "FST inverse",
	.t     = testmethod_fst_inverse,
	.cases = (void **)algs,
};

Test *pre_init[] = {
	&test_fst_is_consistent,
	&test_cube_to_fst_to_cube,
	NULL
};
TestSuite fst_pre_init_suite = {
	.setup    = NULL,
	.tests    = pre_init,
	.teardown = NULL,
};

Test *post_init[] = {
	&test_fst_move,
	&test_fst_inverse,
	NULL
};
TestSuite fst_post_init_suite = {
	.setup    = init_fst,
	.tests    = post_init,
	.teardown = NULL,
};

#endif

Generated with cgit - Back to sebastiano.tronto.net