marcoabreu commented on a change in pull request #12391: [MXNET-851] Test
coverage metrics for R-package
URL: https://github.com/apache/incubator-mxnet/pull/12391#discussion_r216735411
##########
File path: Makefile
##########
@@ -579,16 +578,15 @@ rpkg:
echo "import(methods)" >> R-package/NAMESPACE
R CMD INSTALL R-package
Rscript -e "require(mxnet); mxnet:::mxnet.export('R-package')"
- rm -rf R-package/NAMESPACE
Rscript -e "if (!require('roxygen2')||packageVersion('roxygen2')!=
'5.0.1'){\
devtools::install_version('roxygen2',version='5.0.1',\
repo='https://cloud.r-project.org/',quiet=TRUE)}"
Rscript -e "require(roxygen2); roxygen2::roxygenise('R-package')"
R CMD INSTALL R-package
- rm -rf R-package/src/image_recordio.h
rpkgtest:
- Rscript -e
"require(testthat);res<-test_dir('R-package/tests/testthat');if(!testthat:::all_passed(res)){stop('Test
failures', call. = FALSE)}"
+ Rscript -e
'require(testthat);res<-test_dir("R-package/tests/testthat");if(!testthat:::all_passed(res)){stop("Test
failures", call. = FALSE)}'
+ Rscript -e
'res<-covr:::package_coverage("R-package");fileConn<-file("r-package_coverage.json");writeLines(RJSONIO:::toJSON(res),
fileConn);close(fileConn)'
Review comment:
I think this functions output does not really match the format codecov
expects. Have a look at this line:
https://github.com/r-lib/covr/blob/master/R/codecov.R#L164
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services