Artifact
6fc7061e87095edb0a40dce007e4c7b22e5ed85e :
File
tests/tests.scm
— part of check-in
[b2dff05073]
at
2011-06-29 15:31:09
on branch debug-printing
— Fixed mishandling of an items list with no items, cleaned up tests
(user:
mrwellan
size: 3572)
[more...]
0000: 28 75 73 65 20 74 65 73 74 29 0a 3b 3b 20 28 72 (use test).;; (r
0010: 65 71 75 69 72 65 2d 6c 69 62 72 61 72 79 20 61 equire-library a
0020: 72 67 73 29 0a 0a 28 69 6e 63 6c 75 64 65 20 22 rgs)..(include "
0030: 2e 2e 2f 63 6f 6d 6d 6f 6e 2e 73 63 6d 22 29 0a ../common.scm").
0040: 28 69 6e 63 6c 75 64 65 20 22 2e 2e 2f 6b 65 79 (include "../key
0050: 73 2e 73 63 6d 22 29 0a 28 69 6e 63 6c 75 64 65 s.scm").(include
0060: 20 22 2e 2e 2f 64 62 2e 73 63 6d 22 29 0a 28 69 "../db.scm").(i
0070: 6e 63 6c 75 64 65 20 22 2e 2e 2f 63 6f 6e 66 69 nclude "../confi
0080: 67 66 2e 73 63 6d 22 29 0a 28 69 6e 63 6c 75 64 gf.scm").(includ
0090: 65 20 22 2e 2e 2f 70 72 6f 63 65 73 73 2e 73 63 e "../process.sc
00a0: 6d 22 29 0a 28 69 6e 63 6c 75 64 65 20 22 2e 2e m").(include "..
00b0: 2f 6c 61 75 6e 63 68 2e 73 63 6d 22 29 0a 28 69 /launch.scm").(i
00c0: 6e 63 6c 75 64 65 20 22 2e 2e 2f 69 74 65 6d 73 nclude "../items
00d0: 2e 73 63 6d 22 29 0a 28 69 6e 63 6c 75 64 65 20 .scm").(include
00e0: 22 2e 2e 2f 72 75 6e 73 2e 73 63 6d 22 29 0a 0a "../runs.scm")..
00f0: 28 64 65 66 69 6e 65 20 63 6f 6e 66 66 69 6c 65 (define conffile
0100: 20 23 66 29 0a 28 74 65 73 74 20 22 52 65 61 64 #f).(test "Read
0110: 20 61 20 63 6f 6e 66 69 67 22 20 23 74 20 28 68 a config" #t (h
0120: 61 73 68 2d 74 61 62 6c 65 3f 20 28 72 65 61 64 ash-table? (read
0130: 2d 63 6f 6e 66 69 67 20 22 74 65 73 74 2e 63 6f -config "test.co
0140: 6e 66 69 67 22 29 29 29 0a 28 74 65 73 74 20 22 nfig"))).(test "
0150: 52 65 61 64 20 61 20 63 6f 6e 66 69 67 20 74 68 Read a config th
0160: 61 74 20 64 6f 65 73 6e 27 74 20 65 78 69 73 74 at doesn't exist
0170: 22 20 23 74 20 28 68 61 73 68 2d 74 61 62 6c 65 " #t (hash-table
0180: 3f 20 28 72 65 61 64 2d 63 6f 6e 66 69 67 20 22 ? (read-config "
0190: 6e 61 64 61 2e 63 6f 6e 66 69 67 22 29 29 29 0a nada.config"))).
01a0: 0a 28 73 65 74 21 20 63 6f 6e 66 66 69 6c 65 20 .(set! conffile
01b0: 28 72 65 61 64 2d 63 6f 6e 66 69 67 20 22 74 65 (read-config "te
01c0: 73 74 2e 63 6f 6e 66 69 67 22 29 29 0a 28 74 65 st.config")).(te
01d0: 73 74 20 22 47 65 74 20 61 76 61 69 6c 61 62 6c st "Get availabl
01e0: 65 20 64 69 73 6b 73 70 61 63 65 22 20 23 74 20 e diskspace" #t
01f0: 28 6e 75 6d 62 65 72 3f 20 28 67 65 74 2d 64 66 (number? (get-df
0200: 20 22 2e 2f 22 29 29 29 0a 28 74 65 73 74 20 22 "./"))).(test "
0210: 47 65 74 20 62 65 73 74 20 64 69 72 22 20 23 74 Get best dir" #t
0220: 20 28 6c 65 74 20 28 28 62 65 73 74 64 69 72 20 (let ((bestdir
0230: 28 67 65 74 2d 62 65 73 74 2d 64 69 73 6b 20 63 (get-best-disk c
0240: 6f 6e 66 66 69 6c 65 29 29 29 0a 09 09 09 20 20 onffile)))....
0250: 20 20 20 20 28 6f 72 20 28 65 71 75 61 6c 3f 20 (or (equal?
0260: 22 2e 2f 22 20 20 20 62 65 73 74 64 69 72 29 0a "./" bestdir).
0270: 09 09 09 09 20 20 28 65 71 75 61 6c 3f 20 22 2f .... (equal? "/
0280: 74 6d 70 22 20 62 65 73 74 64 69 72 29 29 29 29 tmp" bestdir))))
0290: 0a 0a 3b 3b 20 64 62 0a 28 64 65 66 69 6e 65 20 ..;; db.(define
02a0: 72 6f 77 20 20 20 20 28 76 65 63 74 6f 72 20 22 row (vector "
02b0: 61 22 20 22 62 22 20 22 63 22 20 22 62 6c 61 68 a" "b" "c" "blah
02c0: 22 29 29 0a 28 64 65 66 69 6e 65 20 68 65 61 64 ")).(define head
02d0: 65 72 20 28 6c 69 73 74 20 22 63 6f 6c 31 22 20 er (list "col1"
02e0: 22 63 6f 6c 32 22 20 22 63 6f 6c 33 22 20 22 63 "col2" "col3" "c
02f0: 6f 6c 34 22 29 29 0a 28 74 65 73 74 20 22 47 65 ol4")).(test "Ge
0300: 74 20 72 6f 77 20 62 79 20 68 65 61 64 65 72 22 t row by header"
0310: 20 22 62 6c 61 68 22 20 28 64 62 3a 67 65 74 2d "blah" (db:get-
0320: 76 61 6c 75 65 2d 62 79 2d 68 65 61 64 65 72 20 value-by-header
0330: 72 6f 77 20 68 65 61 64 65 72 20 22 63 6f 6c 34 row header "col4
0340: 22 29 29 0a 0a 3b 3b 20 28 64 65 66 69 6e 65 20 "))..;; (define
0350: 2a 74 6f 70 70 61 74 68 2a 20 22 74 65 73 74 73 *toppath* "tests
0360: 22 29 0a 28 64 65 66 69 6e 65 20 2a 64 62 2a 20 ").(define *db*
0370: 23 66 29 0a 28 74 65 73 74 20 22 73 65 74 75 70 #f).(test "setup
0380: 20 66 6f 72 20 72 75 6e 22 20 23 74 20 28 62 65 for run" #t (be
0390: 67 69 6e 20 28 73 65 74 75 70 2d 66 6f 72 2d 72 gin (setup-for-r
03a0: 75 6e 29 0a 09 09 09 09 28 73 74 72 69 6e 67 3f un).....(string?
03b0: 20 28 67 65 74 65 6e 76 20 22 4d 54 5f 52 55 4e (getenv "MT_RUN
03c0: 5f 41 52 45 41 5f 48 4f 4d 45 22 29 29 29 29 0a _AREA_HOME")))).
03d0: 28 74 65 73 74 20 22 6f 70 65 6e 2d 64 62 22 20 (test "open-db"
03e0: 23 74 20 28 62 65 67 69 6e 0a 09 09 20 20 20 20 #t (begin...
03f0: 20 28 73 65 74 21 20 2a 64 62 2a 20 28 6f 70 65 (set! *db* (ope
0400: 6e 2d 64 62 29 29 0a 09 09 20 20 20 20 20 28 69 n-db))... (i
0410: 66 20 2a 64 62 2a 20 23 74 20 23 66 29 29 29 0a f *db* #t #f))).
0420: 0a 28 74 65 73 74 20 22 67 65 74 20 63 70 75 20 .(test "get cpu
0430: 6c 6f 61 64 22 20 23 74 20 28 6e 75 6d 62 65 72 load" #t (number
0440: 3f 20 28 67 65 74 2d 63 70 75 2d 6c 6f 61 64 29 ? (get-cpu-load)
0450: 29 29 0a 28 74 65 73 74 20 22 67 65 74 20 75 6e )).(test "get un
0460: 61 6d 65 22 20 20 20 20 23 74 20 28 73 74 72 69 ame" #t (stri
0470: 6e 67 3f 20 28 67 65 74 2d 75 6e 61 6d 65 29 29 ng? (get-uname))
0480: 29 0a 0a 28 74 65 73 74 20 22 67 65 74 20 76 61 )..(test "get va
0490: 6c 69 64 76 61 6c 75 65 73 20 61 73 20 6c 69 73 lidvalues as lis
04a0: 74 22 20 28 6c 69 73 74 20 22 73 74 61 72 74 22 t" (list "start"
04b0: 20 22 65 6e 64 22 20 22 63 6f 6d 70 6c 65 74 65 "end" "complete
04c0: 64 22 29 0a 20 20 20 20 20 20 28 73 74 72 69 6e d"). (strin
04d0: 67 2d 73 70 6c 69 74 20 28 63 6f 6e 66 69 67 2d g-split (config-
04e0: 6c 6f 6f 6b 75 70 20 2a 63 6f 6e 66 69 67 64 61 lookup *configda
04f0: 74 2a 20 22 76 61 6c 69 64 76 61 6c 75 65 73 22 t* "validvalues"
0500: 20 22 73 74 61 74 65 22 29 29 29 0a 0a 28 66 6f "state")))..(fo
0510: 72 2d 65 61 63 68 20 28 6c 61 6d 62 64 61 20 28 r-each (lambda (
0520: 69 74 65 6d 29 0a 09 20 20 20 20 28 74 65 73 74 item).. (test
0530: 20 28 63 6f 6e 63 20 22 67 65 74 20 76 61 6c 69 (conc "get vali
0540: 64 20 69 74 65 6d 73 20 28 22 20 69 74 65 6d 20 d items (" item
0550: 22 29 22 29 0a 09 09 20 20 69 74 65 6d 20 28 63 ")")... item (c
0560: 68 65 63 6b 2d 76 61 6c 69 64 2d 69 74 65 6d 73 heck-valid-items
0570: 20 22 73 74 61 74 65 22 20 69 74 65 6d 29 29 29 "state" item)))
0580: 0a 09 20 20 28 6c 69 73 74 20 22 73 74 61 72 74 .. (list "start
0590: 22 20 22 65 6e 64 22 20 22 63 6f 6d 70 6c 65 74 " "end" "complet
05a0: 65 64 22 29 29 0a 0a 28 66 6f 72 2d 65 61 63 68 ed"))..(for-each
05b0: 20 28 6c 61 6d 62 64 61 20 28 69 74 65 6d 29 0a (lambda (item).
05c0: 09 20 20 20 20 28 74 65 73 74 20 28 63 6f 6e 63 . (test (conc
05d0: 20 22 67 65 74 20 76 61 6c 69 64 20 69 74 65 6d "get valid item
05e0: 73 20 28 22 20 69 74 65 6d 20 22 29 22 29 0a 09 s (" item ")")..
05f0: 09 20 20 69 74 65 6d 20 28 63 68 65 63 6b 2d 76 . item (check-v
0600: 61 6c 69 64 2d 69 74 65 6d 73 20 22 73 74 61 74 alid-items "stat
0610: 75 73 22 20 69 74 65 6d 29 29 29 0a 09 20 20 28 us" item))).. (
0620: 6c 69 73 74 20 22 70 61 73 73 22 20 22 66 61 69 list "pass" "fai
0630: 6c 22 20 22 6e 2f 61 22 29 29 0a 0a 28 74 65 73 l" "n/a"))..(tes
0640: 74 20 22 77 72 69 74 65 20 65 6e 76 20 66 69 6c t "write env fil
0650: 65 73 22 20 22 6e 61 64 61 2e 63 73 68 22 20 28 es" "nada.csh" (
0660: 62 65 67 69 6e 0a 20 20 20 20 20 20 20 20 20 20 begin.
0670: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
0680: 20 20 20 20 20 20 20 20 20 20 20 20 28 73 61 76 (sav
0690: 65 2d 65 6e 76 69 72 6f 6e 6d 65 6e 74 2d 61 73 e-environment-as
06a0: 2d 66 69 6c 65 73 20 22 6e 61 64 61 22 29 0a 20 -files "nada").
06b0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
06c0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
06d0: 20 20 20 20 20 28 61 6e 64 20 28 66 69 6c 65 2d (and (file-
06e0: 65 78 69 73 74 73 3f 20 22 6e 61 64 61 2e 73 68 exists? "nada.sh
06f0: 22 29 0a 20 20 20 20 09 09 09 20 20 20 20 20 20 "). ...
0700: 20 20 20 20 20 20 20 20 20 20 20 28 66 69 6c 65 (file
0710: 2d 65 78 69 73 74 73 3f 20 22 6e 61 64 61 2e 63 -exists? "nada.c
0720: 73 68 22 29 29 29 29 0a 0a 28 74 65 73 74 20 22 sh"))))..(test "
0730: 67 65 74 20 61 6c 6c 20 6c 65 67 61 6c 20 74 65 get all legal te
0740: 73 74 73 22 20 28 6c 69 73 74 20 22 72 75 6e 66 sts" (list "runf
0750: 69 72 73 74 22 20 22 72 75 6e 77 69 74 68 66 69 irst" "runwithfi
0760: 72 73 74 22 20 22 73 69 6e 67 6c 65 74 65 73 74 rst" "singletest
0770: 22 20 22 73 69 6e 67 6c 65 74 65 73 74 32 22 20 " "singletest2"
0780: 22 73 71 6c 69 74 65 73 70 65 65 64 22 29 20 28 "sqlitespeed") (
0790: 73 6f 72 74 20 28 67 65 74 2d 61 6c 6c 2d 6c 65 sort (get-all-le
07a0: 67 61 6c 2d 74 65 73 74 73 29 20 73 74 72 69 6e gal-tests) strin
07b0: 67 3c 3d 3f 29 29 0a 0a 28 74 65 73 74 20 22 72 g<=?))..(test "r
07c0: 65 67 69 73 74 65 72 2d 74 65 73 74 2c 20 74 65 egister-test, te
07d0: 73 74 20 69 6e 66 6f 22 20 22 4e 4f 54 5f 53 54 st info" "NOT_ST
07e0: 41 52 54 45 44 22 0a 20 20 20 20 20 20 28 62 65 ARTED". (be
07f0: 67 69 6e 0a 09 28 72 65 67 69 73 74 65 72 2d 74 gin..(register-t
0800: 65 73 74 20 2a 64 62 2a 20 31 20 22 6e 61 64 61 est *db* 1 "nada
0810: 22 20 22 22 29 0a 09 28 74 65 73 74 3a 67 65 74 " "")..(test:get
0820: 2d 73 74 61 74 65 20 28 64 62 3a 67 65 74 2d 74 -state (db:get-t
0830: 65 73 74 2d 69 6e 66 6f 20 2a 64 62 2a 20 31 20 est-info *db* 1
0840: 22 6e 61 64 61 22 20 22 22 29 29 29 29 0a 0a 28 "nada" ""))))..(
0850: 74 65 73 74 20 22 67 65 74 2d 6b 65 79 73 22 20 test "get-keys"
0860: 22 73 79 73 6e 61 6d 65 22 20 28 6b 65 79 3a 67 "sysname" (key:g
0870: 65 74 2d 66 69 65 6c 64 6e 61 6d 65 20 28 63 61 et-fieldname (ca
0880: 72 20 28 73 6f 72 74 20 28 64 62 2d 67 65 74 2d r (sort (db-get-
0890: 6b 65 79 73 20 2a 64 62 2a 29 28 6c 61 6d 62 64 keys *db*)(lambd
08a0: 61 20 28 61 20 62 29 28 73 74 72 69 6e 67 3e 3d a (a b)(string>=
08b0: 3f 20 28 76 65 63 74 6f 72 2d 72 65 66 20 61 20 ? (vector-ref a
08c0: 30 29 28 76 65 63 74 6f 72 2d 72 65 66 20 62 20 0)(vector-ref b
08d0: 30 29 29 29 29 29 29 29 0a 0a 28 64 65 66 69 6e 0)))))))..(defin
08e0: 65 20 72 65 6d 61 72 67 73 20 28 61 72 67 73 3a e remargs (args:
08f0: 67 65 74 2d 61 72 67 73 0a 09 09 20 27 28 22 62 get-args... '("b
0900: 61 72 22 20 22 66 6f 6f 22 20 22 3a 72 75 6e 6e ar" "foo" ":runn
0910: 61 6d 65 22 20 22 62 6f 62 22 20 22 3a 73 79 73 ame" "bob" ":sys
0920: 6e 61 6d 65 22 20 22 75 62 75 6e 74 75 22 20 22 name" "ubuntu" "
0930: 3a 66 73 6e 61 6d 65 22 20 22 6e 66 73 22 20 22 :fsname" "nfs" "
0940: 3a 64 61 74 61 70 61 74 68 22 20 22 62 6c 61 68 :datapath" "blah
0950: 2f 66 6f 6f 22 20 22 6e 61 64 61 22 29 0a 09 09 /foo" "nada")...
0960: 20 28 6c 69 73 74 20 22 3a 72 75 6e 6e 61 6d 65 (list ":runname
0970: 22 20 22 3a 73 74 61 74 65 22 20 22 3a 73 74 61 " ":state" ":sta
0980: 74 75 73 22 29 0a 09 09 20 28 6c 69 73 74 20 22 tus")... (list "
0990: 2d 68 22 29 0a 09 09 20 61 72 67 73 3a 61 72 67 -h")... args:arg
09a0: 2d 68 61 73 68 0a 09 09 20 30 29 29 0a 0a 28 74 -hash... 0))..(t
09b0: 65 73 74 20 22 72 65 67 69 73 74 65 72 2d 72 75 est "register-ru
09c0: 6e 22 20 23 74 20 28 6e 75 6d 62 65 72 3f 20 28 n" #t (number? (
09d0: 72 65 67 69 73 74 65 72 2d 72 75 6e 20 2a 64 62 register-run *db
09e0: 2a 20 28 64 62 2d 67 65 74 2d 6b 65 79 73 20 2a * (db-get-keys *
09f0: 64 62 2a 29 29 29 29 0a 0a 3b 3b 28 74 65 73 74 db*))))..;;(test
0a00: 20 22 75 70 64 61 74 65 2d 74 65 73 74 2d 69 6e "update-test-in
0a10: 66 6f 22 20 23 74 20 28 74 65 73 74 2d 75 70 64 fo" #t (test-upd
0a20: 61 74 65 2d 6d 65 74 61 2d 69 6e 66 6f 20 2a 64 ate-meta-info *d
0a30: 62 2a 20 31 20 22 6e 61 64 61 22 20 0a 28 73 65 b* 1 "nada" .(se
0a40: 74 65 6e 76 20 22 42 4c 41 48 46 4f 4f 22 20 22 tenv "BLAHFOO" "
0a50: 31 32 33 34 22 29 0a 28 75 6e 73 65 74 65 6e 76 1234").(unsetenv
0a60: 20 22 4e 41 44 41 46 4f 4f 22 29 0a 28 74 65 73 "NADAFOO").(tes
0a70: 74 20 22 65 6e 76 20 74 65 6d 70 20 6f 76 65 72 t "env temp over
0a80: 72 69 64 65 73 22 20 22 78 79 7a 22 20 28 6c 65 rides" "xyz" (le
0a90: 74 20 28 28 70 72 65 76 76 61 6c 73 20 28 61 6c t ((prevvals (al
0aa0: 69 73 74 2d 3e 65 6e 76 2d 76 61 72 73 20 27 28 ist->env-vars '(
0ab0: 28 22 42 4c 41 48 46 4f 4f 22 20 34 33 32 31 29 ("BLAHFOO" 4321)
0ac0: 28 22 4e 41 44 41 46 4f 4f 22 20 78 79 7a 29 29 ("NADAFOO" xyz))
0ad0: 29 29 0a 09 09 09 09 20 20 20 20 20 20 20 28 72 ))..... (r
0ae0: 65 73 75 6c 74 20 20 20 28 67 65 74 2d 65 6e 76 esult (get-env
0af0: 69 72 6f 6e 6d 65 6e 74 2d 76 61 72 69 61 62 6c ironment-variabl
0b00: 65 20 22 4e 41 44 41 46 4f 4f 22 29 29 29 0a 09 e "NADAFOO")))..
0b10: 09 09 09 20 20 20 20 28 61 6c 69 73 74 2d 3e 65 ... (alist->e
0b20: 6e 76 2d 76 61 72 73 20 70 72 65 76 76 61 6c 73 nv-vars prevvals
0b30: 29 0a 09 09 09 09 20 20 20 20 72 65 73 75 6c 74 )..... result
0b40: 29 29 0a 0a 28 74 65 73 74 20 22 65 6e 76 20 72 ))..(test "env r
0b50: 65 73 74 6f 72 65 64 22 20 22 31 32 33 34 22 20 estored" "1234"
0b60: 28 67 65 74 2d 65 6e 76 69 72 6f 6e 6d 65 6e 74 (get-environment
0b70: 2d 76 61 72 69 61 62 6c 65 20 22 42 4c 41 48 46 -variable "BLAHF
0b80: 4f 4f 22 29 29 0a 0a 0a 28 74 65 73 74 20 22 49 OO"))...(test "I
0b90: 74 65 6d 73 20 61 73 73 6f 63 22 20 22 45 6c 65 tems assoc" "Ele
0ba0: 70 68 61 6e 74 22 20 28 63 61 64 61 72 20 28 63 phant" (cadar (c
0bb0: 61 64 72 20 28 69 74 65 6d 2d 61 73 73 6f 63 2d adr (item-assoc-
0bc0: 3e 69 74 65 6d 2d 6c 69 73 74 20 27 28 28 22 41 >item-list '(("A
0bd0: 4e 49 4d 41 4c 22 20 22 45 6c 65 70 68 61 6e 74 NIMAL" "Elephant
0be0: 20 4c 69 6f 6e 22 29 28 22 53 45 41 53 4f 4e 22 Lion")("SEASON"
0bf0: 20 22 53 70 72 69 6e 67 20 46 61 6c 6c 22 29 29 "Spring Fall"))
0c00: 29 29 29 29 0a 28 73 65 74 21 20 2a 76 65 72 62 )))).(set! *verb
0c10: 6f 73 69 74 79 2a 20 36 29 0a 28 74 65 73 74 20 osity* 6).(test
0c20: 22 49 74 65 6d 73 20 61 73 73 6f 63 22 20 27 28 "Items assoc" '(
0c30: 29 28 69 74 65 6d 2d 61 73 73 6f 63 2d 3e 69 74 )(item-assoc->it
0c40: 65 6d 2d 6c 69 73 74 20 27 28 28 22 61 22 20 22 em-list '(("a" "
0c50: 61 20 62 20 63 20 64 22 29 28 22 62 22 20 22 63 a b c d")("b" "c
0c60: 20 64 20 65 22 29 28 22 63 22 20 22 22 29 28 22 d e")("c" "")("
0c70: 64 22 29 29 29 29 0a 28 73 65 74 21 20 2a 76 65 d")))).(set! *ve
0c80: 72 62 6f 73 69 74 79 2a 20 2d 31 29 0a 28 74 65 rbosity* -1).(te
0c90: 73 74 20 22 49 74 65 6d 73 20 61 73 73 6f 63 20 st "Items assoc
0ca0: 65 6d 70 74 79 20 69 74 65 6d 73 22 20 27 28 29 empty items" '()
0cb0: 20 20 20 28 69 74 65 6d 2d 61 73 73 6f 63 2d 3e (item-assoc->
0cc0: 69 74 65 6d 2d 6c 69 73 74 20 27 28 28 22 41 22 item-list '(("A"
0cd0: 29 29 29 29 0a 28 73 65 74 21 20 2a 76 65 72 62 )))).(set! *verb
0ce0: 6f 73 69 74 79 2a 20 31 29 0a 28 74 65 73 74 20 osity* 1).(test
0cf0: 22 49 74 65 6d 73 20 74 61 62 6c 65 22 20 22 53 "Items table" "S
0d00: 45 41 53 4f 4e 22 20 28 63 61 61 64 61 72 20 28 EASON" (caadar (
0d10: 69 74 65 6d 2d 74 61 62 6c 65 2d 3e 69 74 65 6d item-table->item
0d20: 2d 6c 69 73 74 20 27 28 28 22 41 4e 49 4d 41 4c -list '(("ANIMAL
0d30: 22 20 22 45 6c 65 70 68 61 6e 74 20 4c 69 6f 6e " "Elephant Lion
0d40: 22 29 28 22 53 45 41 53 4f 4e 22 20 22 53 70 72 ")("SEASON" "Spr
0d50: 69 6e 67 20 57 69 6e 74 65 72 22 29 29 29 29 29 ing Winter")))))
0d60: 0a 28 74 65 73 74 20 22 49 74 65 6d 73 20 74 61 .(test "Items ta
0d70: 62 6c 65 20 65 6d 70 74 79 20 69 74 65 6d 73 20 ble empty items
0d80: 49 22 20 27 28 29 20 28 69 74 65 6d 2d 74 61 62 I" '() (item-tab
0d90: 6c 65 2d 3e 69 74 65 6d 2d 6c 69 73 74 20 27 28 le->item-list '(
0da0: 28 22 41 22 29 29 29 29 0a 28 74 65 73 74 20 22 ("A")))).(test "
0db0: 49 74 65 6d 73 20 74 61 62 6c 65 20 65 6d 70 74 Items table empt
0dc0: 79 20 69 74 65 6d 73 20 49 49 22 20 27 28 29 20 y items II" '()
0dd0: 28 69 74 65 6d 2d 74 61 62 6c 65 2d 3e 69 74 65 (item-table->ite
0de0: 6d 2d 6c 69 73 74 20 27 28 28 22 41 22 20 22 22 m-list '(("A" ""
0df0: 29 29 29 29 ))))