Skip to content

Commit 4d76110

Browse files
committed
improve the bitmap test a little bit
- avoid using make-screen-bitmap so the bitmaps are more consistent - put the correct and incorrect bitmaps closer together
1 parent 727ae59 commit 4d76110

35 files changed

+5
-7
lines changed
Loading
Loading
Loading
-236 Bytes
Loading
Loading
Loading
-3.53 KB
Loading
-1.16 KB
Loading
-999 Bytes
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
-363 Bytes
Loading
Loading
Loading
Loading
-7.83 KB
Loading
Loading
Loading
Loading
Loading
-734 Bytes
Loading
-8 Bytes
Loading
-2.15 KB
Loading
-76 Bytes
Loading
Loading
-2.04 KB
Loading

redex-test/redex/tests/private/bitmap-test-util.rkt

+5-7
Original file line numberDiff line numberDiff line change
@@ -47,11 +47,9 @@
4747
(send bdc draw-text "does not exist" 0 0)
4848
(send bdc set-bitmap #f)
4949
bm))]
50-
[new-bitmap ((if (eq? (system-type) 'unix)
51-
make-bitmap
52-
make-screen-bitmap)
53-
(ceiling (inexact->exact (pict-width pict)))
54-
(ceiling (inexact->exact (pict-height pict))))]
50+
[new-bitmap (make-bitmap
51+
(ceiling (inexact->exact (pict-width pict)))
52+
(ceiling (inexact->exact (pict-height pict))))]
5553
[bdc (make-object bitmap-dc% new-bitmap)])
5654
(send bdc clear)
5755
(draw-pict pict bdc 0 0)
@@ -207,8 +205,8 @@
207205
(define trsp (new vertical-panel% [parent (get-test-result-single-panel)]))
208206
(define msg (new message% [label (format "line ~a" line-number)] [parent trsp]))
209207
(define hp (new horizontal-panel% [parent trsp]))
210-
(define vp1 (new vertical-panel% [parent hp]))
211-
(define vp2 (new vertical-panel% [parent hp]))
208+
(define vp1 (new vertical-panel% [parent hp] [alignment '(right top)]))
209+
(define vp2 (new vertical-panel% [parent hp] [alignment '(left top)]))
212210
(define computing/differences-msg
213211
(new message% [label (format "~a pixels different" number-of-different-pixels)] [parent trsp]))
214212
(define chk (new check-box%

0 commit comments

Comments
 (0)