-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgregg_audit.unit
124 lines (94 loc) · 27.6 KB
/
gregg_audit.unit
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
#!/usr/local/bin/koios
# koios-polos (axis of heaven) unit testing meta-language
#23456789-12 123456789-123456789-123456789-12345 123456789-123456789-123456 123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456789- 123456789- 123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456789- 123456789-123456789-
#==(verb)=== ===========(description)=========== =====(function)=========== ========================(arguments)================================================================= ==(test)== ==========================(results)================================================================= ========(var)=======
PREP include the prototype headers - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
incl include public header gregg.h - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
#23456789-12 123456789-123456789-123456789-12345 123456789-123456789-123456 123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456789- 123456789- 123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456789- 123456789-123456789-
#==(verb)=== ===========(description)=========== =====(function)=========== ========================(arguments)================================================================= ==(test)== ==========================(results)================================================================= ========(var)=======
SCRP (AUDIT) verify auditing individual letters 0s letters AUDIT_gregg_letter ((01.---)) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
COND initialize the testing environment - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ((01.001)) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
exec start testing PROG__unit_quiet i_equal 0
local create working/return variable - - - - - - - - - - - - - char x_act [LEN_FULL] = "";
local create working/return variable - - - - - - - - - - - - - char x_exp [LEN_FULL] = "";
COND verify a simple first entry - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ((01.002)) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
exec call build AUDIT_build_fancy 0 , 0 , "k" , x_act i_equal 0
exec call build (end) AUDIT_build_fancy 100 , 0 , "" , x_act i_equal 0
code create expected output - - - - - - - - - - - - - sprintf (x_exp, BOLD_GRN "k" BOLD_OFF);
echo ... check fancy version - - - - - - - - - - - - - x_act s_equal [[ x_exp ]]
COND verify several characters (overwrite last test) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ((01.002)) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
exec call build AUDIT_build_fancy 0 , 0 , "k" , x_act i_equal 0
exec call build AUDIT_build_fancy 1 , 0 , "a" , x_act i_equal 0
exec call build AUDIT_build_fancy 2 , 0 , "t" , x_act i_equal 0
exec call build (end) AUDIT_build_fancy 100 , 0 , "" , x_act i_equal 0
code create expected output - - - - - - - - - - - - - sprintf (x_exp, BOLD_GRN "k·a·t" BOLD_OFF);
echo ... check fancy version - - - - - - - - - - - - - x_act s_equal [[ x_exp ]]
COND verify a bad character - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ((01.002)) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
exec call build AUDIT_build_fancy 0 , -1 , "c" , x_act i_equal 0
exec call build (end) AUDIT_build_fancy 100 , 0 , "" , x_act i_equal 0
code create expected output - - - - - - - - - - - - - sprintf (x_exp, BOLD_ERR "c" BOLD_OFF BOLD_GRN BOLD_OFF);
echo ... check fancy version - - - - - - - - - - - - - x_act s_equal [[ x_exp ]]
COND verify a bad lead character - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ((01.002)) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
exec call build AUDIT_build_fancy 0 , -1 , "c" , x_act i_equal 0
exec call build AUDIT_build_fancy 1 , 0 , "a" , x_act i_equal 0
exec call build AUDIT_build_fancy 2 , 0 , "t" , x_act i_equal 0
exec call build (end) AUDIT_build_fancy 100 , 0 , "" , x_act i_equal 0
code create expected output - - - - - - - - - - - - - sprintf (x_exp, BOLD_ERR "c" BOLD_OFF BOLD_GRN "·a·t" BOLD_OFF);
echo ... check fancy version - - - - - - - - - - - - - x_act s_equal [[ x_exp ]]
COND verify a bad middle character - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ((01.002)) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
exec call build AUDIT_build_fancy 0 , 0 , "k" , x_act i_equal 0
exec call build AUDIT_build_fancy 1 , -1 , "q" , x_act i_equal 0
exec call build AUDIT_build_fancy 2 , 0 , "t" , x_act i_equal 0
exec call build (end) AUDIT_build_fancy 100 , 0 , "" , x_act i_equal 0
code create expected output - - - - - - - - - - - - - sprintf (x_exp, BOLD_GRN "k·" BOLD_ERR "q" BOLD_OFF BOLD_GRN "·t" BOLD_OFF);
echo ... check fancy version - - - - - - - - - - - - - x_act s_equal [[ x_exp ]]
COND verify a bad tail character - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ((01.002)) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
exec call build AUDIT_build_fancy 0 , 0 , "k" , x_act i_equal 0
exec call build AUDIT_build_fancy 1 , 0 , "a" , x_act i_equal 0
exec call build AUDIT_build_fancy 2 , -1 , "W" , x_act i_equal 0
exec call build (end) AUDIT_build_fancy 100 , 0 , "" , x_act i_equal 0
code create expected output - - - - - - - - - - - - - sprintf (x_exp, BOLD_GRN "k·a·" BOLD_ERR "W" BOLD_OFF BOLD_GRN BOLD_OFF);
echo ... check fancy version - - - - - - - - - - - - - x_act s_equal [[ x_exp ]]
COND complete testing - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ((04.003)) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
exec stop testing PROG__unit_end i_equal 0
#23456789-12 123456789-123456789-123456789-12345 123456789-123456789-123456 123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456789- 123456789- 123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456789- 123456789-123456789-
#==(verb)=== ===========(description)=========== =====(function)=========== ========================(arguments)================================================================= ==(test)== ==========================(results)================================================================= ========(var)=======
SCRP (AUDIT) verify auditing gregg outlines 0s outline AUDIT_gregg_outline ((01.---)) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
COND initialize the testing environment - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ((01.001)) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
exec start testing PROG__unit_quiet i_equal 0
local create working/return variable - - - - - - - - - - - - - char x_act [LEN_FULL] = "";
local create working/return variable - - - - - - - - - - - - - char x_exp [LEN_FULL] = "";
COND verify a simple, one letter outline - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ((01.002)) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
exec call outline AUDIT_gregg_outline "k" , x_act i_equal 0
code create expected output - - - - - - - - - - - - - sprintf (x_exp, BOLD_GRN "k" BOLD_OFF);
echo ... check fancy version - - - - - - - - - - - - - x_act s_equal [[ x_exp ]]
COND verify a small word - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ((01.002)) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
exec call outline AUDIT_gregg_outline "k·a·t" , x_act i_equal 0
code create expected output - - - - - - - - - - - - - sprintf (x_exp, BOLD_GRN "k·a·t" BOLD_OFF);
echo ... check fancy version - - - - - - - - - - - - - x_act s_equal [[ x_exp ]]
COND verify a bad first letter - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ((01.002)) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
exec call outline AUDIT_gregg_outline "c·a·t" , x_act i_equal 0
code create expected output - - - - - - - - - - - - - sprintf (x_exp, BOLD_ERR "c" BOLD_OFF BOLD_GRN "·a·t" BOLD_OFF);
echo ... check fancy version - - - - - - - - - - - - - x_act s_equal [[ x_exp ]]
COND verify a bad middle character - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ((01.002)) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
exec call outline AUDIT_gregg_outline "k·q·t" , x_act i_equal 0
code create expected output - - - - - - - - - - - - - sprintf (x_exp, BOLD_GRN "k·" BOLD_ERR "q" BOLD_OFF BOLD_GRN "·t" BOLD_OFF);
echo ... check fancy version - - - - - - - - - - - - - x_act s_equal [[ x_exp ]]
COND verify a bad tail character - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ((01.002)) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
exec call outline AUDIT_gregg_outline "k·a·W" , x_act i_equal 0
code create expected output - - - - - - - - - - - - - sprintf (x_exp, BOLD_GRN "k·a·" BOLD_ERR "W" BOLD_OFF BOLD_GRN BOLD_OFF);
echo ... check fancy version - - - - - - - - - - - - - x_act s_equal [[ x_exp ]]
COND verify with special character - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ((01.002)) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
exec call outline AUDIT_gregg_outline "/·e·d" , x_act i_equal 0
code create expected output - - - - - - - - - - - - - sprintf (x_exp, BOLD_GRN "/·e·d" BOLD_OFF);
echo ... check fancy version - - - - - - - - - - - - - x_act s_equal [[ x_exp ]]
COND verify with suffix - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ((01.002)) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
exec call outline AUDIT_gregg_outline "a·k·t·>·´" , x_act i_equal 0
code create expected output - - - - - - - - - - - - - sprintf (x_exp, BOLD_GRN "a·k·t·>·´" BOLD_OFF);
echo ... check fancy version - - - - - - - - - - - - - x_act s_equal [[ x_exp ]]
COND verify with complex vowels (not legal) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ((01.002)) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
exec call outline AUDIT_gregg_outline "k·akt·t" , x_act i_equal 0
code create expected output - - - - - - - - - - - - - sprintf (x_exp, BOLD_GRN "k·" BOLD_ERR "akt" BOLD_OFF BOLD_GRN "·t" BOLD_OFF);
echo ... check fancy version - - - - - - - - - - - - - x_act s_equal [[ x_exp ]]
COND complete testing - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ((04.003)) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
exec stop testing PROG__unit_end i_equal 0