diff --git a/collects/framework/main.ss b/collects/framework/main.ss index 887bb65e..a064b7d2 100644 --- a/collects/framework/main.ss +++ b/collects/framework/main.ss @@ -84,7 +84,12 @@ (lambda (x) (or (eq? x 'common) (eq? x 'std)))) - + + ;; reset this -- this preference is only for the test suite. + ;; it does not need to be set across starting up and shutting down + ;; the application. + (preferences:set 'framework:file-dialogs 'std) + ;; groups (preferences:set-default 'framework:exit-when-no-frames #t boolean?) diff --git a/collects/tests/framework/main.ss b/collects/tests/framework/main.ss index d1bae5d4..4021ac2b 100644 --- a/collects/tests/framework/main.ss +++ b/collects/tests/framework/main.ss @@ -105,8 +105,10 @@ (lambda () (when (and in-port out-port) - (close-output-port out-port) - (close-input-port in-port) + (with-handlers ([(lambda (x) #t) (lambda (x) (void))]) + (close-output-port out-port)) + (with-handlers ([(lambda (x) #t) (lambda (x) (void))]) + (close-input-port in-port)) (set! in-port #f) (set! in-port #f)))) @@ -152,8 +154,10 @@ (newline)))]) (unless (and in-port out-port - (or (not (char-ready? in-port)) - (not (eof-object? (peek-char in-port))))) + (with-handlers ([tcp-error? + (lambda (x) #f)]) + (or (not (char-ready? in-port)) + (not (eof-object? (peek-char in-port)))))) (restart-mred)) (printf " ~a // ~a: sending to mred:~n" section-name test-name) (show-text sexp) @@ -194,7 +198,6 @@ (and (list? answer) (= 2 (length answer)))) (error 'send-sexp-to-mred "unpected result from mred: ~s~n" answer)) - (if (eof-object? answer) (raise (make-eof-result)) (case (car answer) diff --git a/collects/tests/framework/prefs.ss b/collects/tests/framework/prefs.ss index cb780807..df1d1593 100644 --- a/collects/tests/framework/prefs.ss +++ b/collects/tests/framework/prefs.ss @@ -32,6 +32,7 @@ (check-eq? 'new-pref) `(begin (preferences:set ',pref-sym 'new-pref) (preferences:get ',pref-sym))) + (with-handlers ([eof-result? (lambda (x) (void))]) (send-sexp-to-mred '(begin (preferences:set 'framework:verify-exit #f) (exit:exit))))