Fix typed/rackunit contract exception when using run-tests (#583)

* Add a test that suites and run-tests work in typed/rackunit

* Fix Seed type

The "seed" parameter of fold-test-results is passed to each test suite but, near as I can tell, never actually interacted with by the suite.
This commit is contained in:
Jack Firth 2017-07-14 05:58:11 -07:00 committed by Sam Tobin-Hochstadt
parent afa0530b3a
commit 6369753c28
2 changed files with 11 additions and 1 deletions

View File

@ -134,7 +134,7 @@
(require/opaque-type TestCase test-case? rackunit)
(provide TestCase test-case?)
(define-type Seed (U #f (Object)))
(define-type Seed Any)
(define-type test-suite-handler-down
(rackunit-test-suite (Option String) (Thunk Any) (Thunk Any) Seed -> Seed))

View File

@ -0,0 +1,10 @@
#lang typed/racket
(require typed/rackunit
typed/rackunit/text-ui)
(define passing-suite
(test-suite "Example Typed Rackunit test suite"
(check-equal? 1 1)))
(check-equal? (run-tests passing-suite 'quiet) 0)