1 USING: ascii tools.test sequences kernel math ;
4 [ t ] [ CHAR: a letter? ] unit-test
5 [ f ] [ CHAR: A letter? ] unit-test
6 [ f ] [ CHAR: a LETTER? ] unit-test
7 [ t ] [ CHAR: A LETTER? ] unit-test
8 [ t ] [ CHAR: 0 digit? ] unit-test
9 [ f ] [ CHAR: x digit? ] unit-test
12 0 "There are Four Upper Case characters"
13 [ LETTER? [ 1+ ] when ] each
16 [ t f ] [ CHAR: \s ascii? 400 ascii? ] unit-test
18 [ "HELLO HOW ARE YOU?" ] [ "hellO hOw arE YOU?" >upper ] unit-test
19 [ "i'm good thx bai" ] [ "I'm Good THX bai" >lower ] unit-test