aboutsummaryrefslogtreecommitdiff
path: root/tests/fst_post_init_tests.c
diff options
context:
space:
mode:
Diffstat (limited to 'tests/fst_post_init_tests.c')
-rw-r--r--tests/fst_post_init_tests.c33
1 files changed, 0 insertions, 33 deletions
diff --git a/tests/fst_post_init_tests.c b/tests/fst_post_init_tests.c
index 653e379..9d8d554 100644
--- a/tests/fst_post_init_tests.c
+++ b/tests/fst_post_init_tests.c
@@ -4,19 +4,16 @@ static bool fst_move_testcase(Cube *c, Alg *a);
4static bool fst_inverse_testcase(Cube *c, Alg *a); 4static bool fst_inverse_testcase(Cube *c, Alg *a);
5 5
6static bool fst_move_test(); 6static bool fst_move_test();
7static bool fst_where_is_edge_test();
8static bool fst_inverse_test(); 7static bool fst_inverse_test();
9 8
10static Tester test[] = { 9static Tester test[] = {
11 fst_move_test, 10 fst_move_test,
12 fst_where_is_edge_test,
13 fst_inverse_test, 11 fst_inverse_test,
14 NULL 12 NULL
15}; 13};
16 14
17static char *name[] = { 15static char *name[] = {
18 "FST move", 16 "FST move",
19 "FST where is edge",
20 "FST inverse", 17 "FST inverse",
21}; 18};
22 19
@@ -62,36 +59,6 @@ fst_move_test()
62} 59}
63 60
64static bool 61static bool
65fst_where_is_edge_test()
66{
67 int i;
68 Alg *scr;
69 Cube c, d;
70 FstCube fst;
71
72 /* Testing on a single scramble is fine for now */
73 scr = new_alg("RUFDL2B2FRD");
74 make_solved(&c);
75 apply_alg(scr, &c);
76 fst = cube_to_fst(&c);
77
78 for (i = 0; i < 12; i++) {
79 if (fst_where_is_edge(c.ep[i], fst) != i) {
80 fst_to_cube(fst, &d);
81 printf("Alg: ");
82 print_alg(scr, false);
83 printf("Expected:\n");
84 print_cube(&c);
85 printf("But got:\n");
86 print_cube(&d);
87 return false;
88 }
89 }
90
91 return true;
92}
93
94static bool
95fst_inverse_test() 62fst_inverse_test()
96{ 63{
97 return try_all_str(fst_inverse_testcase, "FST test incorrect"); 64 return try_all_str(fst_inverse_testcase, "FST test incorrect");

Generated with cgit - Back to sebastiano.tronto.net