Don't try to print highly nested forms for type errors.
[sbcl.git] / tests / test-funs.lisp
blob04e0eed0364dec55718144bef82608174f798af0
1 (defvar *test-evaluator-mode* :compile)
3 (defun clear-test-status ()
4 (with-open-file (stream "test-status.lisp-expr"
5 :direction :output
6 :if-exists :supersede)
7 (write-line "NIL" stream)))
9 (defun load-test (file)
10 (load file :external-format :utf-8))
12 (defun cload-test (file)
13 (let ((compile-name (compile-file-pathname file)))
14 (unwind-protect
15 (progn
16 (compile-file file :print nil)
17 (load compile-name))
18 (ignore-errors
19 (delete-file compile-name)))))
21 (defun sh-test (file)
22 (clear-test-status)
23 (progn
24 (sb-posix:setenv "TEST_SBCL_EVALUATOR_MODE"
25 (string-downcase *test-evaluator-mode*)
27 (let ((process (sb-ext:run-program "/bin/sh"
28 (list (native-namestring file))
29 :output *error-output*)))
30 (let ((*failures* nil))
31 (test-util:report-test-status))
32 (sb-ext:exit :code (process-exit-code process)))))