Open
Description
This Typed Racket program should report that the "Should be a failure" test failed and no tests succeeded.
#lang typed/racket
(require typed/rackunit typed/rackunit/text-ui)
(run-tests
(test-suite
"Tests"
(test-equal? "Should be a failure" 0 1)))
Here's the output of running this.
--------------------
Tests > Unnamed test
. ../../Applications/Racket v8.14/share/pkgs/rackunit-typed/rackunit/main.rkt:322:27: FAILURE
name: check-equal?
location:
/Applications/Racket v8.14/share/pkgs/rackunit-typed/rackunit/main.rkt:322:27
actual: 0
expected: 1
--------------------
1 success(es) 0 failure(s) 0 error(s) 1 test(s) run
0
Notice that the test doesn't get a name and the file/line reported as containing the error is not my code, but Typed Racket's rackunit instead.
The equivalent test in normal Racket works as expected.
#lang racket
(require rackunit rackunit/text-ui)
(run-tests
(test-suite
"Tests"
(test-equal? "Should be a failure" 0 1)))
outputs
--------------------
Tests > Should be a failure
. FAILURE
name: check-equal?
location: 11-unsaved-editor:7:2
actual: 0
expected: 1
--------------------
0 success(es) 1 failure(s) 0 error(s) 1 test(s) run
1
Metadata
Metadata
Assignees
Labels
No labels