jjwiseman
2018-4-17 19:56:48

is there a way i can get better stack traces while using raco test? example output: raco test -t aici/deliberator/kb.rkt raco test: (submod "aici/deliberator/kb.rkt" test) -------------------- < memory function ERROR application: not a procedure; expected a procedure that can be applied to arguments given: '< arguments...: 5 6 --------------------


jjwiseman
2018-4-17 19:57:54

as far as locating the error, all it gives me is the test case name. i know the error is being raised inside the function i’m testing, but it’d be nice to know exactly where.


greg
2018-4-18 03:29:15

@jjwiseman For racket I’d suggest trying -l errortrace as described here: https://docs.racket-lang.org/errortrace/quick-instructions.html?q=errortrace But I’m not sure how to compose that with raco test and its -t table output. As a quick hack, you could temporarily change the source file — add (require errortrace) inside the (module+ test).