-
Notifications
You must be signed in to change notification settings - Fork 0
/
unittesting.out
410 lines (359 loc) · 22.7 KB
/
unittesting.out
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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
bash -v unittesting.sh
#!/bin/bash
# Testing script for puzzle.c Unit Test
# Authors: Dylan Beinstock, Salifyanji J. Namwila, and Veronica Quidore
# Date: November 11 2021
#
# usage: bash -v unittesting.sh
# call the compiled puzzletest program in the puzzle subdirectory
./puzzletest
could not open file to write :(
FILE POINTER IS NULL
Welcome to the Puzzle Module Unit Tests. We have expected you...
try all of the null cases for puzzle_new()
excellent! no memory allocated for invalid (negative) size of puzzle!
no memory allocated for invalid (non-perfect square) puzzle size! yay!
no memory allocated for invalid (too-large perfect square -> 100) puzzle size! yay!
lets. make. a. PUZZLEEEEEEEEEE (9x9)
memory for puzzle1 successfully allocated!
check the initialization of box_t structs within grid indirectly through printing puzzle simple and formatted struct (should be grid of 0s)
0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0
+-------+-------+-------+
| 0 0 0 | 0 0 0 | 0 0 0 |
| 0 0 0 | 0 0 0 | 0 0 0 |
| 0 0 0 | 0 0 0 | 0 0 0 |
+-------+-------+-------+
| 0 0 0 | 0 0 0 | 0 0 0 |
| 0 0 0 | 0 0 0 | 0 0 0 |
| 0 0 0 | 0 0 0 | 0 0 0 |
+-------+-------+-------+
| 0 0 0 | 0 0 0 | 0 0 0 |
| 0 0 0 | 0 0 0 | 0 0 0 |
| 0 0 0 | 0 0 0 | 0 0 0 |
+-------+-------+-------+
great! The memory was allocated. we now have puzzle1
can we get the grid size...?
we can get the size of puzzle1! That size is 9
did not get size of NULL puzzle! success!
ok ok ok cool cool cool cool cool, but can we get the actual 2-D grid?
good job! much success! get_grid() works!
good job! much success! get_grid() returned null on NULL argument!
Now let's try setting boxes to valid values...
set_box_value() assigned valid value to valid coordinates... SUCCESS
set_box_value() assigned valid value to valid coordinates... SUCCESS
set_box_value() assigned valid value to valid coordinates... SUCCESS
set_box_value() assigned valid value to valid coordinates... SUCCESS
set_box_value() assigned valid value to valid coordinates... SUCCESS
set_box_value() assigned valid value to valid coordinates... SUCCESS
set_box_value() assigned valid value to valid coordinates... SUCCESS
set_box_value() assigned valid value to valid coordinates... SUCCESS
set_box_value() assigned valid value to valid coordinates... SUCCESS
set_box_value() assigned valid value to valid coordinates... SUCCESS
set_box_value() assigned valid value to valid coordinates... SUCCESS
set_box_value() assigned valid value to valid coordinates... SUCCESS
set_box_value() assigned valid value to valid coordinates... SUCCESS
set_box_value() assigned valid value to valid coordinates... SUCCESS
set_box_value() assigned valid value to valid coordinates... SUCCESS
set_box_value() assigned valid value to valid coordinates... SUCCESS
set_box_value() assigned valid value to valid coordinates... SUCCESS
set_box_value() assigned valid value to valid coordinates... SUCCESS
set_box_value() assigned valid value to valid coordinates... SUCCESS
set_box_value() assigned valid value to valid coordinates... SUCCESS
set_box_value() assigned valid value to valid coordinates... SUCCESS
set_box_value() did assigned value = 0 for valid coordinates... SUCCESS
set_box_value() did not assign value to value > puzzle.size... SUCCESS
set_box_value() did not assign value when row > coordinate grid index... SUCCESS
set_box_value() did not assign value when column > largest coordinate grid index... SUCCESS
set_box_value() did not assign value when value < 0 ... SUCCESS
set_box_value() did not assign value when x < 0 ... SUCCESS
set_box_value() did not assign value when y < 0 ... SUCCESS
set_box_value() did assign value to NULL puzzle... SUCCESS
great! First round of numbers set for puzzle1!
1 4 7 3 2 5 6 8 9
2 4 0 0 0 0 0 0 0
3 6 9 0 0 0 0 0 0
4 0 0 0 0 0 0 0 0
5 0 0 0 0 0 0 0 0
6 0 0 0 0 0 0 0 0
7 0 0 0 0 0 0 0 0
8 0 0 0 0 0 0 0 0
9 0 0 0 0 0 0 0 0
+-------+-------+-------+
| 1 4 7 | 3 2 5 | 6 8 9 |
| 2 4 0 | 0 0 0 | 0 0 0 |
| 3 6 9 | 0 0 0 | 0 0 0 |
+-------+-------+-------+
| 4 0 0 | 0 0 0 | 0 0 0 |
| 5 0 0 | 0 0 0 | 0 0 0 |
| 6 0 0 | 0 0 0 | 0 0 0 |
+-------+-------+-------+
| 7 0 0 | 0 0 0 | 0 0 0 |
| 8 0 0 | 0 0 0 | 0 0 0 |
| 9 0 0 | 0 0 0 | 0 0 0 |
+-------+-------+-------+
now try getting one of the box values at row 2 column 0
get_box_value() success!
now try getting a box value at an invalid coordinate (9,9)
get_box_value() boundary case success!
now try getting a box value with a NULL puzzle
get_box_value() boundary case success!
well that was nice. Now test how well this baby cross checks the row, column, and 3x3 for existing numbers
correct! value 9 was in cross section row 1 column 2
check a different value!
correct! value 7 was in cross section row 1 column 2
check different coordinates!
correct! value (7) was in cross section row = 8, column = 2
check different coordinates and value!
correct! value (5) was in cross section row = 4 column = 8
check a different value!
correct! value 8 was NOT in cross section row = 1 column = 2
check a NULL puzzle!
correct! returned true upon NULL puzzle
check is_val_in_box()...
success! correctly detected 3 is in 3x3 box for row 2 column 2
success! correctly detected 3 is in 3x3 box for row 2 column 3
success! correctly returned true for NULL puzzle argument
test NULL file pointers for print methods (should get error msgs)
test NULL puzzle for print methods (should print (null) )
(null)
(null)
Make a 25x25 puzzle!!
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
+----------------+----------------+----------------+----------------+----------------+
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
+----------------+----------------+----------------+----------------+----------------+
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
+----------------+----------------+----------------+----------------+----------------+
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
+----------------+----------------+----------------+----------------+----------------+
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
+----------------+----------------+----------------+----------------+----------------+
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
| 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 | 00 00 00 00 00 |
+----------------+----------------+----------------+----------------+----------------+
set a few numbers..
success! 25 set at (4,4)
success! 4 set at (24,24)
success! 26 NOT set at (24,24)
success! 4 NOT set at (24,25)
success! 4 set at (25,24)
check getters...
puzzle2_size is 25
success! retrieved puzzle2 (24,24) value as 4
success! retrieved puzzle2 (25,24) value as -1
success! retrieved puzzle2 (24,25) value as -1
check cross-sectional validation in puzzle2
correct! 4 is in cross section of point (23, 22)
correct! 4 is in cross section of point (19, 24)
correct! 4 is in cross section of point (24, 12)
correct! 7 is NOT in cross section of point (24, 12)
Make a 36x36 puzzle!!
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
+-------------------+-------------------+-------------------+-------------------+-------------------+-------------------+
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
+-------------------+-------------------+-------------------+-------------------+-------------------+-------------------+
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
+-------------------+-------------------+-------------------+-------------------+-------------------+-------------------+
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
+-------------------+-------------------+-------------------+-------------------+-------------------+-------------------+
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
+-------------------+-------------------+-------------------+-------------------+-------------------+-------------------+
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
+-------------------+-------------------+-------------------+-------------------+-------------------+-------------------+
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
| 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 | 00 00 00 00 00 00 |
+-------------------+-------------------+-------------------+-------------------+-------------------+-------------------+
Make a 16x16 puzzle!!
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
+-------------+-------------+-------------+-------------+
| 00 00 00 00 | 00 00 00 00 | 00 00 00 00 | 00 00 00 00 |
| 00 00 00 00 | 00 00 00 00 | 00 00 00 00 | 00 00 00 00 |
| 00 00 00 00 | 00 00 00 00 | 00 00 00 00 | 00 00 00 00 |
| 00 00 00 00 | 00 00 00 00 | 00 00 00 00 | 00 00 00 00 |
+-------------+-------------+-------------+-------------+
| 00 00 00 00 | 00 00 00 00 | 00 00 00 00 | 00 00 00 00 |
| 00 00 00 00 | 00 00 00 00 | 00 00 00 00 | 00 00 00 00 |
| 00 00 00 00 | 00 00 00 00 | 00 00 00 00 | 00 00 00 00 |
| 00 00 00 00 | 00 00 00 00 | 00 00 00 00 | 00 00 00 00 |
+-------------+-------------+-------------+-------------+
| 00 00 00 00 | 00 00 00 00 | 00 00 00 00 | 00 00 00 00 |
| 00 00 00 00 | 00 00 00 00 | 00 00 00 00 | 00 00 00 00 |
| 00 00 00 00 | 00 00 00 00 | 00 00 00 00 | 00 00 00 00 |
| 00 00 00 00 | 00 00 00 00 | 00 00 00 00 | 00 00 00 00 |
+-------------+-------------+-------------+-------------+
| 00 00 00 00 | 00 00 00 00 | 00 00 00 00 | 00 00 00 00 |
| 00 00 00 00 | 00 00 00 00 | 00 00 00 00 | 00 00 00 00 |
| 00 00 00 00 | 00 00 00 00 | 00 00 00 00 | 00 00 00 00 |
| 00 00 00 00 | 00 00 00 00 | 00 00 00 00 | 00 00 00 00 |
+-------------+-------------+-------------+-------------+
Make a 4x4 puzzle!!
0 0 0 0
0 0 0 0
0 0 0 0
0 0 0 0
+-----+-----+
| 0 0 | 0 0 |
| 0 0 | 0 0 |
+-----+-----+
| 0 0 | 0 0 |
| 0 0 | 0 0 |
+-----+-----+
set a few numbers..
success! 0 set at (3,3)
success! 4 set at (3,3)
success! 3 set at (1,2)
success! 5 NOT set at (2,3)
check getters...
puzzle2_size is 4
success! retrieved puzzle2 (24,24) value as 3
success! retrieved puzzle2 (25,24) value as -1
check cross-sectional validation in puzzle2
0 0 0 0
0 0 0 0
0 3 0 0
0 0 0 4
correct! 4 is in cross section of point (2,3)
correct! 4 is NOT in cross section of point (1,0)
check get_num_to_delete() method
for puzzle size 9 level easy get 44 to delete
for puzzle size 9 level hard get 56 to delete
for puzzle size 9 level medium get -1 to delete
for puzzle size NULL level easy get -1 to delete
for puzzle size 16 level easy get 51 to delete
for puzzle size 16 level easy get 64 to delete
for puzzle size 16 level easy get -1 to delete
test the is_valid_solved() and is_valid_unsolved() methods
returned false w/o seg faults for NULL puzzle args in methods! Final SUCCESS!
deleting puzzles...
puzzles deleted!
end of unit testing! thank you and goodbye!