X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=contrib%2Fsb-cover%2Ftests.lisp;h=ea54b7537680fe9e354673714441afd61ef9e5aa;hb=72a34c4188d01b13b47a0862c0330a904fd636f9;hp=7903b80db47922d65967baf2efa8f06f9f7d9355;hpb=77a7ce93218e71f21268661611530a129002a8e6;p=sbcl.git diff --git a/contrib/sb-cover/tests.lisp b/contrib/sb-cover/tests.lisp index 7903b80..ea54b75 100644 --- a/contrib/sb-cover/tests.lisp +++ b/contrib/sb-cover/tests.lisp @@ -28,11 +28,18 @@ (load (compile-file (merge-pathnames #p"test-data-1.lisp" *path*))) (report-expect-failure) -;;; Instrument the file, try again +;;; Instrument the file, try again -- first with a non-directory pathname (proclaim '(optimize sb-cover:store-coverage-data)) (load (compile-file (merge-pathnames #p"test-data-1.lisp" *path*))) +(catch 'ok + (handler-case + (sb-cover:report #p"/tmp/foo") + (error () + (throw 'ok nil))) + (error "REPORT with a non-pathname directory did not signal an error.")) + (report) (assert (probe-file (make-pathname :name "cover-index" :type "html" @@ -98,3 +105,7 @@ (load (compile-file (merge-pathnames #p"test-data-3.lisp" *path*))) (test-2) +;; Clean up after the tests + +(map nil #'delete-file + (directory (merge-pathnames #p"*.html" *output-directory*)))