Changeset 10047


Ignore:
Timestamp:
09/27/05 18:27:57 (16 years ago)
Author:
piso
Message:

Work in progress.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/j/src/org/armedbear/lisp/tests/pathname-tests.lisp

    r10044 r10047  
    22;;;
    33;;; Copyright (C) 2005 Peter Graves
    4 ;;; $Id: pathname-tests.lisp,v 1.30 2005-09-26 19:32:53 piso Exp $
     4;;; $Id: pathname-tests.lisp,v 1.31 2005-09-27 18:27:57 piso Exp $
    55;;;
    66;;; This program is free software; you can redistribute it and/or
     
    4242
    4343(unless (find-package '#:test)
    44   (defpackage #:test (:use #:cl #:regression-test
    45                            #+abcl #:extensions)))
     44  (defpackage #:test (:use #:cl #:regression-test)))
    4645
    4746(in-package #:test)
     
    156155
    157156;; It's suboptimal if all pathnames return the same SXHASH, but that happens
    158 ;; with CMUCL and SBCL.
     157;; with SBCL.
    159158(deftest sxhash.3
    160159  (= (sxhash #p"/usr/local/bin/sbcl") (sxhash #p"") (sxhash #p"foo.bar"))
    161   #+(or cmu sbcl) t
    162   #-(or cmu sbcl) nil)
     160  #+sbcl t
     161  #-sbcl nil)
    163162
    164163(deftest physical.1
     
    416415           "#P\"EFFLUVIA:BAR.BAZ.42\"")
    417416  t)
     417
    418418#+allegro
    419419;; Allegro returns NIL for the device and directory and drops the version
     
    422422  (check-logical-pathname #p"effluvia:bar.baz.42" "effluvia" nil "bar" "baz" nil)
    423423  t)
     424
    424425#+allegro
    425426(deftest logical.5
    426427  (string= (write-to-string #p"effluvia:bar.baz" :escape t)
    427            "#p\"effluvia:bar.baz\"")
     428           #+allegro-v6.2 "#p\"effluvia:bar.baz\""
     429           #+allegro-v7.0 "#P\"effluvia:bar.baz\"")
    428430  t)
    429431
     
    431433  (typep (parse-namestring "**;*.*.*" "effluvia") 'logical-pathname)
    432434  t)
     435
    433436(deftest logical.7
    434437  (check-namestring (parse-namestring "**;*.*.*" "effluvia")
     
    584587(deftest translate-pathname.3
    585588  #-abcl
    586   (string= (pathname-name (translate-pathname "foobar" "*" "foo*")) "foofoobar")
     589  (string= (pathname-name (translate-pathname "foobar" "*" "foo*"))
     590           #-allegro-v7.0 "foofoobar"
     591           #+allegro-v7.0 "foo*")
    587592  #+abcl
    588593  (signals-error (translate-pathname "foobar" "*" "foo*") 'error)
     
    592597(deftest translate-pathname.4
    593598  #-abcl
    594   (equal (translate-pathname "foobar" "foo*" "*baz") #p"barbaz")
     599  (equal (translate-pathname "foobar" "foo*" "*baz")
     600         #-allegro-v7.0 #p"barbaz"
     601         #+allegro-v7.0 #p"*baz")
    595602  #+abcl
    596603  (signals-error (translate-pathname "foobar" "foo*" "*baz") 'error)
     604  t)
     605
     606;; ABCL doesn't implement this translation.
     607(deftest translate-pathname.5a
     608  #-abcl
     609  (equal (translate-pathname "foobar" "foo*" "")
     610         #+(or allegro clisp) #p"bar"
     611         #+sbcl #p"foobar")
     612  #+abcl
     613  (signals-error (translate-pathname "foobar" "foo*" "") 'error)
    597614  t)
    598615
Note: See TracChangeset for help on using the changeset viewer.