pathnames.lsp 520 Bytes
Newer Older
1 2 3 4 5
;-*- Mode:     Lisp -*-
;;;; Author:   Paul Dietz
;;;; Created:  Sat Nov 29 04:21:53 2003
;;;; Contains: Various tests on pathnames

6

7 8 9 10 11 12

(deftest pathnames-print-and-read-properly
  (with-standard-io-syntax
   (loop
    for p1 in *pathnames*
    for s = (handler-case (write-to-string p1 :readably t)
sds's avatar
sds committed
13
                          (print-not-readable () :unreadable-error))
14 15 16 17 18 19
    unless (eql s :unreadable-error)
    append
    (let ((p2 (read-from-string s)))
     (unless (equal p1 p2)
       (list (list p1 s p2))))))
  nil)