From: Siraaj Khandkar Date: Thu, 19 Nov 2020 02:53:21 +0000 (-0500) Subject: Simplify test case X-Git-Tag: 0.4.0~5 X-Git-Url: https://git.xandkar.net/?a=commitdiff_plain;h=4d9589831816d64a85e8c81ce81708ec0d5dd10f;p=tt.git Simplify test case --- diff --git a/tt.rkt b/tt.rkt index 986ade1..d37788d 100644 --- a/tt.rkt +++ b/tt.rkt @@ -88,13 +88,11 @@ results) (module+ test - (define n-workers 10) - (define given (list - (λ (x) (if (even? x) x #f)) - (range 11))) - (check-equal? - (sort (apply concurrent-filter-map (cons n-workers given)) <) - (sort (apply filter-map given ) <))) + (let* ([f (λ (x) (if (even? x) x #f))] + [xs (range 11)] + [actual (sort (concurrent-filter-map 10 f xs) <)] + [expected (sort ( filter-map f xs) <)]) + (check-equal? actual expected "concurrent-filter-map"))) (define (msg-print out-format odd msg) (printf