Running ‘testthat.R’ [74s/107s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(pmml, quietly = T)
  > 
  > test_check("pmml")
  ── 1. Error: GeneralRegressionModel/stats PMML validates against schema (@test_s
  y values must be 0 <= y <= 1
  Backtrace:
   1. stats::glm(...)
   4. stats::glm.fit(...)
  
  ── 2. Error: MiningModel/ada PMML validates against schema (@test_schema_validat
  character class is not supported for features. Supported classes: numeric, logical, factor.
  Backtrace:
   1. testthat::expect_equal(validate_pmml(pmml(fit), schema), 0)
   7. pmml::pmml.ada(fit)
   9. pmml:::.pmmlDataDictionary(noTargetFields, transformed = transforms)
  
  ── 3. Error: MiningModel/randomForest PMML validates against schema (@test_schem
  character class is not supported for features. Supported classes: numeric, logical, factor.
  Backtrace:
   1. testthat::expect_equal(validate_pmml(pmml(fit), schema), 0)
   7. pmml::pmml.randomForest(fit)
   9. pmml:::.pmmlDataDictionary(field, transformed = transforms)
  
  ── 4. Error: NaiveBayesModel/e1071 PMML validates against schema (@test_schema_v
  Unable to determine levels of target variable.
            If numeric, please ensure it is read as a factor by using as.factor(variable_name)
  Backtrace:
   1. testthat::expect_equal(...)
   7. pmml::pmml.naiveBayes(fit, predicted_field = "BANKCARD")
  
  ── 5. Error: NearestNeighborModel/neighbr PMML validates against schema (@test_s
  missing values not allowed in train_test or test_set
  Backtrace:
   1. neighbr::knn(...)
  
  ── 6. Error: NeuralNetwork/nnet PMML validates against schema  ─────────────────
  NA/NaN/Inf in foreign function call (arg 2)
  Backtrace:
   1. nnet::nnet(...)
   2. nnet::nnet.formula(...)
   3. nnet::nnet.default(x, y, w, ...)
  
  ── 7. Error: RegressionModel/nnet PMML validates against schema (@test_schema_va
  character class is not supported for features. Supported classes: numeric, logical, factor.
  Backtrace:
   1. testthat::expect_equal(validate_pmml(pmml(fit), schema), 0)
   7. pmml::pmml.multinom(fit)
   9. pmml:::.pmmlDataDictionary(field, NULL, NULL, transforms)
  
  ── 8. Error: SupportVectorMachineModel/e1071 PMML validates against schema (@tes
  character class is not supported for features. Supported classes: numeric, logical, factor.
  Backtrace:
   1. testthat::expect_equal(validate_pmml(pmml(fit), schema), 0)
   7. pmml::pmml.svm(fit)
   9. pmml:::.pmmlDataDictionary(field, transformed = transforms, target = target)
  
  ── 9. Error: SupportVectorMachineModel/kernlab PMML validates against schema (@t
  No Support Vectors found. You may want to change your parameters
  Backtrace:
   1. kernlab::ksvm(CLASS ~ ., data = iris_nor, kernel = "rbfdot")
   2. kernlab::ksvm(CLASS ~ ., data = iris_nor, kernel = "rbfdot")
   3. kernlab:::.local(x, ...)
   5. kernlab::ksvm(x, y, scaled = scaled, ...)
   6. kernlab:::.local(x, ...)
  
  ── 10. Error: TreeModel/rpart PMML validates against schema (@test_schema_valida
  character class is not supported for features. Supported classes: numeric, logical, factor.
  Backtrace:
   1. testthat::expect_equal(validate_pmml(pmml(fit), schema), 0)
   7. pmml::pmml.rpart(fit)
   9. pmml:::.pmmlDataDictionary(...)
  
  ══ testthat results  ═══════════════════════════════════════════════════════════
  [ OK: 288 | SKIPPED: 4 | WARNINGS: 2 | FAILED: 10 ]
  1.  Error: GeneralRegressionModel/stats PMML validates against schema (@test_schema_validation.R#338) 
  2.  Error: MiningModel/ada PMML validates against schema (@test_schema_validation.R#405) 
  3.  Error: MiningModel/randomForest PMML validates against schema (@test_schema_validation.R#465) 
  4.  Error: NaiveBayesModel/e1071 PMML validates against schema (@test_schema_validation.R#752) 
  5.  Error: NearestNeighborModel/neighbr PMML validates against schema (@test_schema_validation.R#920) 
  6.  Error: NeuralNetwork/nnet PMML validates against schema 
  7.  Error: RegressionModel/nnet PMML validates against schema (@test_schema_validation.R#979) 
  8.  Error: SupportVectorMachineModel/e1071 PMML validates against schema (@test_schema_validation.R#1139) 
  9.  Error: SupportVectorMachineModel/kernlab PMML validates against schema (@test_schema_validation.R#1345) 
  10. Error: TreeModel/rpart PMML validates against schema (@test_schema_validation.R#1418) 
  
  Error: testthat unit tests failed
  Execution halted