fix some tests that need to find `racket'

This commit is contained in:
Matthew Flatt 2013-08-02 12:08:26 -06:00
parent 2a271a55fc
commit 4492cf2555
5 changed files with 18 additions and 14 deletions

View File

@ -1,6 +1,7 @@
#lang racket
(require tests/eli-tester
racket/runtime-path)
racket/runtime-path
compiler/find-exe)
(define (capture-output command . args)
(define o (open-output-string))
@ -14,7 +15,7 @@
(define (test-on-program filename)
; run modular program, capture output
(define-values (modular-output modular-error)
(capture-output (find-executable-path "racket") filename))
(capture-output (find-exe) filename))
(define demod-filename
(let-values ([(base filename dir?) (split-path filename)])
@ -25,11 +26,11 @@
; demodularize
(parameterize ([current-input-port (open-input-string "")])
(system* (find-executable-path "raco") "demod" "-o" demod-filename filename))
(system* (find-exe) "-l-" "raco" "demod" "-o" demod-filename filename))
; run whole program
(define-values (whole-output whole-error)
(capture-output (find-executable-path "racket") demod-filename))
(capture-output (find-exe) demod-filename))
; compare output
(test

View File

@ -7,6 +7,7 @@ exec racket -t "$0" -- -s -t 60 -v -R $*
(require setup/dirs
racket/runtime-path
racket/future
compiler/find-exe
"zo-test-util.rkt")
(define ((make-recorder! ht) file phase)
@ -63,7 +64,7 @@ exec racket -t "$0" -- -s -t 60 -v -R $*
(! p-str)]))
(define-runtime-path zo-test-worker-path "zo-test-worker.rkt")
(define racket-path (path->string (find-executable-path "racket")))
(define racket-path (path->string (find-exe)))
(define p
(command-line #:program "zo-test"

View File

@ -18,7 +18,8 @@ exec racket -qu "$0" ${1+"$@"}
dynext/file
syntax/toplevel
scheme/runtime-path
racket/port)
racket/port
compiler/find-exe)
;; Implementaton-specific control functions ------------------------------
@ -363,7 +364,7 @@ exec racket -qu "$0" ${1+"$@"}
void
mk-racket
(lambda (bm)
(system (format "racket -u ~a.rkt" bm)))
(system* (find-exe) "-u" (format "~a.rkt" bm)))
extract-racket-times
clean-up-zo
racket-skip-progs)

View File

@ -18,7 +18,8 @@ exec racket -qu "$0" ${1+"$@"}
mzlib/file
dynext/file
syntax/toplevel
scheme/runtime-path)
scheme/runtime-path
compiler/find-exe)
;; Implementaton-specific control functions ------------------------------
@ -80,7 +81,7 @@ exec racket -qu "$0" ${1+"$@"}
void
mk-racket
(lambda (bm)
(system (format "racket run.rkt ~a racket" bm)))
(system* (find-exe) "run.rkt" bm "racket"))
extract-racket-times
clean-up-zo
'())
@ -88,7 +89,7 @@ exec racket -qu "$0" ${1+"$@"}
void
mk-typed-racket-non-optimizing
(lambda (bm)
(system (format "racket run.rkt ~a typed-racket-non-optimizing" bm)))
(system* (find-exe) "run.rkt" bm "typed-racket-non-optimizing"))
extract-racket-times
clean-up-typed
'())
@ -96,7 +97,7 @@ exec racket -qu "$0" ${1+"$@"}
void
mk-typed-racket
(lambda (bm)
(system (format "racket run.rkt ~a typed-racket" bm)))
(system* (find-exe) "run.rkt" bm "typed-racket"))
extract-racket-times
clean-up-typed
'())

View File

@ -1,10 +1,10 @@
#lang racket/base
(require tests/stress
racket/system
racket/runtime-path)
racket/runtime-path
compiler/find-exe)
(define racket-pth
(find-executable-path "racket"))
(define racket-pth (find-exe))
(define-runtime-path ttt:raw "ttt-bench-raw.rkt")
(define-runtime-path ttt:ctc "ttt-bench-ctc.rkt")