Running ‘doRUnit.R’ [9s/13s]
Running the tests in ‘tests/doRUnit.R’ failed.
Complete output:
  > ## unit tests will not be done if RUnit is not available
  > if(require("RUnit", quietly=TRUE)) {    
  +  
  +   ## --- Setup ---
  +  
  +   pkg <- "krm" # <-- Change to package name!
  +   if(Sys.getenv("RCMDCHECK") == "FALSE") {
  +     ## Path to unit tests for standalone running under Makefile (not R CMD check)
  +     ## PKG/tests/../inst/unitTests
  +     path <- file.path(getwd(), "unitTests")
  +   } else {
  +     ## Path to unit tests for R CMD check
  +     ## PKG.Rcheck/tests/../PKG/unitTests
  +     path <- system.file("unitTests", package=pkg)
  +   }
  +   cat("\nRunning unit tests\n")
  +   print(list(pkg=pkg, getwd=getwd(), pathToUnitTests=path))
  +  
  +   library(package=pkg, character.only=TRUE)
  +  
  +   ## If desired, load the name space to allow testing of private functions
  +   ## if (is.element(pkg, loadedNamespaces()))
  +   ##     attach(loadNamespace(pkg), name=paste("namespace", pkg, sep=":"), pos=3)
  +   ##
  +   ## or simply call PKG:::myPrivateFunction() in tests
  +  
  +   ## --- Testing ---
  +  
  +   ## Define tests
  +   testSuite <- defineTestSuite(name=paste(pkg, "unit testing"),
  +                                           dirs=path)
  +   ## Run
  +   tests <- runTestSuite(testSuite)
  +  
  +   ## Default report name
  +   pathReport <- file.path(path, "report")
  +  
  +   ## Report to stdout and text files
  +   cat("------------------- UNIT TEST SUMMARY ---------------------\n\n")
  +   printTextProtocol(tests, showDetails=FALSE)
  +   printTextProtocol(tests, showDetails=FALSE,
  +                     fileName=paste(pathReport, "Summary.txt", sep=""))
  +   printTextProtocol(tests, showDetails=TRUE,
  +                     fileName=paste(pathReport, ".txt", sep=""))
  +  
  +   ## Report to HTML file
  +   printHTMLProtocol(tests, fileName=paste(pathReport, ".html", sep=""))
  +  
  +   ## Return stop() to cause R CMD check stop in case of
  +   ##  - failures i.e. FALSE to unit tests or
  +   ##  - errors i.e. R errors
  +   tmp <- getErrors(tests)
  +   if(tmp$nFail > 0 | tmp$nErr > 0) {
  +     stop(paste("\n\nunit testing failed (#test failures: ", tmp$nFail,
  +                ", #R errors: ",  tmp$nErr, ")\n\n", sep=""))
  +   }
  + } else {
  +   warning("cannot run unit tests -- package RUnit is not available")
  + }
  
  Running unit tests
  $pkg
  [1] "krm"
  
  $getwd
  [1] "/home/hornik/tmp/R.check/r-devel-gcc/Work/PKGS/krm.Rcheck/tests"
  
  $pathToUnitTests
  [1] "/tmp/Rtmp0KZuPc/RLIBS_6e4e56bb5f04/krm/unitTests"
  
  Loading required package: kyotil
  
  
  Executing test function test.getSeqKernel  ...  done successfully.
  
  
  
  Executing test function test.krm.mos.test  ... Loading required namespace: MASS
  formula.kern: ~z.1 + z.2 + z.3 + z.4 + z.5
  <environment: 0x56241675e360>
  summary(c(l2dist)) = 0.211 5.4 8.88 10.3 13.5 67.9 100 
  summary(c(rhos)) = 1.29 11.5 21.7 21.7 31.9 42.1 
  rhos defined. time passed: Time difference of 0.04421997 secs
  dim(X) = 100 2 
  beta.h = 0.347 0.761 
  Total time passed: Time difference of 3.682608 secs
  formula.kern: ~z.1 + z.2 + z.3 + z.4 + z.5
  <environment: 0x56241675e360>
  summary(c(l2dist)) = 0.211 5.4 8.88 10.3 13.5 67.9 100 
  summary(c(rhos)) = 1.29 11.5 21.7 21.7 31.9 42.1 
  rhos defined. time passed: Time difference of 0.07551551 secs
  dim(X) = 100 2 
  beta.h = 0.347 0.761 
   num [1:100, 1:100] 1 0.01383 0.03779 0.00277 0.00143 ...
   - attr(*, "dimnames")=List of 2
    ..$ : chr [1:100] "1" "2" "3" "4" ...
    ..$ : chr [1:100] "1" "2" "3" "4" ...
   num [1:100, 1:100] 0.97747 -0.02172 0.0023 -0.00945 -0.01565 ...
   num [1:100, 1:100] 1 0.996 0.997 0.994 0.994 ...
   - attr(*, "dimnames")=List of 2
    ..$ : chr [1:100] "1" "2" "3" "4" ...
    ..$ : chr [1:100] "1" "2" "3" "4" ...
   num [1:100, 1:100] 0.97747 -0.02172 0.0023 -0.00945 -0.01565 ...
  Total time passed: Time difference of 1.443151 secs
  formula.kern: ~z.1 + z.2 + z.3 + z.4 + z.5
  <environment: 0x56241675e360>
  summary(c(l2dist)) = 0.504 5 7.95 9.31 12.7 43.8 50 
  summary(c(rhos)) = 0.224 10.5 14.8 13.9 18.1 20.9 
  rhos defined. time passed: Time difference of 0.003881931 secs
  dim(X) = 50 2 
  beta.h = -0.214 0.984 
  Total time passed: Time difference of 0.3092067 secs
  seq.file.name = /home/hornik/tmp/R.check/r-devel-gcc/Work/build/Packages/krm/misc/sim1.fasta 
  summary(c(l2dist)) = 78.6 104 114 121 138 185 20 
  summary(c(rhos)) = 4.64 41.2 77.8 77.8 114 151 
  rhos defined. time passed: Time difference of 0.8235347 secs
  dim(X) = 20 1 
  beta.h = -0.847 
  Total time passed: Time difference of 1.31375 secs
  formula.kern: ~seq
  <environment: 0x56241675e360>
  summary(c(l2dist)) = 78.6 104 114 121 138 185 20 
  summary(c(rhos)) = 4.64 41.2 77.8 77.8 114 151 
  rhos defined. time passed: Time difference of 0.7338657 secs
  dim(X) = 20 1 
  beta.h = -0.847 
  Total time passed: Time difference of 1.165688 secs
  formula.kern: ~seq
  <environment: 0x56241675e360>
  summary(c(l2dist)) = 6.29 12.5 15.3 15.4 18.1 23.9 20 
  summary(c(rhos)) = 1.7 15.1 28.5 28.5 41.9 55.2 
  rhos defined. time passed: Time difference of 0.09192705 secs
  dim(X) = 20 1 
  beta.h = -0.847 
  Total time passed: Time difference of 0.8020873 secs
   done successfully.
  
  
  
  Executing test function test.krm.score.test  ...  done successfully.
  
  ------------------- UNIT TEST SUMMARY ---------------------
  
  RUNIT TEST PROTOCOL -- Fri Jan 12 18:54:04 2018 
  *********************************************** 
  Number of test functions: 3 
  Number of errors: 0 
  Number of failures: 0 
  
   
  1 Test Suite : 
  krm unit testing - 3 test functions, 0 errors, 0 failures
  Error in file(file, ifelse(append, "a", "w")) : 
    cannot open the connection
  Calls: printTextProtocol -> cat -> file
  In addition: Warning message:
  In file(file, ifelse(append, "a", "w")) :
    cannot open file '/tmp/Rtmp0KZuPc/RLIBS_6e4e56bb5f04/krm/unitTests/reportSummary.txt': Read-only file system
  Execution halted