Running ‘doRUnit.R’ [110s/142s]
Running the tests in ‘tests/doRUnit.R’ failed.
Complete output:
  > # Copyright (C) 2010 - 2013 Dirk Eddelbuettel, Romain Francois and Douglas Bates
  > # Copyright (C) 2014        Dirk Eddelbuettel
  > # Earlier copyrights Gregor Gorjanc, Martin Maechler and Murray Stokely as detailed below
  > #
  > # This file is part of RcppArmadillo.
  > #
  > # RcppArmadillo is free software: you can redistribute it and/or
  > # modify it under the terms of the GNU General Public License as
  > # published by the Free Software Foundation, either version 2 of the
  > # License, or (at your option) any later version.
  > #
  > # RcppArmadillo is distributed in the hope that it will be useful, but
  > # WITHOUT ANY WARRANTY; without even the implied warranty of
  > # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  > # General Public License for more details.
  > #
  > # You should have received a copy of the GNU General Public License
  > # along with RcppArmadillo.  If not, see <http://www.gnu.org/licenses/>.
  > 
  > ## doRUnit.R --- Run RUnit tests
  > ##
  > ## with credits to package fUtilities in RMetrics
  > ## which credits Gregor Gojanc's example in CRAN package  'gdata'
  > ## as per the R Wiki http://wiki.r-project.org/rwiki/doku.php?id=developers:runit
  > ## and changed further by Martin Maechler
  > ## and more changes by Murray Stokely in HistogramTools
  > ## and then used adapted in RProtoBuf
  > ## and now used in Rcpp and here 
  > ##
  > ## Dirk Eddelbuettel, Feb - June 2014
  > 
  > stopifnot(require(RUnit, quietly=TRUE))
  > stopifnot(require(RcppArmadillo, quietly=TRUE))
  > 
  > ## Define tests
  > testSuite <- defineTestSuite(name="RcppArmadillo Unit Tests",
  +                              dirs=system.file("unitTests", package = "RcppArmadillo"),
  +                              testFuncRegexp = "^[Tt]est.+")
  > 
  > ## without this, we get (or used to get) unit test failures
  > Sys.setenv("R_TESTS"="")
  > 
  > ## Run tests
  > tests <- runTestSuite(testSuite)
  
  
  Executing test function test.armadillo.mat.const  ...  done successfully.
  
  
  
  Executing test function test.armadillo.mat.const.ref  ...  done successfully.
  
  
  
  Executing test function test.armadillo.mat.plain  ...  done successfully.
  
  
  
  Executing test function test.armadillo.mat.ref  ...  done successfully.
  
  
  
  Executing test function test.armadillo.sugar.ctor  ...  done successfully.
  
  
  
  Executing test function test.armadillo.sugar.matrix.ctor  ...  done successfully.
  
  
  
  Executing test function test.armadillo.unsigned.as  ...  done successfully.
  
  
  
  Executing test function test.armadillo.vec.const  ...  done successfully.
  
  
  
  Executing test function test.armadillo.vec.const.ref  ...  done successfully.
  
  
  
  Executing test function test.armadillo.vec.plain  ...  done successfully.
  
  
  
  Executing test function test.armadillo.vec.ref  ...  done successfully.
  
  
  
  Executing test function test.as.Col  ...  done successfully.
  
  
  
  Executing test function test.as.Mat  ...  done successfully.
  
  
  
  Executing test function test.as.Row  ...  done successfully.
  
  
  
  Executing test function test.cxmat  ...  done successfully.
  
  
  
  Executing test function test.mtGlue  ...  done successfully.
  
  
  
  Executing test function test.mtOp  ...  done successfully.
  
  
  
  Executing test function test.sugar  ...  done successfully.
  
  
  
  Executing test function test.sugar.cplx  ...  done successfully.
  
  
  
  Executing test function test.wrap.Glue  ...  done successfully.
  
  
  
  Executing test function test.wrap.Op  ...  done successfully.
  
  
  
  Executing test function test.wrap.R  ...  done successfully.
  
  
  
  Executing test function test.complex  ...  done successfully.
  
  
  
  Executing test function test.cube  ...  done successfully.
  
  
  
  Executing test function test.fastLm  ...  done successfully.
  
  
  
  Executing test function test.fastLm.default  ...  done successfully.
  
  
  
  Executing test function test.fastLm.formula  ...  done successfully.
  
  
  
  Executing test function test.summary.fastLm  ...  done successfully.
  
  
  
  Executing test function test.rmultinom  ... rmultinom.cpp: In function ‘Rcpp::IntegerVector rmultinomC(int, int, Rcpp::NumericVector)’:
  rmultinom.cpp:13:44: error: invalid initialization of non-const reference of type ‘arma::vec& {aka arma::Col<double>&}’ from an rvalue of type ‘arma::vec {aka arma::Col<double>}’
       RcppArmadillo::FixProb(fixprob, 1, true);
                                              ^
  In file included from /data/gannet/ripley/R/packages/tests-devel/RcppArmadillo.Rcheck/RcppArmadillo/include/armadillo_bits/Col_meat.hpp:1723:0,
                   from /data/gannet/ripley/R/packages/tests-devel/RcppArmadillo.Rcheck/RcppArmadillo/include/armadillo:564,
                   from /data/gannet/ripley/R/packages/tests-devel/RcppArmadillo.Rcheck/RcppArmadillo/include/RcppArmadilloForward.h:46,
                   from /data/gannet/ripley/R/packages/tests-devel/RcppArmadillo.Rcheck/RcppArmadillo/include/RcppArmadillo.h:31,
                   from /data/gannet/ripley/R/packages/tests-devel/RcppArmadillo.Rcheck/RcppArmadillo/include/RcppArmadilloExtensions/rmultinom.h:28,
                   from rmultinom.cpp:2:
  /data/gannet/ripley/R/packages/tests-devel/RcppArmadillo.Rcheck/RcppArmadillo/include/RcppArmadillo/Col_meat.h:28:8: note:   after user-defined conversion: arma::Col<eT>::Col(const Rcpp::VectorBase<RTYPE, NA, VECTOR>&) [with int RTYPE = 14; bool NA = true; VECTOR = Rcpp::Vector<14, Rcpp::PreserveStorage>; eT = double]
   inline Col<eT>::Col( const Rcpp::VectorBase<RTYPE,NA,VECTOR>& X )
          ^~~~~~~
  In file included from rmultinom.cpp:3:0:
  /data/gannet/ripley/R/packages/tests-devel/RcppArmadillo.Rcheck/RcppArmadillo/include/RcppArmadilloExtensions/fixprob.h:29:14: note:   initializing argument 1 of ‘void Rcpp::RcppArmadillo::FixProb(arma::vec&, int, bool)’
           void FixProb(arma::vec &prob, const int size, const bool replace) {
                ^~~~~~~
  make[1]: *** [rmultinom.o] Error 1
  make[1]: Target 'all' not remade because of errors.
  make[1]: Entering directory '/tmp/RtmpdQINd6/sourceCpp-x86_64-pc-linux-gnu-0.12.11/sourcecpp_aab94c109aa1'
  g++ -std=gnu++98 -I/data/gannet/ripley/R/R-devel/include -DNDEBUG   -I"/data/gannet/ripley/R/test-3.5/Rcpp/include" -I"/data/gannet/ripley/R/packages/tests-devel/RcppArmadillo.Rcheck/RcppArmadillo/include" -I"/data/gannet/ripley/R/packages/tests-devel/RcppArmadillo.Rcheck/RcppArmadillo/unitTests/cpp" -I/usr/local/include   -fpic  -g -O2 -Wall -pedantic -mtune=native  -c rmultinom.cpp -o rmultinom.o
  /data/gannet/ripley/R/R-devel/etc/Makeconf:166: recipe for target 'rmultinom.o' failed
  make[1]: Leaving directory '/tmp/RtmpdQINd6/sourceCpp-x86_64-pc-linux-gnu-0.12.11/sourcecpp_aab94c109aa1'
  Error in sourceCpp(system.file("unitTests", "cpp", file, package = "RcppArmadillo")) : 
    Error 1 occurred building shared library.
  
  
  Executing test function test.randi  ...  done successfully.
  
  
  
  Executing test function test.randi.seed  ...  done successfully.
  
  
  
  Executing test function test.randn  ...  done successfully.
  
  
  
  Executing test function test.randn.seed  ...  done successfully.
  
  
  
  Executing test function test.randu  ...  done successfully.
  
  
  
  Executing test function test.randu.seed  ...  done successfully.
  
  
  
  Executing test function test.sample  ...  done successfully.
  
  
  
  Executing test function test.as.sparse  ...  done successfully.
  
  
  
  Executing test function test.sparse.addition  ...  done successfully.
  
  
  
  Executing test function test.sparse.fromTriplet  ...  done successfully.
  
  
  
  Executing test function test.sparse.iterators  ...  done successfully.
  
  
  
  Executing test function test.sparse.list  ...  done successfully.
  
  
  
  Executing test function test.sparse.multiplication  ...  done successfully.
  
  
  
  Executing test function test.sparse.sqrt  ...  done successfully.
  
  
  
  Executing test function test.sparse.square  ...  done successfully.
  
  
  
  Executing test function test.sparse.transpose  ...  done successfully.
  
  > 
  > ## Print results
  > printTextProtocol(tests)
  RUNIT TEST PROTOCOL -- Mon May 29 19:49:11 2017 
  *********************************************** 
  Number of test functions: 45 
  Number of errors: 1 
  Number of failures: 0 
  
   
  1 Test Suite : 
  RcppArmadillo Unit Tests - 45 test functions, 1 error, 0 failures
  ERROR in .setUp (before test.rmultinom): Error executing .setUp before test.rmultinom : Error in sourceCpp(system.file("unitTests", "cpp", file, package = "RcppArmadillo")) : 
    Error 1 occurred building shared library.
  
  
  
  Details 
  *************************** 
  Test Suite: RcppArmadillo Unit Tests 
  Test function regexp: ^[Tt]est.+ 
  Test file regexp: ^runit.+\.[rR]$ 
  Involved directory: 
  /data/gannet/ripley/R/packages/tests-devel/RcppArmadillo.Rcheck/RcppArmadillo/unitTests 
  --------------------------- 
  Test file: /data/gannet/ripley/R/packages/tests-devel/RcppArmadillo.Rcheck/RcppArmadillo/unitTests/runit.RcppArmadillo.R 
  test.armadillo.mat.const: (1 checks) ... OK (0 seconds)
  test.armadillo.mat.const.ref: (1 checks) ... OK (0 seconds)
  test.armadillo.mat.plain: (1 checks) ... OK (0 seconds)
  test.armadillo.mat.ref: (1 checks) ... OK (0 seconds)
  test.armadillo.sugar.ctor: (1 checks) ... OK (0 seconds)
  test.armadillo.sugar.matrix.ctor: (1 checks) ... OK (0.02 seconds)
  test.armadillo.unsigned.as: (8 checks) ... OK (0 seconds)
  test.armadillo.vec.const: (1 checks) ... OK (0 seconds)
  test.armadillo.vec.const.ref: (1 checks) ... OK (0 seconds)
  test.armadillo.vec.plain: (1 checks) ... OK (0 seconds)
  test.armadillo.vec.ref: (1 checks) ... OK (0 seconds)
  test.as.Col: (1 checks) ... OK (0 seconds)
  test.as.Mat: (1 checks) ... OK (0 seconds)
  test.as.Row: (1 checks) ... OK (0 seconds)
  test.cxmat: (1 checks) ... OK (0 seconds)
  test.mtGlue: (1 checks) ... OK (0 seconds)
  test.mtOp: (1 checks) ... OK (0 seconds)
  test.sugar: (1 checks) ... OK (0 seconds)
  test.sugar.cplx: (1 checks) ... OK (0 seconds)
  test.wrap.Glue: (1 checks) ... OK (0 seconds)
  test.wrap.Op: (1 checks) ... OK (0 seconds)
  test.wrap.R: (10 checks) ... OK (0 seconds)
  --------------------------- 
  Test file: /data/gannet/ripley/R/packages/tests-devel/RcppArmadillo.Rcheck/RcppArmadillo/unitTests/runit.complex.R 
  test.complex: (11 checks) ... OK (0 seconds)
  --------------------------- 
  Test file: /data/gannet/ripley/R/packages/tests-devel/RcppArmadillo.Rcheck/RcppArmadillo/unitTests/runit.cube.R 
  test.cube: (18 checks) ... OK (0.03 seconds)
  --------------------------- 
  Test file: /data/gannet/ripley/R/packages/tests-devel/RcppArmadillo.Rcheck/RcppArmadillo/unitTests/runit.fastLm.R 
  test.fastLm: (3 checks) ... OK (0.03 seconds)
  test.fastLm.default: (5 checks) ... OK (0.01 seconds)
  test.fastLm.formula: (5 checks) ... OK (0.03 seconds)
  test.summary.fastLm: (12 checks) ... OK (0.07 seconds)
  --------------------------- 
  Test file: /data/gannet/ripley/R/packages/tests-devel/RcppArmadillo.Rcheck/RcppArmadillo/unitTests/runit.rmultinom.R 
  .setUp (before test.rmultinom): ERROR !! 
  Error executing .setUp before test.rmultinom : Error in sourceCpp(system.file("unitTests", "cpp", file, package = "RcppArmadillo")) : 
    Error 1 occurred building shared library.
  --------------------------- 
  Test file: /data/gannet/ripley/R/packages/tests-devel/RcppArmadillo.Rcheck/RcppArmadillo/unitTests/runit.rng.R 
  test.randi: (2 checks) ... OK (0 seconds)
  test.randi.seed: (1 checks) ... OK (0 seconds)
  test.randn: (3 checks) ... OK (0 seconds)
  test.randn.seed: (1 checks) ... OK (0 seconds)
  test.randu: (2 checks) ... OK (0 seconds)
  test.randu.seed: (1 checks) ... OK (0 seconds)
  --------------------------- 
  Test file: /data/gannet/ripley/R/packages/tests-devel/RcppArmadillo.Rcheck/RcppArmadillo/unitTests/runit.sample.R 
  test.sample: (21 checks) ... OK (0.1 seconds)
  --------------------------- 
  Test file: /data/gannet/ripley/R/packages/tests-devel/RcppArmadillo.Rcheck/RcppArmadillo/unitTests/runit.sparse.R 
  test.as.sparse: (1 checks) ... OK (0 seconds)
  test.sparse.addition: (1 checks) ... OK (0.03 seconds)
  test.sparse.fromTriplet: (1 checks) ... OK (0 seconds)
  test.sparse.iterators: (1 checks) ... OK (0.01 seconds)
  test.sparse.list: (1 checks) ... OK (0 seconds)
  test.sparse.multiplication: (1 checks) ... OK (0 seconds)
  test.sparse.sqrt: (1 checks) ... OK (0 seconds)
  test.sparse.square: (1 checks) ... OK (0 seconds)
  test.sparse.transpose: (1 checks) ... OK (0 seconds)
  > 
  > ## Return success or failure to R CMD CHECK
  > if (getErrors(tests)$nFail > 0) {
  +     stop("TEST FAILED!")
  + }
  > if (getErrors(tests)$nErr > 0) {
  +     stop("TEST HAD ERRORS!")
  + }
  Error: TEST HAD ERRORS!
  Execution halted