8773: I should have run the tests
svn: r6741
This commit is contained in:
parent
c79499e8b6
commit
e9a4d3aeb2
|
@ -1,5 +1,6 @@
|
||||||
;; test errors by hand in GUI
|
;; test errors by hand in GUI
|
||||||
(load "tester.ss")
|
(load "tester.ss")
|
||||||
|
(require (lib "convert.ss" "htdp"))
|
||||||
|
|
||||||
;; f2c : num -> num
|
;; f2c : num -> num
|
||||||
;; to convert a Fahrenheit temperature into a Celsius temperature
|
;; to convert a Fahrenheit temperature into a Celsius temperature
|
||||||
|
|
|
@ -1,8 +1,11 @@
|
||||||
|
;; The first three lines of this file were inserted by DrScheme. They record metadata
|
||||||
|
;; about the language level of this file in a form that our tools can easily process.
|
||||||
|
#reader(lib "htdp-intermediate-lambda-reader.ss" "lang")((modname dir) (read-case-sensitive #t) (teachpacks ((lib "dir.ss" "teachpack" "htdp"))) (htdp-settings #8(#t constructor repeating-decimal #f #t none #f ((lib "dir.ss" "teachpack" "htdp")))))
|
||||||
;; TeachPack: dir.ss
|
;; TeachPack: dir.ss
|
||||||
;; Language: Intermediate with Lambda
|
;; Language: Intermediate with Lambda
|
||||||
|
|
||||||
(define current (create-dir "."))
|
(define current (create-dir "."))
|
||||||
(define teachps (create-dir (string-append "/Users/matthias/plt/" "/teachpack/htdp")))
|
(define teachps (create-dir (string-append "/Users/matthias/plt/" "collects/teachpack/htdp")))
|
||||||
|
|
||||||
(define current-files (map file-name (dir-files current)))
|
(define current-files (map file-name (dir-files current)))
|
||||||
(define teachps-files (map file-name (dir-files teachps)))
|
(define teachps-files (map file-name (dir-files teachps)))
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
;; The first three lines of this file were inserted by DrScheme. They record metadata
|
||||||
|
;; about the language level of this file in a form that our tools can easily process.
|
||||||
|
#reader(lib "htdp-intermediate-lambda-reader.ss" "lang")((modname draw) (read-case-sensitive #t) (teachpacks ((lib "draw.ss" "teachpack" "htdp"))) (htdp-settings #8(#t constructor repeating-decimal #f #t none #f ((lib "draw.ss" "teachpack" "htdp")))))
|
||||||
;; This tests a good portion but needs some more
|
;; This tests a good portion but needs some more
|
||||||
;; This needs some tests for error behavior of functions ...
|
;; This needs some tests for error behavior of functions ...
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
;; The first three lines of this file were inserted by DrScheme. They record metadata
|
;; The first three lines of this file were inserted by DrScheme. They record metadata
|
||||||
;; about the language level of this file in a form that our tools can easily process.
|
;; about the language level of this file in a form that our tools can easily process.
|
||||||
#reader(lib "htdp-intermediate-lambda-reader.ss" "lang")((modname world) (read-case-sensitive #t) (htdp-settings #7(#t constructor repeating-decimal #f #t none #f)))
|
#reader(lib "htdp-intermediate-lambda-reader.ss" "lang")((modname world) (read-case-sensitive #t) (teachpacks ((lib "world.ss" "teachpack" "htdp"))) (htdp-settings #8(#t constructor repeating-decimal #f #t none #f ((lib "world.ss" "teachpack" "htdp")))))
|
||||||
;; testing world
|
;; testing world
|
||||||
|
|
||||||
;; World = Nat
|
;; World = Nat
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
#cs(module elevator mzscheme
|
(module elevator mzscheme
|
||||||
(require (lib "big-draw.ss" "htdp")
|
(require (lib "big-draw.ss" "htdp")
|
||||||
(lib "error.ss" "htdp")
|
(lib "error.ss" "htdp")
|
||||||
(lib "posn.ss" "lang")
|
(lib "posn.ss" "lang")
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
#cs(module graphing mzscheme
|
(module graphing mzscheme
|
||||||
(require (lib "error.ss" "htdp")
|
(require (lib "error.ss" "htdp")
|
||||||
(lib "unit.ss")
|
(lib "unit.ss")
|
||||||
(lib "draw-sig.ss" "htdp")
|
(lib "draw-sig.ss" "htdp")
|
||||||
|
|
|
@ -282,12 +282,18 @@ Matthew
|
||||||
(for-each (lambda (cand)
|
(for-each (lambda (cand)
|
||||||
(check-image 'run-movie cand "first" "list of images"))
|
(check-image 'run-movie cand "first" "list of images"))
|
||||||
movie)
|
movie)
|
||||||
(let run-movie ([movie movie])
|
(let* ([fst (car movie)]
|
||||||
(cond [(null? movie) #t]
|
[wdt (image-width fst)]
|
||||||
[(pair? movie)
|
[hgt (image-height fst)]
|
||||||
(update-frame (car movie))
|
[nxt (lambda (w) (if (null? w) (end-of-time "") (cdr w)))])
|
||||||
(sleep/yield .05)
|
(big-bang wdt hgt (/ 1 27) movie)
|
||||||
(run-movie (cdr movie))])))
|
(let run-movie ([movie movie])
|
||||||
|
(cond
|
||||||
|
[(null? movie) #t]
|
||||||
|
[(pair? movie)
|
||||||
|
(update-frame (car movie))
|
||||||
|
(sleep/yield .05)
|
||||||
|
(run-movie (cdr movie))]))))
|
||||||
|
|
||||||
(define (run-simulation width height rate f)
|
(define (run-simulation width height rate f)
|
||||||
(check-pos 'run-simulation width "first")
|
(check-pos 'run-simulation width "first")
|
||||||
|
|
|
@ -135,7 +135,8 @@ students to simulate a small world of animated drawings and games:
|
||||||
|
|
||||||
<li><code>{(idx run-movie)} : (Listof Image) -> true </code><br>
|
<li><code>{(idx run-movie)} : (Listof Image) -> true </code><br>
|
||||||
<code>(run-movie loi)</code>
|
<code>(run-movie loi)</code>
|
||||||
shows the list of images in loi, time-delayed
|
shows the list of images in loi in a time-delayed manner;
|
||||||
|
assume: all images are of the same size
|
||||||
</menu></p>
|
</menu></p>
|
||||||
|
|
||||||
<hr />
|
<hr />
|
||||||
|
|
Loading…
Reference in New Issue
Block a user