r4497: Auto commit for Debian build
authorKevin M. Rosenberg <kevin@rosenberg.net>
Tue, 15 Apr 2003 16:21:43 +0000 (16:21 +0000)
committerKevin M. Rosenberg <kevin@rosenberg.net>
Tue, 15 Apr 2003 16:21:43 +0000 (16:21 +0000)
base64-tests.lisp
base64.asd
debian/control

index 7158bb245af72c4722a164c382e5bcaddc7eb0ee..0e5fb1e0504b71bd876d321f09c8fa09a8dcbf9a 100644 (file)
@@ -7,7 +7,7 @@
 ;;;; Programmer:    Kevin M. Rosenberg
 ;;;; Date Started:  Jan 2003
 ;;;;
 ;;;; Programmer:    Kevin M. Rosenberg
 ;;;; Date Started:  Jan 2003
 ;;;;
-;;;; $Id: base64-tests.lisp,v 1.9 2003/04/15 16:15:21 kevin Exp $
+;;;; $Id: base64-tests.lisp,v 1.10 2003/04/15 16:21:43 kevin Exp $
 ;;;; *************************************************************************
 
 (in-package :cl-user)
 ;;;; *************************************************************************
 
 (in-package :cl-user)
 
 (defun test-base64 ()
   (setq *break-on-test-failures* t) 
 
 (defun test-base64 ()
   (setq *break-on-test-failures* t) 
-  (with-tests (:name "cl-base64 tests")
-    (do* ((length 0 (+ 3 length))
-         (string (make-string length) (make-string length))
-         (usb8 (make-usb8-array length) (make-usb8-array length))
-         (integer (random (expt 10 length)) (random (expt 10 length))))
-        ((>= length 300))
+  (do* ((length 0 (+ 3 length))
+       (string (make-string length) (make-string length))
+       (usb8 (make-usb8-array length) (make-usb8-array length))
+       (integer (random (expt 10 length)) (random (expt 10 length))))
+       ((>= length 300))
     (dotimes (i length)
       (declare (fixnum i))
       (let ((code (random 256)))
        (setf (schar string i) (code-char code))
        (setf (aref usb8 i) code)))
     (dotimes (i length)
       (declare (fixnum i))
       (let ((code (random 256)))
        (setf (schar string i) (code-char code))
        (setf (aref usb8 i) code)))
-
-      (do* ((columns 0 (+ columns 4)))
-          ((> columns length))
+    
+    (do* ((columns 0 (+ columns 4)))
+        ((> columns length))
       ;; Test against cl-base64 routines
       ;; Test against cl-base64 routines
-       (test integer (base64-string-to-integer
-                                (integer-to-base64-string integer :columns columns))
-             :test #'eql)
-       (test string (base64-string-to-string
-                               (string-to-base64-string string :columns columns))
-                     :test #'string=)
+      (assert (= integer (base64-string-to-integer
+                         (integer-to-base64-string integer :columns columns))))
+      (assert (string= (base64-string-to-string
+                       (string-to-base64-string string :columns columns))))
       
       ;; Test against AllegroCL built-in routines
       #+allegro
       (progn
       
       ;; Test against AllegroCL built-in routines
       #+allegro
       (progn
-       (test integer (excl:base64-string-to-integer
-                      (integer-to-base64-string integer :columns columns)))
-       (test integer (base64-string-to-integer
-                      (excl:integer-to-base64-string integer)))
-       (test (string-to-base64-string string :columns columns)
-             (excl:usb8-array-to-base64-string usb8
-                                               (if (zerop columns)
-                                                   nil
-                                                   columns))
-             :test #'string=)
-       (test string (base64-string-to-string
-                     (excl:usb8-array-to-base64-string
-                      usb8
-                      (if (zerop columns)
-                          nil
-                          columns)))
-             :test #'string=)))))
+       (assert (= integer (excl:base64-string-to-integer
+                           (integer-to-base64-string integer :columns columns))))
+       (assert (= integer (base64-string-to-integer
+                           (excl:integer-to-base64-string integer))))
+       (assert (string= (string-to-base64-string string :columns columns)
+                        (excl:usb8-array-to-base64-string usb8
+                                                          (if (zerop columns)
+                                                              nil
+                                                              columns))))
+       (assert (string= string (base64-string-to-string
+                                (excl:usb8-array-to-base64-string
+                                 usb8
+                                 (if (zerop columns)
+                                     nil
+                                     columns))))))))
+  (format t "~&All tests passed~%")
   t)
 
 
   t)
 
 
index b47d46ed1a3353c08af3f8afe3b6c898cfa22075..f4b32d811727d35176c03e0a8c0d4921f56b20c5 100644 (file)
@@ -7,7 +7,7 @@
 ;;;; Programmer:    Kevin M. Rosenberg
 ;;;; Date Started:  Dec 2002
 ;;;;
 ;;;; Programmer:    Kevin M. Rosenberg
 ;;;; Date Started:  Dec 2002
 ;;;;
-;;;; $Id: base64.asd,v 1.18 2003/04/15 16:12:01 kevin Exp $
+;;;; $Id: base64.asd,v 1.19 2003/04/15 16:21:43 kevin Exp $
 ;;;; *************************************************************************
 
 (in-package :asdf)
 ;;;; *************************************************************************
 
 (in-package :asdf)
@@ -29,7 +29,7 @@
            (pushnew :base64 cl:*features*))
 
   ;; depends-on only needed for test-op
            (pushnew :base64 cl:*features*))
 
   ;; depends-on only needed for test-op
-  :depends-on (:kmrcl :tester
+  :depends-on (:kmrcl) 
   
   :components
   ((:file "package")
   
   :components
   ((:file "package")
index 36ceff646cdac89a4a93793f9699280a43546092..3ecfd1c538c0996176332db627421eeb20d7c1f8 100644 (file)
@@ -7,7 +7,7 @@ Standards-Version: 3.5.9.0
 
 Package: cl-base64
 Architecture: all
 
 Package: cl-base64
 Architecture: all
-Depends: ${shlibs:Depends}, common-lisp-controller (>= 3.47), cl-kmrcl, cl-tester
+Depends: ${shlibs:Depends}, common-lisp-controller (>= 3.47), cl-kmrcl
 Description: Common Lisp package to encode and decode base64 with URI support
  This package provides highly optimized base64 encoding and decoding.
  Besides conversion to and from strings, integer conversions are supported.
 Description: Common Lisp package to encode and decode base64 with URI support
  This package provides highly optimized base64 encoding and decoding.
  Besides conversion to and from strings, integer conversions are supported.