File tree 2 files changed +5
-2
lines changed
2 files changed +5
-2
lines changed Original file line number Diff line number Diff line change 1
1
# covr (development version)
2
2
3
+ * ` report() ` now provides a more detailed error message if the ` DT ` and ` htmltools ` dependencies are not installed (#500 ).
4
+
3
5
* Added ` covr.record_tests ` option. When ` TRUE ` , this enables the recording of
4
6
the trace of the tests being executed and adds an itemization of which tests
5
7
result in the execution of each trace. For more details see
Original file line number Diff line number Diff line change @@ -21,8 +21,9 @@ report <- function(x = package_coverage(),
21
21
# Paths need to be absolute for save_html to work properly
22
22
file <- file.path(normalizePath(dirname(file ), mustWork = TRUE ), basename(file ))
23
23
24
- loadNamespace(" htmltools" )
25
- loadNamespace(" DT" )
24
+ if (! (requireNamespace(" htmltools" , quietly = TRUE ) && requireNamespace(" DT" , quietly = TRUE ))) {
25
+ stop(" The `DT` and `htmltools` packages must be installed to use `covr::report()`" , call. = FALSE )
26
+ }
26
27
27
28
data <- to_report_data(x )
28
29
You can’t perform that action at this time.
0 commit comments