CMUCL commit: src/i18n/tests (norm-test.lisp word-break-test.lisp)
Raymond Toy
rtoy at common-lisp.net
Sat Sep 4 03:15:49 CEST 2010
Date: Friday, September 3, 2010 @ 21:15:49
Author: rtoy
Path: /project/cmucl/cvsroot/src/i18n/tests
Modified: norm-test.lisp word-break-test.lisp
Merge changes from 20b branch.
----------------------+
norm-test.lisp | 11 ++++++-----
word-break-test.lisp | 6 +++---
2 files changed, 9 insertions(+), 8 deletions(-)
Index: src/i18n/tests/norm-test.lisp
diff -u src/i18n/tests/norm-test.lisp:1.2 src/i18n/tests/norm-test.lisp:1.3
--- src/i18n/tests/norm-test.lisp:1.2 Tue Sep 15 11:53:28 2009
+++ src/i18n/tests/norm-test.lisp Fri Sep 3 21:15:49 2010
@@ -4,7 +4,7 @@
(in-package "CL-USER")
(defvar *normalization-test* "target:i18n/tests/NormalizationTest.txt")
-(defun parse-line (line)
+(defun parse-norm-line (line)
(declare (string line))
(cond ((or (char= (aref line 0) #\@)
(char= (aref line 0) #\#))
@@ -46,7 +46,7 @@
(failures 0))
(loop for line = (read-line testfile nil nil) while line do
(multiple-value-bind (c1 c2 c3 c4 c5)
- (parse-line line)
+ (parse-norm-line line)
(when c1
(incf total)
(let ((test1 (lisp::string-to-nfd c1))
@@ -78,8 +78,9 @@
(let ((total 0)
(failures 0))
(loop for line = (read-line testfile nil nil) while line do
+ ;;(format t "line = ~S~%" line)
(multiple-value-bind (c1 c2 c3 c4 c5)
- (parse-line line)
+ (parse-norm-line line)
(when c1
(incf total)
(let ((test1 (lisp::string-to-nfkd c1))
@@ -111,7 +112,7 @@
(failures 0))
(loop for line = (read-line testfile nil nil) while line do
(multiple-value-bind (c1 c2 c3 c4 c5)
- (parse-line line)
+ (parse-norm-line line)
(when c1
(incf total)
(let ((test1 (lisp::string-to-nfc c1))
@@ -144,7 +145,7 @@
(failures 0))
(loop for line = (read-line testfile nil nil) while line do
(multiple-value-bind (c1 c2 c3 c4 c5)
- (parse-line line)
+ (parse-norm-line line)
(when c1
(incf total)
(let ((test1 (lisp::string-to-nfkc c1))
Index: src/i18n/tests/word-break-test.lisp
diff -u src/i18n/tests/word-break-test.lisp:1.2 src/i18n/tests/word-break-test.lisp:1.3
--- src/i18n/tests/word-break-test.lisp:1.2 Tue Sep 15 11:59:45 2009
+++ src/i18n/tests/word-break-test.lisp Fri Sep 3 21:15:49 2010
@@ -5,7 +5,7 @@
(defvar *word-break-test* "target:i18n/tests/WordBreakTest.txt")
-(defun parse-line (line)
+(defun parse-word-break-line (line)
(let* ((eos (or (position #\# line)
(length line))))
;; See WordBreakTest.txt for the format of the file. Basically
@@ -63,13 +63,13 @@
(let ((count 0)
(failed 0))
(format t "Run WordBreakTest~%")
- (with-open-file (s file :direction :input :external-format :utf8)
+ (with-open-file (s file :direction :input :external-format :utf)
(loop for line = (read-line s nil nil)
while line
do
(progn
(multiple-value-bind (s b)
- (parse-line line)
+ (parse-word-break-line line)
(when s
(incf count)
(incf failed (if (do-test s b) 0 1)))))))
More information about the cmucl-commit
mailing list