fixing issues #13

This commit is contained in:
Spencer Florence 2015-01-07 11:04:36 -05:00
parent b80d0234e5
commit 054de64fa2
2 changed files with 7 additions and 5 deletions

View File

@ -19,7 +19,6 @@
;; Test files and build coverage map
;; returns true if all tests passed
(define (test-files! . paths)
(clear-coverage!)
(for ([path paths])
(define p
(if (absolute-path? path)
@ -88,6 +87,9 @@
(namespace-require `(file ,(path->string strace)))
(namespace-require 'rackunit)))
;; A little hack to setup coverage for the first time
(clear-coverage!)
;; -> [Hashof PathString (Listof (List Boolean srcloc))]
;; returns a hash of file to a list, where the first of the list is if
;; that srcloc was covered or not

View File

@ -11,13 +11,13 @@ functions of test coverage.
@defproc[(test-files! (files path-string?) ...) any/c]{
Clears all coverage information, then tests all given @racket[files]
and stores the coverage information. Returns false if tests
failed. Test coverage information is still collected when test fail.}
Tests all given @racket[files] and stores the coverage information. Returns
false if tests failed. Test coverage information is still collected when test
fail. Test coverage info is added to existing coverage info.}
@defproc[(clear-coverage!) any]{Clears all coverage information.}
@defproc[(get-coverage-information) coverage/c]{Gets coverage information.}
@defproc[(get-coverage-information) coverage/c]{Gets the current coverage information.}
@defproc[(make-covered? (coverage file-coverage/c) (path path-string?))
(->* (exact-positive-integer?)
(#:byte? boolean?)