X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=tests%2Fside-effectful-pathnames.test.sh;h=2f974e610e348c2c7c56ebe94aaa9fafea114fa2;hb=a189a69454ef7635149319ae213b337f17c50d20;hp=29f3596b4483436c18213e657754061c3e1c5825;hpb=a8f2656f635d81ec326303f47e0612fb1f35fd91;p=sbcl.git diff --git a/tests/side-effectful-pathnames.test.sh b/tests/side-effectful-pathnames.test.sh index 29f3596..2f974e6 100644 --- a/tests/side-effectful-pathnames.test.sh +++ b/tests/side-effectful-pathnames.test.sh @@ -1,31 +1,91 @@ #!/bin/sh -# FIXME: MNA wrote the tests below to work with the new -# lp-test-file.lisp file in place. It'd be good to replace them either -# with code which uses an existing distribution file instead, or with -# code which creates a new file in $TMPDIR and uses that. Meanwhile, -# we just return success immediately instead of doing anything. -exit 104 +# This software is part of the SBCL system. See the README file for +# more information. +# +# While most of SBCL is derived from the CMU CL system, the test +# files (like this one) were written from scratch after the fork +# from CMU CL. +# +# This software is in the public domain and is provided with +# absolutely no warranty. See the COPYING and CREDITS files for +# more information. -;;; loading files w/ logical pathnames -(setf (logical-pathname-translations "TEST") - '(("**;*.*.*" - #.(concatenate 'string - (namestring (sb-int:default-directory)) - "**/*.*")) - ("**;*.*.*" - #.(concatenate 'string - (namestring (sb-int:default-directory)) - "**/*.*.*")))) -(assert (equal (namestring (translate-logical-pathname - "test:lp-test-file.lisp")) - #.(concatenate 'string - (namestring (sb-int:default-directory)) - "lp-test-file.lisp"))) -(load "TEST:LP-TEST-FILE") -(let ((compiled-file-name (namestring (compile-file "TEST:LP-TEST-FILE"))) - (should-be-file-name - #.(concatenate 'string - (namestring (sb-int:default-directory)) - "lp-test-file.x86f"))) - (assert (equal compiled-file-name should-be-file-name))) +. ./subr.sh + +use_test_subdirectory +testdir="`pwd -P`" # resolve symbolic links in the directory. + +# LOADing and COMPILEing files with logical pathnames +testfilestem="load-test" +StudlyCapsStem="Load-Test" +testfilename="$testfilestem.lisp" +cat >$testfilename <