Small set of tests for strings and chars.

This commit is contained in:
mainzelm 2003-02-25 13:20:13 +00:00
parent 57463ce596
commit e0b3cbd1b1
2 changed files with 22 additions and 1 deletions

View File

@ -0,0 +1,15 @@
(add-test! 'file-name-sans-extension 'string-and-chars
(lambda ()
(and (string=? (file-name-sans-extension ".scm") ".scm")
(string=? (file-name-sans-extension "/.scm") "/.scm")
(string=? (file-name-sans-extension "a/.scm") "a/.scm")
(string=? (file-name-sans-extension "t.scm") "t")
(string=? (file-name-sans-extension "a/t.scm") "a/t")
(string=? (file-name-sans-extension "/a/t.scm") "/a/t")
(string=? (file-name-sans-extension "/a/b.c/t.scm") "/a/b.c/t")
(string=? (file-name-sans-extension "") "")
(string=? (file-name-sans-extension "t") "t")
(string=? (file-name-sans-extension "a/t") "a/t")
(string=? (file-name-sans-extension "/a/t") "/a/t")
(string=? (file-name-sans-extension "/a/b.c/t") "/a/b.c/t"))))

View File

@ -70,6 +70,11 @@
(lambda ()
(> (string-length (system-name)) 0)))))
(define-structure strings-and-chars-test (export)
(open scheme-with-scsh
test-base)
(files strings-and-chars-test))
(define-structure test-all
(export test-all)
(open scheme
@ -77,7 +82,8 @@
add-env-test
process-state-test
system-parameter-tests
file-system-test))
file-system-test
strings-and-chars-test))