File tree 1 file changed +5
-2
lines changed
1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change 23
23
(define (filter/rx rx v*)
24
24
(filter (λ (v) (regexp-match? rx v)) v*))
25
25
26
+ (define (<=1 n)
27
+ (<= 1 n))
28
+
26
29
(for ((d (in-glob "*/ " )))
27
30
(cond
28
31
[(compiled-dir? d)
39
42
(path->string (file-name-from-path ps))))
40
43
(define scrbl*
41
44
(let ([f* (filter/rx #rx"\\.scrbl$ " file*)])
42
- (check-equal? (length f*) 1 (format "directory '~a' must contains one Scribble file " d))
45
+ (check-pred <=1 (length f*) (format "directory '~a' must contain at least one Scribble file " d))
43
46
f*))
44
47
(define test*
45
48
(let ([f* (filter/rx #rx"-test\\.rkt$ " file*)])
46
- (check-equal? (length f*) 1 (format "directory '~a' must contains one '-test.rkt' file " d))
49
+ (check-pred <=1 (length f*) (format "directory '~a' must contain at least one '-test.rkt' file " d))
47
50
f*))
48
51
(define scrbl-name (cadr (regexp-match #rx"^([^.]*)\\.scrbl$ " (car scrbl*))))
49
52
(define test-name (cadr (regexp-match #rx"^([^.]*)-test\\.rkt$ " (car test*))))
You can’t perform that action at this time.
0 commit comments